aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm
diff options
context:
space:
mode:
authorGravatar Weiliang Chen <weiliangc@chromium.org>2018-05-30 15:15:23 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-07-03 21:30:27 +0000
commit3e95e578c255e8b854d7997a47b74b1b03f1346f (patch)
tree9bc84a130d3a38b54ccb585e64821bfad5cc7731 /gm
parentc940f5d5ff81602b5269373a4b15dbedd09de541 (diff)
Use TextureProxy size directly in GrYUVToRGBEffect FragmentProcessor
Instead of take extra input to indicate size for texture proxies of different planes, directly use texture proxy's size. Bug: skia:7903 Change-Id: I5d6c859510f7390948c6dcfbdd17343faa786aca Reviewed-on: https://skia-review.googlesource.com/130964 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Weiliang Chen <weiliangc@chromium.org>
Diffstat (limited to 'gm')
-rw-r--r--gm/yuvtorgbeffect.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/gm/yuvtorgbeffect.cpp b/gm/yuvtorgbeffect.cpp
index a73025502b..09bbd562b2 100644
--- a/gm/yuvtorgbeffect.cpp
+++ b/gm/yuvtorgbeffect.cpp
@@ -101,7 +101,6 @@ protected:
constexpr SkScalar kDrawPad = 10.f;
constexpr SkScalar kTestPad = 10.f;
constexpr SkScalar kColorSpaceOffset = 36.f;
- SkISize sizes[3] = {{YSIZE, YSIZE}, {USIZE, USIZE}, {VSIZE, VSIZE}};
for (int space = kJPEG_SkYUVColorSpace; space <= kLastEnum_SkYUVColorSpace; ++space) {
SkRect renderRect = SkRect::MakeWH(SkIntToScalar(fBmp[0].width()),
@@ -119,7 +118,6 @@ protected:
GrYUVtoRGBEffect::Make(proxy[indices[i][0]],
proxy[indices[i][1]],
proxy[indices[i][2]],
- sizes,
static_cast<SkYUVColorSpace>(space),
false));
if (fp) {
@@ -227,7 +225,6 @@ protected:
constexpr SkScalar kDrawPad = 10.f;
constexpr SkScalar kTestPad = 10.f;
constexpr SkScalar kColorSpaceOffset = 36.f;
- SkISize sizes[3] = {{YSIZE, YSIZE}, {USIZE, USIZE}, {VSIZE, VSIZE}};
for (int space = kJPEG_SkYUVColorSpace; space <= kLastEnum_SkYUVColorSpace; ++space) {
SkRect renderRect =
@@ -239,7 +236,7 @@ protected:
GrPaint grPaint;
grPaint.setXPFactory(GrPorterDuffXPFactory::Get(SkBlendMode::kSrc));
- auto fp = GrYUVtoRGBEffect::Make(proxy[0], proxy[1], proxy[2], sizes,
+ auto fp = GrYUVtoRGBEffect::Make(proxy[0], proxy[1], proxy[2],
static_cast<SkYUVColorSpace>(space), true);
if (fp) {
SkMatrix viewMatrix;