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

Side by Side Diff: tests/GLProgramsTest.cpp

Issue 23707019: alpha threshold bitmap shader (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: false->NULL Created 7 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « src/gpu/SkGpuDevice.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 // This is a GPU-backend specific test. It relies on static intializers to work 9 // This is a GPU-backend specific test. It relies on static intializers to work
10 10
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 DEFINE_GPUTESTCLASS("GLPrograms", GLProgramsTestClass, GLProgramsTest) 221 DEFINE_GPUTESTCLASS("GLPrograms", GLProgramsTestClass, GLProgramsTest)
222 222
223 // This is evil evil evil. The linker may throw away whole translation units as dead code if it 223 // This is evil evil evil. The linker may throw away whole translation units as dead code if it
224 // thinks none of the functions are called. It will do this even if there are st atic initializers 224 // thinks none of the functions are called. It will do this even if there are st atic initializers
225 // in the unit that could pass pointers to functions from the unit out to other translation units! 225 // in the unit that could pass pointers to functions from the unit out to other translation units!
226 // We force some of the effects that would otherwise be discarded to link here. 226 // We force some of the effects that would otherwise be discarded to link here.
227 227
228 #include "SkLightingImageFilter.h" 228 #include "SkLightingImageFilter.h"
229 #include "SkMagnifierImageFilter.h" 229 #include "SkMagnifierImageFilter.h"
230 #include "SkColorMatrixFilter.h" 230 #include "SkColorMatrixFilter.h"
231 #include "SkBitmapAlphaThresholdShader.h"
231 232
232 void forceLinking(); 233 void forceLinking();
233 234
234 void forceLinking() { 235 void forceLinking() {
235 SkLightingImageFilter::CreateDistantLitDiffuse(SkPoint3(0,0,0), 0, 0, 0); 236 SkLightingImageFilter::CreateDistantLitDiffuse(SkPoint3(0,0,0), 0, 0, 0);
236 SkMagnifierImageFilter mag(SkRect::MakeWH(SK_Scalar1, SK_Scalar1), SK_Scalar 1); 237 SkMagnifierImageFilter mag(SkRect::MakeWH(SK_Scalar1, SK_Scalar1), SK_Scalar 1);
237 GrConfigConversionEffect::Create(NULL, 238 GrConfigConversionEffect::Create(NULL,
238 false, 239 false,
239 GrConfigConversionEffect::kNone_PMConversio n, 240 GrConfigConversionEffect::kNone_PMConversio n,
240 SkMatrix::I()); 241 SkMatrix::I());
241 SkScalar matrix[20]; 242 SkScalar matrix[20];
242 SkColorMatrixFilter cmf(matrix); 243 SkColorMatrixFilter cmf(matrix);
244 SkBitmapAlphaThresholdShader::Create(SkBitmap(), SkRegion(), 0x80);
243 } 245 }
244 246
245 #endif 247 #endif
OLDNEW
« no previous file with comments | « src/gpu/SkGpuDevice.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698