Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(95)

Side by Side Diff: gm/yuvtorgbeffect.cpp

Issue 2037413002: Add SkSourceGammaTreatment enum so we know how to create mips (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove leftover comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 // This test only works with the GPU backend. 8 // This test only works with the GPU backend.
9 9
10 #include "gm.h" 10 #include "gm.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 return; 75 return;
76 } 76 }
77 77
78 GrContext* context = canvas->getGrContext(); 78 GrContext* context = canvas->getGrContext();
79 if (!context) { 79 if (!context) {
80 return; 80 return;
81 } 81 }
82 82
83 SkAutoTUnref<GrTexture> texture[3]; 83 SkAutoTUnref<GrTexture> texture[3];
84 texture[0].reset(GrRefCachedBitmapTexture(context, fBmp[0], 84 texture[0].reset(GrRefCachedBitmapTexture(context, fBmp[0],
85 GrTextureParams::ClampBilerp() )); 85 GrTextureParams::ClampBilerp() , false));
86 texture[1].reset(GrRefCachedBitmapTexture(context, fBmp[1], 86 texture[1].reset(GrRefCachedBitmapTexture(context, fBmp[1],
87 GrTextureParams::ClampBilerp() )); 87 GrTextureParams::ClampBilerp() , false));
88 texture[2].reset(GrRefCachedBitmapTexture(context, fBmp[2], 88 texture[2].reset(GrRefCachedBitmapTexture(context, fBmp[2],
89 GrTextureParams::ClampBilerp() )); 89 GrTextureParams::ClampBilerp() , false));
90 90
91 if (!texture[0] || !texture[1] || !texture[2]) { 91 if (!texture[0] || !texture[1] || !texture[2]) {
92 return; 92 return;
93 } 93 }
94 94
95 static const SkScalar kDrawPad = 10.f; 95 static const SkScalar kDrawPad = 10.f;
96 static const SkScalar kTestPad = 10.f; 96 static const SkScalar kTestPad = 10.f;
97 static const SkScalar kColorSpaceOffset = 36.f; 97 static const SkScalar kColorSpaceOffset = 36.f;
98 SkISize sizes[3] = {{YSIZE, YSIZE}, {USIZE, USIZE}, {VSIZE, VSIZE}}; 98 SkISize sizes[3] = {{YSIZE, YSIZE}, {USIZE, USIZE}, {VSIZE, VSIZE}};
99 99
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 private: 137 private:
138 SkBitmap fBmp[3]; 138 SkBitmap fBmp[3];
139 139
140 typedef GM INHERITED; 140 typedef GM INHERITED;
141 }; 141 };
142 142
143 DEF_GM(return new YUVtoRGBEffect;) 143 DEF_GM(return new YUVtoRGBEffect;)
144 } 144 }
145 145
146 #endif 146 #endif
OLDNEW
« no previous file with comments | « gm/texturedomaineffect.cpp ('k') | include/core/SkShader.h » ('j') | src/gpu/SkGr.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698