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

Side by Side Diff: src/core/SkDraw.cpp

Issue 134163010: Refactor read and write buffers. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: original write flags were fine Created 6 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
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 #include "SkDraw.h" 8 #include "SkDraw.h"
9 #include "SkBlitter.h" 9 #include "SkBlitter.h"
10 #include "SkBounder.h" 10 #include "SkBounder.h"
(...skipping 2364 matching lines...) Expand 10 before | Expand all | Expand 10 after
2375 SkTriColorShader() {} 2375 SkTriColorShader() {}
2376 2376
2377 bool setup(const SkPoint pts[], const SkColor colors[], int, int, int); 2377 bool setup(const SkPoint pts[], const SkColor colors[], int, int, int);
2378 2378
2379 virtual void shadeSpan(int x, int y, SkPMColor dstC[], int count) SK_OVERRID E; 2379 virtual void shadeSpan(int x, int y, SkPMColor dstC[], int count) SK_OVERRID E;
2380 2380
2381 SK_DEVELOPER_TO_STRING() 2381 SK_DEVELOPER_TO_STRING()
2382 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkTriColorShader) 2382 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkTriColorShader)
2383 2383
2384 protected: 2384 protected:
2385 SkTriColorShader(SkFlattenableReadBuffer& buffer) : SkShader(buffer) {} 2385 SkTriColorShader(SkReadBuffer& buffer) : SkShader(buffer) {}
2386 2386
2387 private: 2387 private:
2388 SkMatrix fDstToUnit; 2388 SkMatrix fDstToUnit;
2389 SkPMColor fColors[3]; 2389 SkPMColor fColors[3];
2390 2390
2391 typedef SkShader INHERITED; 2391 typedef SkShader INHERITED;
2392 }; 2392 };
2393 2393
2394 bool SkTriColorShader::setup(const SkPoint pts[], const SkColor colors[], 2394 bool SkTriColorShader::setup(const SkPoint pts[], const SkColor colors[],
2395 int index0, int index1, int index2) { 2395 int index0, int index1, int index2) {
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
2820 mask->fImage = SkMask::AllocImage(size); 2820 mask->fImage = SkMask::AllocImage(size);
2821 memset(mask->fImage, 0, mask->computeImageSize()); 2821 memset(mask->fImage, 0, mask->computeImageSize());
2822 } 2822 }
2823 2823
2824 if (SkMask::kJustComputeBounds_CreateMode != mode) { 2824 if (SkMask::kJustComputeBounds_CreateMode != mode) {
2825 draw_into_mask(*mask, devPath, style); 2825 draw_into_mask(*mask, devPath, style);
2826 } 2826 }
2827 2827
2828 return true; 2828 return true;
2829 } 2829 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698