| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 | 8 |
| 9 #include "GrGLUtil.h" | 9 #include "GrGLUtil.h" |
| 10 #include "SkMatrix.h" | 10 #include "SkMatrix.h" |
| (...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 static const GrGLenum gTable[] = { | 336 static const GrGLenum gTable[] = { |
| 337 GR_GL_ALWAYS, // kAlways_StencilFunc | 337 GR_GL_ALWAYS, // kAlways_StencilFunc |
| 338 GR_GL_NEVER, // kNever_StencilFunc | 338 GR_GL_NEVER, // kNever_StencilFunc |
| 339 GR_GL_GREATER, // kGreater_StencilFunc | 339 GR_GL_GREATER, // kGreater_StencilFunc |
| 340 GR_GL_GEQUAL, // kGEqual_StencilFunc | 340 GR_GL_GEQUAL, // kGEqual_StencilFunc |
| 341 GR_GL_LESS, // kLess_StencilFunc | 341 GR_GL_LESS, // kLess_StencilFunc |
| 342 GR_GL_LEQUAL, // kLEqual_StencilFunc, | 342 GR_GL_LEQUAL, // kLEqual_StencilFunc, |
| 343 GR_GL_EQUAL, // kEqual_StencilFunc, | 343 GR_GL_EQUAL, // kEqual_StencilFunc, |
| 344 GR_GL_NOTEQUAL, // kNotEqual_StencilFunc, | 344 GR_GL_NOTEQUAL, // kNotEqual_StencilFunc, |
| 345 }; | 345 }; |
| 346 GR_STATIC_ASSERT(SK_ARRAY_COUNT(gTable) == kBasicStencilFuncCount); | 346 GR_STATIC_ASSERT(SK_ARRAY_COUNT(gTable) == kBasicStencilFuncCnt); |
| 347 GR_STATIC_ASSERT(0 == kAlways_StencilFunc); | 347 GR_STATIC_ASSERT(0 == kAlways_StencilFunc); |
| 348 GR_STATIC_ASSERT(1 == kNever_StencilFunc); | 348 GR_STATIC_ASSERT(1 == kNever_StencilFunc); |
| 349 GR_STATIC_ASSERT(2 == kGreater_StencilFunc); | 349 GR_STATIC_ASSERT(2 == kGreater_StencilFunc); |
| 350 GR_STATIC_ASSERT(3 == kGEqual_StencilFunc); | 350 GR_STATIC_ASSERT(3 == kGEqual_StencilFunc); |
| 351 GR_STATIC_ASSERT(4 == kLess_StencilFunc); | 351 GR_STATIC_ASSERT(4 == kLess_StencilFunc); |
| 352 GR_STATIC_ASSERT(5 == kLEqual_StencilFunc); | 352 GR_STATIC_ASSERT(5 == kLEqual_StencilFunc); |
| 353 GR_STATIC_ASSERT(6 == kEqual_StencilFunc); | 353 GR_STATIC_ASSERT(6 == kEqual_StencilFunc); |
| 354 GR_STATIC_ASSERT(7 == kNotEqual_StencilFunc); | 354 GR_STATIC_ASSERT(7 == kNotEqual_StencilFunc); |
| 355 SkASSERT((unsigned) basicFunc < kBasicStencilFuncCount); | 355 SkASSERT((unsigned) basicFunc < kBasicStencilFuncCnt); |
| 356 | 356 |
| 357 return gTable[basicFunc]; | 357 return gTable[basicFunc]; |
| 358 } | 358 } |
| OLD | NEW |