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

Side by Side Diff: include/core/SkCanvas.h

Issue 189963004: Fix the rendering error of SkDraw::drawVertices in gpu path for solid color (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: update document for SkVertState.h, and fix a small bug" Created 6 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
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 #ifndef SkCanvas_DEFINED 8 #ifndef SkCanvas_DEFINED
9 #define SkCanvas_DEFINED 9 #define SkCanvas_DEFINED
10 10
(...skipping 984 matching lines...) Expand 10 before | Expand all | Expand 10 after
995 */ 995 */
996 virtual void drawPicture(SkPicture& picture); 996 virtual void drawPicture(SkPicture& picture);
997 997
998 enum VertexMode { 998 enum VertexMode {
999 kTriangles_VertexMode, 999 kTriangles_VertexMode,
1000 kTriangleStrip_VertexMode, 1000 kTriangleStrip_VertexMode,
1001 kTriangleFan_VertexMode 1001 kTriangleFan_VertexMode
1002 }; 1002 };
1003 1003
1004 /** Draw the array of vertices, interpreted as triangles (based on mode). 1004 /** Draw the array of vertices, interpreted as triangles (based on mode).
1005
1006 If both textures and vertex-colors are NULL, we strokes hairlines with
1007 the paint's color. This behavior is a useful debugging mode to visualize
1008 the mesh.
1009
1005 @param vmode How to interpret the array of vertices 1010 @param vmode How to interpret the array of vertices
1006 @param vertexCount The number of points in the vertices array (and 1011 @param vertexCount The number of points in the vertices array (and
1007 corresponding texs and colors arrays if non-null) 1012 corresponding texs and colors arrays if non-null)
1008 @param vertices Array of vertices for the mesh 1013 @param vertices Array of vertices for the mesh
1009 @param texs May be null. If not null, specifies the coordinate 1014 @param texs May be null. If not null, specifies the coordinate
1010 in _texture_ space (not uv space) for each vertex. 1015 in _texture_ space (not uv space) for each vertex.
1011 @param colors May be null. If not null, specifies a color for each 1016 @param colors May be null. If not null, specifies a color for each
1012 vertex, to be interpolated across the triangle. 1017 vertex, to be interpolated across the triangle.
1013 @param xmode Used if both texs and colors are present. In this 1018 @param xmode Used if both texs and colors are present. In this
1014 case the colors are combined with the texture using mode, 1019 case the colors are combined with the texture using mode,
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after
1498 bool asROBitmap(SkBitmap*) const; 1503 bool asROBitmap(SkBitmap*) const;
1499 1504
1500 private: 1505 private:
1501 SkBitmap fBitmap; // used if peekPixels() fails 1506 SkBitmap fBitmap; // used if peekPixels() fails
1502 const void* fAddr; // NULL on failure 1507 const void* fAddr; // NULL on failure
1503 SkImageInfo fInfo; 1508 SkImageInfo fInfo;
1504 size_t fRowBytes; 1509 size_t fRowBytes;
1505 }; 1510 };
1506 1511
1507 #endif 1512 #endif
OLDNEW
« no previous file with comments | « gyp/core.gypi ('k') | include/core/SkVertState.h » ('j') | include/core/SkVertState.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698