OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #ifndef SkGradientShaderPriv_DEFINED | 8 #ifndef SkGradientShaderPriv_DEFINED |
9 #define SkGradientShaderPriv_DEFINED | 9 #define SkGradientShaderPriv_DEFINED |
10 | 10 |
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
322 * determines the gradient value. | 322 * determines the gradient value. |
323 */ | 323 */ |
324 | 324 |
325 class GrTextureStripAtlas; | 325 class GrTextureStripAtlas; |
326 | 326 |
327 // Base class for Gr gradient effects | 327 // Base class for Gr gradient effects |
328 class GrGradientEffect : public GrFragmentProcessor { | 328 class GrGradientEffect : public GrFragmentProcessor { |
329 public: | 329 public: |
330 | 330 |
331 GrGradientEffect(GrContext* ctx, | 331 GrGradientEffect(GrContext* ctx, |
332 GrShaderDataManager*, | 332 GrProcessorDataManager*, |
333 const SkGradientShaderBase& shader, | 333 const SkGradientShaderBase& shader, |
334 const SkMatrix& matrix, | 334 const SkMatrix& matrix, |
335 SkShader::TileMode tileMode); | 335 SkShader::TileMode tileMode); |
336 | 336 |
337 virtual ~GrGradientEffect(); | 337 virtual ~GrGradientEffect(); |
338 | 338 |
339 bool useAtlas() const { return SkToBool(-1 != fRow); } | 339 bool useAtlas() const { return SkToBool(-1 != fRow); } |
340 SkScalar getYCoord() const { return fYCoord; }; | 340 SkScalar getYCoord() const { return fYCoord; }; |
341 | 341 |
342 SkGradientShaderBase::GpuColorType getColorType() const { return fColorType;
} | 342 SkGradientShaderBase::GpuColorType getColorType() const { return fColorType;
} |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
447 GrGLProgramDataManager::UniformHandle fColorStartUni; | 447 GrGLProgramDataManager::UniformHandle fColorStartUni; |
448 GrGLProgramDataManager::UniformHandle fColorMidUni; | 448 GrGLProgramDataManager::UniformHandle fColorMidUni; |
449 GrGLProgramDataManager::UniformHandle fColorEndUni; | 449 GrGLProgramDataManager::UniformHandle fColorEndUni; |
450 | 450 |
451 typedef GrGLFragmentProcessor INHERITED; | 451 typedef GrGLFragmentProcessor INHERITED; |
452 }; | 452 }; |
453 | 453 |
454 #endif | 454 #endif |
455 | 455 |
456 #endif | 456 #endif |
OLD | NEW |