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

Side by Side Diff: samplecode/SampleSlides.cpp

Issue 51033004: add SK_ATTR_DEPRECATED -- will need to disable for chrome, since it triggers a warning (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 1 month 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 | « samplecode/SamplePatch.cpp ('k') | samplecode/SampleTextureDomain.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 "SampleCode.h" 8 #include "SampleCode.h"
9 #include "SkBlurMask.h" 9 #include "SkBlurMask.h"
10 #include "SkBlurMaskFilter.h" 10 #include "SkBlurMaskFilter.h"
(...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after
437 437
438 SkAutoUnref aur0(fShader0); 438 SkAutoUnref aur0(fShader0);
439 SkAutoUnref aur1(fShader1); 439 SkAutoUnref aur1(fShader1);
440 440
441 make_strip(&fRecs[0], size.fX, size.fY); 441 make_strip(&fRecs[0], size.fX, size.fY);
442 make_fan(&fRecs[1], size.fX, size.fY); 442 make_fan(&fRecs[1], size.fX, size.fY);
443 make_tris(&fRecs[2]); 443 make_tris(&fRecs[2]);
444 444
445 SkPaint paint; 445 SkPaint paint;
446 paint.setDither(true); 446 paint.setDither(true);
447 paint.setFilterBitmap(true); 447 paint.setFilterLevel(SkPaint::kLow_FilterLevel);
448 448
449 for (size_t i = 0; i < SK_ARRAY_COUNT(fRecs); i++) { 449 for (size_t i = 0; i < SK_ARRAY_COUNT(fRecs); i++) {
450 canvas->save(); 450 canvas->save();
451 451
452 paint.setShader(NULL); 452 paint.setShader(NULL);
453 canvas->drawVertices(fRecs[i].fMode, fRecs[i].fCount, 453 canvas->drawVertices(fRecs[i].fMode, fRecs[i].fCount,
454 fRecs[i].fVerts, fRecs[i].fTexs, 454 fRecs[i].fVerts, fRecs[i].fTexs,
455 NULL, NULL, NULL, 0, paint); 455 NULL, NULL, NULL, 0, paint);
456 456
457 canvas->translate(SkIntToScalar(210), 0); 457 canvas->translate(SkIntToScalar(210), 0);
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after
725 } 725 }
726 726
727 private: 727 private:
728 typedef SampleView INHERITED; 728 typedef SampleView INHERITED;
729 }; 729 };
730 730
731 ////////////////////////////////////////////////////////////////////////////// 731 //////////////////////////////////////////////////////////////////////////////
732 732
733 static SkView* MyFactory() { return new SlideView; } 733 static SkView* MyFactory() { return new SlideView; }
734 static SkViewRegister reg(MyFactory); 734 static SkViewRegister reg(MyFactory);
OLDNEW
« no previous file with comments | « samplecode/SamplePatch.cpp ('k') | samplecode/SampleTextureDomain.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698