diff options
author | 2013-07-13 17:24:24 +0000 | |
---|---|---|
committer | 2013-07-13 17:24:24 +0000 | |
commit | 42dacab4e7366d9f53989558cc8d045c3d065bcd (patch) | |
tree | b4659c9888df3193960c1dd1cfb01650dcc12cdb /src/gpu/GrDrawState.cpp | |
parent | 0408a346962ef0939704fe435a0cdde52da4613f (diff) |
Make GrPaint have a variable sized array of color and coverage stages rather than a fixed size.
R=robertphillips@google.com, jvanverth@google.com
Author: bsalomon@google.com
Review URL: https://chromiumcodereview.appspot.com/18686007
git-svn-id: http://skia.googlecode.com/svn/trunk@10062 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/gpu/GrDrawState.cpp')
-rw-r--r-- | src/gpu/GrDrawState.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/gpu/GrDrawState.cpp b/src/gpu/GrDrawState.cpp index 7c68543479..ab800d24e7 100644 --- a/src/gpu/GrDrawState.cpp +++ b/src/gpu/GrDrawState.cpp @@ -32,16 +32,12 @@ void GrDrawState::setFromPaint(const GrPaint& paint, const SkMatrix& vm, GrRende fColorStages.reset(); fCoverageStages.reset(); - for (int i = 0; i < GrPaint::kMaxColorStages; ++i) { - if (paint.isColorStageEnabled(i)) { - fColorStages.push_back(paint.getColorStage(i)); - } + for (int i = 0; i < paint.numColorStages(); ++i) { + fColorStages.push_back(paint.getColorStage(i)); } - for (int i = 0; i < GrPaint::kMaxCoverageStages; ++i) { - if (paint.isCoverageStageEnabled(i)) { - fCoverageStages.push_back(paint.getCoverageStage(i)); - } + for (int i = 0; i < paint.numCoverageStages(); ++i) { + fCoverageStages.push_back(paint.getCoverageStage(i)); } this->setRenderTarget(rt); |