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

Side by Side Diff: src/effects/SkColorMatrixFilter.cpp

Issue 15697012: Add printing of SkColorFilter-derived classes to debugger (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Remove unnecessary macros Created 7 years, 7 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/effects/SkColorFilters.cpp ('k') | src/effects/SkTableColorFilter.cpp » ('j') | 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 #include "SkColorMatrixFilter.h" 8 #include "SkColorMatrixFilter.h"
9 #include "SkColorMatrix.h" 9 #include "SkColorMatrix.h"
10 #include "SkColorPriv.h" 10 #include "SkColorPriv.h"
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 colorMatrix.fMat[i] = random->nextSScalar1(); 470 colorMatrix.fMat[i] = random->nextSScalar1();
471 } 471 }
472 return ColorMatrixEffect::Create(colorMatrix); 472 return ColorMatrixEffect::Create(colorMatrix);
473 } 473 }
474 474
475 GrEffectRef* SkColorMatrixFilter::asNewEffect(GrContext*) const { 475 GrEffectRef* SkColorMatrixFilter::asNewEffect(GrContext*) const {
476 return ColorMatrixEffect::Create(fMatrix); 476 return ColorMatrixEffect::Create(fMatrix);
477 } 477 }
478 478
479 #endif 479 #endif
480
481 #ifdef SK_DEVELOPER
482 void SkColorMatrixFilter::toString(SkString* str) const {
483 str->append("SkColorMatrixFilter: ");
484
485 str->append("matrix: (");
486 for (int i = 0; i < 20; ++i) {
487 str->appendScalar(fMatrix.fMat[i]);
488 if (i < 19) {
489 str->append(", ");
490 }
491 }
492 str->append(")");
493 }
494 #endif
OLDNEW
« no previous file with comments | « src/effects/SkColorFilters.cpp ('k') | src/effects/SkTableColorFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698