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

Side by Side Diff: samplecode/SampleAll.cpp

Issue 768183002: Revert of Remove SK_SUPPORT_LEGACY_DEEPFLATTENING. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years 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
« no previous file with comments | « samplecode/ClockFaceView.cpp ('k') | src/core/SkBitmapProcShader.h » ('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 "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 Dot2DPathEffect(SkScalar radius, const SkMatrix& matrix) 165 Dot2DPathEffect(SkScalar radius, const SkMatrix& matrix)
166 : Sk2DPathEffect(matrix), fRadius(radius) {} 166 : Sk2DPathEffect(matrix), fRadius(radius) {}
167 167
168 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(Dot2DPathEffect) 168 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(Dot2DPathEffect)
169 169
170 protected: 170 protected:
171 virtual void next(const SkPoint& loc, int u, int v, SkPath* dst) const SK_OV ERRIDE { 171 virtual void next(const SkPoint& loc, int u, int v, SkPath* dst) const SK_OV ERRIDE {
172 dst->addCircle(loc.fX, loc.fY, fRadius); 172 dst->addCircle(loc.fX, loc.fY, fRadius);
173 } 173 }
174 174
175 #ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING
176 Dot2DPathEffect(SkReadBuffer& buffer) : INHERITED(buffer) {
177 fRadius = buffer.readScalar();
178 }
179 #endif
175 virtual void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE { 180 virtual void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE {
176 this->INHERITED::flatten(buffer); 181 this->INHERITED::flatten(buffer);
177 buffer.writeScalar(fRadius); 182 buffer.writeScalar(fRadius);
178 } 183 }
179 184
180 private: 185 private:
181 SkScalar fRadius; 186 SkScalar fRadius;
182 187
183 typedef Sk2DPathEffect INHERITED; 188 typedef Sk2DPathEffect INHERITED;
184 }; 189 };
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after
590 private: 595 private:
591 SkPoint fClickPt; 596 SkPoint fClickPt;
592 SkBitmap fBug, fTb, fTx; 597 SkBitmap fBug, fTb, fTx;
593 typedef SampleView INHERITED; 598 typedef SampleView INHERITED;
594 }; 599 };
595 600
596 ////////////////////////////////////////////////////////////////////////////// 601 //////////////////////////////////////////////////////////////////////////////
597 602
598 static SkView* MyFactory() { return new DemoView; } 603 static SkView* MyFactory() { return new DemoView; }
599 static SkViewRegister reg(MyFactory); 604 static SkViewRegister reg(MyFactory);
OLDNEW
« no previous file with comments | « samplecode/ClockFaceView.cpp ('k') | src/core/SkBitmapProcShader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698