Flutter Engine
The Flutter Engine
Macros | Functions
DrawCommand.cpp File Reference
#include "tools/debugger/DrawCommand.h"
#include "include/core/SkAlphaType.h"
#include "include/core/SkBitmap.h"
#include "include/core/SkBlendMode.h"
#include "include/core/SkBlurTypes.h"
#include "include/core/SkClipOp.h"
#include "include/core/SkColorFilter.h"
#include "include/core/SkColorType.h"
#include "include/core/SkDrawable.h"
#include "include/core/SkFlattenable.h"
#include "include/core/SkFont.h"
#include "include/core/SkFontTypes.h"
#include "include/core/SkImageFilter.h"
#include "include/core/SkImageInfo.h"
#include "include/core/SkMaskFilter.h"
#include "include/core/SkPathEffect.h"
#include "include/core/SkPathTypes.h"
#include "include/core/SkPicture.h"
#include "include/core/SkPixmap.h"
#include "include/core/SkPoint3.h"
#include "include/core/SkRSXform.h"
#include "include/core/SkSamplingOptions.h"
#include "include/core/SkSize.h"
#include "include/core/SkStream.h"
#include "include/core/SkTypeface.h"
#include "include/encode/SkPngEncoder.h"
#include "include/private/base/SkDebug.h"
#include "include/private/base/SkMalloc.h"
#include "include/private/base/SkTo.h"
#include "include/private/gpu/ganesh/GrImageContext.h"
#include "include/utils/SkShadowUtils.h"
#include "src/base/SkAutoMalloc.h"
#include "src/core/SkCanvasPriv.h"
#include "src/core/SkFontPriv.h"
#include "src/core/SkMaskFilterBase.h"
#include "src/core/SkPaintDefaults.h"
#include "src/core/SkRectPriv.h"
#include "src/core/SkTextBlobPriv.h"
#include "src/core/SkWriteBuffer.h"
#include "src/image/SkImage_Base.h"
#include "src/utils/SkJSONWriter.h"
#include "tools/UrlDataManager.h"
#include "tools/debugger/DebugLayerManager.h"
#include "tools/debugger/JsonWriteBuffer.h"
#include <algorithm>
#include <cstring>
#include <utility>

Go to the source code of this file.

Macros

#define DEBUGCANVAS_ATTRIBUTE_DUMP   "dump"
 
#define DEBUGCANVAS_ATTRIBUTE_COMMAND   "command"
 
#define DEBUGCANVAS_ATTRIBUTE_VISIBLE   "visible"
 
#define DEBUGCANVAS_ATTRIBUTE_MATRIX   "matrix"
 
#define DEBUGCANVAS_ATTRIBUTE_DRAWDEPTHTRANS   "drawDepthTranslation"
 
#define DEBUGCANVAS_ATTRIBUTE_COORDS   "coords"
 
#define DEBUGCANVAS_ATTRIBUTE_EDGING   "edging"
 
#define DEBUGCANVAS_ATTRIBUTE_HINTING   "hinting"
 
#define DEBUGCANVAS_ATTRIBUTE_BOUNDS   "bounds"
 
#define DEBUGCANVAS_ATTRIBUTE_PAINT   "paint"
 
#define DEBUGCANVAS_ATTRIBUTE_OUTER   "outer"
 
#define DEBUGCANVAS_ATTRIBUTE_INNER   "inner"
 
#define DEBUGCANVAS_ATTRIBUTE_MODE   "mode"
 
#define DEBUGCANVAS_ATTRIBUTE_POINTS   "points"
 
#define DEBUGCANVAS_ATTRIBUTE_PATH   "path"
 
#define DEBUGCANVAS_ATTRIBUTE_CLUSTERS   "clusters"
 
#define DEBUGCANVAS_ATTRIBUTE_TEXT   "text"
 
#define DEBUGCANVAS_ATTRIBUTE_COLOR   "color"
 
#define DEBUGCANVAS_ATTRIBUTE_ALPHA   "alpha"
 
#define DEBUGCANVAS_ATTRIBUTE_BLENDMODE   "blendMode"
 
#define DEBUGCANVAS_ATTRIBUTE_SAMPLING   "sampling"
 
#define DEBUGCANVAS_ATTRIBUTE_STYLE   "style"
 
#define DEBUGCANVAS_ATTRIBUTE_STROKEWIDTH   "strokeWidth"
 
#define DEBUGCANVAS_ATTRIBUTE_STROKEMITER   "strokeMiter"
 
#define DEBUGCANVAS_ATTRIBUTE_STROKEJOIN   "strokeJoin"
 
#define DEBUGCANVAS_ATTRIBUTE_CAP   "cap"
 
#define DEBUGCANVAS_ATTRIBUTE_ANTIALIAS   "antiAlias"
 
#define DEBUGCANVAS_ATTRIBUTE_DITHER   "dither"
 
#define DEBUGCANVAS_ATTRIBUTE_FAKEBOLDTEXT   "fakeBoldText"
 
#define DEBUGCANVAS_ATTRIBUTE_LINEARTEXT   "linearText"
 
#define DEBUGCANVAS_ATTRIBUTE_SUBPIXELTEXT   "subpixelText"
 
#define DEBUGCANVAS_ATTRIBUTE_DEVKERNTEXT   "devKernText"
 
#define DEBUGCANVAS_ATTRIBUTE_LCDRENDERTEXT   "lcdRenderText"
 
#define DEBUGCANVAS_ATTRIBUTE_EMBEDDEDBITMAPTEXT   "embeddedBitmapText"
 
#define DEBUGCANVAS_ATTRIBUTE_AUTOHINTING   "forceAutoHinting"
 
#define DEBUGCANVAS_ATTRIBUTE_REGION   "region"
 
#define DEBUGCANVAS_ATTRIBUTE_REGIONOP   "op"
 
#define DEBUGCANVAS_ATTRIBUTE_EDGESTYLE   "edgeStyle"
 
#define DEBUGCANVAS_ATTRIBUTE_DEVICEREGION   "deviceRegion"
 
#define DEBUGCANVAS_ATTRIBUTE_BLUR   "blur"
 
#define DEBUGCANVAS_ATTRIBUTE_SIGMA   "sigma"
 
#define DEBUGCANVAS_ATTRIBUTE_QUALITY   "quality"
 
#define DEBUGCANVAS_ATTRIBUTE_TEXTSIZE   "textSize"
 
#define DEBUGCANVAS_ATTRIBUTE_TEXTSCALEX   "textScaleX"
 
#define DEBUGCANVAS_ATTRIBUTE_TEXTSKEWX   "textSkewX"
 
#define DEBUGCANVAS_ATTRIBUTE_DASHING   "dashing"
 
#define DEBUGCANVAS_ATTRIBUTE_INTERVALS   "intervals"
 
#define DEBUGCANVAS_ATTRIBUTE_PHASE   "phase"
 
#define DEBUGCANVAS_ATTRIBUTE_FILLTYPE   "fillType"
 
#define DEBUGCANVAS_ATTRIBUTE_VERBS   "verbs"
 
#define DEBUGCANVAS_ATTRIBUTE_NAME   "name"
 
#define DEBUGCANVAS_ATTRIBUTE_DATA   "data"
 
#define DEBUGCANVAS_ATTRIBUTE_VALUES   "values"
 
#define DEBUGCANVAS_ATTRIBUTE_SHADER   "shader"
 
#define DEBUGCANVAS_ATTRIBUTE_PATHEFFECT   "pathEffect"
 
#define DEBUGCANVAS_ATTRIBUTE_MASKFILTER   "maskFilter"
 
#define DEBUGCANVAS_ATTRIBUTE_XFERMODE   "xfermode"
 
#define DEBUGCANVAS_ATTRIBUTE_BACKDROP   "backdrop"
 
#define DEBUGCANVAS_ATTRIBUTE_COLORFILTER   "colorfilter"
 
#define DEBUGCANVAS_ATTRIBUTE_IMAGEFILTER   "imagefilter"
 
#define DEBUGCANVAS_ATTRIBUTE_IMAGE   "image"
 
#define DEBUGCANVAS_ATTRIBUTE_IMAGE_INDEX   "imageIndex"
 
#define DEBUGCANVAS_ATTRIBUTE_BITMAP   "bitmap"
 
#define DEBUGCANVAS_ATTRIBUTE_SRC   "src"
 
#define DEBUGCANVAS_ATTRIBUTE_DST   "dst"
 
#define DEBUGCANVAS_ATTRIBUTE_CENTER   "center"
 
#define DEBUGCANVAS_ATTRIBUTE_STRICT   "strict"
 
#define DEBUGCANVAS_ATTRIBUTE_DESCRIPTION   "description"
 
#define DEBUGCANVAS_ATTRIBUTE_X   "x"
 
#define DEBUGCANVAS_ATTRIBUTE_Y   "y"
 
#define DEBUGCANVAS_ATTRIBUTE_RUNS   "runs"
 
#define DEBUGCANVAS_ATTRIBUTE_POSITIONS   "positions"
 
#define DEBUGCANVAS_ATTRIBUTE_GLYPHS   "glyphs"
 
#define DEBUGCANVAS_ATTRIBUTE_FONT   "font"
 
#define DEBUGCANVAS_ATTRIBUTE_TYPEFACE   "typeface"
 
#define DEBUGCANVAS_ATTRIBUTE_CUBICS   "cubics"
 
#define DEBUGCANVAS_ATTRIBUTE_COLORS   "colors"
 
#define DEBUGCANVAS_ATTRIBUTE_TEXTURECOORDS   "textureCoords"
 
#define DEBUGCANVAS_ATTRIBUTE_STARTANGLE   "startAngle"
 
#define DEBUGCANVAS_ATTRIBUTE_SWEEPANGLE   "sweepAngle"
 
#define DEBUGCANVAS_ATTRIBUTE_USECENTER   "useCenter"
 
#define DEBUGCANVAS_ATTRIBUTE_SHORTDESC   "shortDesc"
 
#define DEBUGCANVAS_ATTRIBUTE_UNIQUE_ID   "uniqueID"
 
#define DEBUGCANVAS_ATTRIBUTE_WIDTH   "width"
 
#define DEBUGCANVAS_ATTRIBUTE_HEIGHT   "height"
 
#define DEBUGCANVAS_ATTRIBUTE_ALPHA   "alpha"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICE   "lattice"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICEXCOUNT   "xCount"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICEYCOUNT   "yCount"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICEXDIVS   "xDivs"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICEYDIVS   "yDivs"
 
#define DEBUGCANVAS_ATTRIBUTE_LATTICEFLAGS   "flags"
 
#define DEBUGCANVAS_ATTRIBUTE_ZPLANE   "zPlane"
 
#define DEBUGCANVAS_ATTRIBUTE_LIGHTPOSITION   "lightPositions"
 
#define DEBUGCANVAS_ATTRIBUTE_AMBIENTCOLOR   "ambientColor"
 
#define DEBUGCANVAS_ATTRIBUTE_SPOTCOLOR   "spotColor"
 
#define DEBUGCANVAS_ATTRIBUTE_LIGHTRADIUS   "lightRadius"
 
#define DEBUGCANVAS_ATTRIBUTE_LAYERNODEID   "layerNodeId"
 
#define DEBUGCANVAS_VERB_MOVE   "move"
 
#define DEBUGCANVAS_VERB_LINE   "line"
 
#define DEBUGCANVAS_VERB_QUAD   "quad"
 
#define DEBUGCANVAS_VERB_CUBIC   "cubic"
 
#define DEBUGCANVAS_VERB_CONIC   "conic"
 
#define DEBUGCANVAS_VERB_CLOSE   "close"
 
#define DEBUGCANVAS_STYLE_FILL   "fill"
 
#define DEBUGCANVAS_STYLE_STROKE   "stroke"
 
#define DEBUGCANVAS_STYLE_STROKEANDFILL   "strokeAndFill"
 
#define DEBUGCANVAS_POINTMODE_POINTS   "points"
 
#define DEBUGCANVAS_POINTMODE_LINES   "lines"
 
#define DEBUGCANVAS_POINTMODE_POLYGON   "polygon"
 
#define DEBUGCANVAS_CLIPOP_DIFFERENCE   "difference"
 
#define DEBUGCANVAS_CLIPOP_INTERSECT   "intersect"
 
#define DEBUGCANVAS_BLURSTYLE_NORMAL   "normal"
 
#define DEBUGCANVAS_BLURSTYLE_SOLID   "solid"
 
#define DEBUGCANVAS_BLURSTYLE_OUTER   "outer"
 
#define DEBUGCANVAS_BLURSTYLE_INNER   "inner"
 
#define DEBUGCANVAS_BLURQUALITY_LOW   "low"
 
#define DEBUGCANVAS_BLURQUALITY_HIGH   "high"
 
#define DEBUGCANVAS_FILLTYPE_WINDING   "winding"
 
#define DEBUGCANVAS_FILLTYPE_EVENODD   "evenOdd"
 
#define DEBUGCANVAS_FILLTYPE_INVERSEWINDING   "inverseWinding"
 
#define DEBUGCANVAS_FILLTYPE_INVERSEEVENODD   "inverseEvenOdd"
 
#define DEBUGCANVAS_CAP_BUTT   "butt"
 
#define DEBUGCANVAS_CAP_ROUND   "round"
 
#define DEBUGCANVAS_CAP_SQUARE   "square"
 
#define DEBUGCANVAS_MITER_JOIN   "miter"
 
#define DEBUGCANVAS_ROUND_JOIN   "round"
 
#define DEBUGCANVAS_BEVEL_JOIN   "bevel"
 
#define DEBUGCANVAS_COLORTYPE_ARGB4444   "ARGB4444"
 
#define DEBUGCANVAS_COLORTYPE_RGBA8888   "RGBA8888"
 
#define DEBUGCANVAS_COLORTYPE_BGRA8888   "BGRA8888"
 
#define DEBUGCANVAS_COLORTYPE_565   "565"
 
#define DEBUGCANVAS_COLORTYPE_GRAY8   "Gray8"
 
#define DEBUGCANVAS_COLORTYPE_INDEX8   "Index8"
 
#define DEBUGCANVAS_COLORTYPE_ALPHA8   "Alpha8"
 
#define DEBUGCANVAS_ALPHATYPE_OPAQUE   "opaque"
 
#define DEBUGCANVAS_ALPHATYPE_PREMUL   "premul"
 
#define DEBUGCANVAS_ALPHATYPE_UNPREMUL   "unpremul"
 
#define DEBUGCANVAS_ALPHATYPE_UNKNOWN   "unknown"
 
#define DEBUGCANVAS_HINTING_NONE   "none"
 
#define DEBUGCANVAS_HINTING_SLIGHT   "slight"
 
#define DEBUGCANVAS_HINTING_NORMAL   "normal"
 
#define DEBUGCANVAS_HINTING_FULL   "full"
 
#define DEBUGCANVAS_EDGING_ALIAS   "alias"
 
#define DEBUGCANVAS_EDGING_ANTIALIAS   "antialias"
 
#define DEBUGCANVAS_EDGING_SUBPIXELANTIALIAS   "subpixelantialias"
 
#define DEBUGCANVAS_SHADOWFLAG_TRANSPARENT_OCC   "transparentOccluder"
 
#define DEBUGCANVAS_SHADOWFLAG_GEOMETRIC_ONLY   "geometricOnly"
 

Functions

static SkStringstr_append (SkString *str, const SkRect &r)
 
static void make_json_rrect (SkJSONWriter &writer, const SkRRect &rrect)
 
static const char * clipop_name (SkClipOp op)
 
static const char * pointmode_name (SkCanvas::PointMode mode)
 
static void store_scalar (SkJSONWriter &writer, const char *key, SkScalar value, SkScalar defaultValue)
 
static void store_bool (SkJSONWriter &writer, const char *key, bool value, bool defaultValue)
 
static SkString encode_data (const void *bytes, size_t count, const char *contentType, UrlDataManager &urlDataManager)
 
static const char * color_type_name (SkColorType colorType)
 
static const char * alpha_type_name (SkAlphaType alphaType)
 
static void apply_font_hinting (const SkFont &font, SkJSONWriter &writer)
 
static void apply_font_edging (const SkFont &font, SkJSONWriter &writer)
 
static void apply_paint_color (const SkPaint &paint, SkJSONWriter &writer)
 
static void apply_paint_style (const SkPaint &paint, SkJSONWriter &writer)
 
static void apply_paint_cap (const SkPaint &paint, SkJSONWriter &writer)
 
static void apply_paint_join (const SkPaint &paint, SkJSONWriter &writer)
 
static void apply_paint_maskfilter (const SkPaint &paint, SkJSONWriter &writer, UrlDataManager &urlDataManager)
 
static void apply_paint_patheffect (const SkPaint &paint, SkJSONWriter &writer, UrlDataManager &urlDataManager)
 
static void apply_font_typeface (const SkFont &font, SkJSONWriter &writer, UrlDataManager &urlDataManager)
 
static void apply_flattenable (const char *key, SkFlattenable *flattenable, SkJSONWriter &writer, UrlDataManager &urlDataManager)
 
static void MakeJsonFont (const SkFont &font, SkJSONWriter &writer, UrlDataManager &urlDataManager)
 

Macro Definition Documentation

◆ DEBUGCANVAS_ALPHATYPE_OPAQUE

#define DEBUGCANVAS_ALPHATYPE_OPAQUE   "opaque"

Definition at line 210 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ALPHATYPE_PREMUL

#define DEBUGCANVAS_ALPHATYPE_PREMUL   "premul"

Definition at line 211 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ALPHATYPE_UNKNOWN

#define DEBUGCANVAS_ALPHATYPE_UNKNOWN   "unknown"

Definition at line 213 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ALPHATYPE_UNPREMUL

#define DEBUGCANVAS_ALPHATYPE_UNPREMUL   "unpremul"

Definition at line 212 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_ALPHA [1/2]

#define DEBUGCANVAS_ATTRIBUTE_ALPHA   "alpha"

Definition at line 149 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_ALPHA [2/2]

#define DEBUGCANVAS_ATTRIBUTE_ALPHA   "alpha"

Definition at line 149 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_AMBIENTCOLOR

#define DEBUGCANVAS_ATTRIBUTE_AMBIENTCOLOR   "ambientColor"

Definition at line 158 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_ANTIALIAS

#define DEBUGCANVAS_ATTRIBUTE_ANTIALIAS   "antiAlias"

Definition at line 90 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_AUTOHINTING

#define DEBUGCANVAS_ATTRIBUTE_AUTOHINTING   "forceAutoHinting"

Definition at line 98 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_BACKDROP

#define DEBUGCANVAS_ATTRIBUTE_BACKDROP   "backdrop"

Definition at line 121 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_BITMAP

#define DEBUGCANVAS_ATTRIBUTE_BITMAP   "bitmap"

Definition at line 126 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_BLENDMODE

#define DEBUGCANVAS_ATTRIBUTE_BLENDMODE   "blendMode"

Definition at line 83 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_BLUR

#define DEBUGCANVAS_ATTRIBUTE_BLUR   "blur"

Definition at line 103 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_BOUNDS

#define DEBUGCANVAS_ATTRIBUTE_BOUNDS   "bounds"

Definition at line 72 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_CAP

#define DEBUGCANVAS_ATTRIBUTE_CAP   "cap"

Definition at line 89 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_CENTER

#define DEBUGCANVAS_ATTRIBUTE_CENTER   "center"

Definition at line 129 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_CLUSTERS

#define DEBUGCANVAS_ATTRIBUTE_CLUSTERS   "clusters"

Definition at line 79 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_COLOR

#define DEBUGCANVAS_ATTRIBUTE_COLOR   "color"

Definition at line 81 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_COLORFILTER

#define DEBUGCANVAS_ATTRIBUTE_COLORFILTER   "colorfilter"

Definition at line 122 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_COLORS

#define DEBUGCANVAS_ATTRIBUTE_COLORS   "colors"

Definition at line 140 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_COMMAND

#define DEBUGCANVAS_ATTRIBUTE_COMMAND   "command"

Definition at line 65 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_COORDS

#define DEBUGCANVAS_ATTRIBUTE_COORDS   "coords"

Definition at line 69 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_CUBICS

#define DEBUGCANVAS_ATTRIBUTE_CUBICS   "cubics"

Definition at line 139 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DASHING

#define DEBUGCANVAS_ATTRIBUTE_DASHING   "dashing"

Definition at line 109 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DATA

#define DEBUGCANVAS_ATTRIBUTE_DATA   "data"

Definition at line 115 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DESCRIPTION

#define DEBUGCANVAS_ATTRIBUTE_DESCRIPTION   "description"

Definition at line 131 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DEVICEREGION

#define DEBUGCANVAS_ATTRIBUTE_DEVICEREGION   "deviceRegion"

Definition at line 102 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DEVKERNTEXT

#define DEBUGCANVAS_ATTRIBUTE_DEVKERNTEXT   "devKernText"

Definition at line 95 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DITHER

#define DEBUGCANVAS_ATTRIBUTE_DITHER   "dither"

Definition at line 91 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DRAWDEPTHTRANS

#define DEBUGCANVAS_ATTRIBUTE_DRAWDEPTHTRANS   "drawDepthTranslation"

Definition at line 68 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DST

#define DEBUGCANVAS_ATTRIBUTE_DST   "dst"

Definition at line 128 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_DUMP

#define DEBUGCANVAS_ATTRIBUTE_DUMP   "dump"

Definition at line 64 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_EDGESTYLE

#define DEBUGCANVAS_ATTRIBUTE_EDGESTYLE   "edgeStyle"

Definition at line 101 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_EDGING

#define DEBUGCANVAS_ATTRIBUTE_EDGING   "edging"

Definition at line 70 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_EMBEDDEDBITMAPTEXT

#define DEBUGCANVAS_ATTRIBUTE_EMBEDDEDBITMAPTEXT   "embeddedBitmapText"

Definition at line 97 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_FAKEBOLDTEXT

#define DEBUGCANVAS_ATTRIBUTE_FAKEBOLDTEXT   "fakeBoldText"

Definition at line 92 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_FILLTYPE

#define DEBUGCANVAS_ATTRIBUTE_FILLTYPE   "fillType"

Definition at line 112 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_FONT

#define DEBUGCANVAS_ATTRIBUTE_FONT   "font"

Definition at line 137 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_GLYPHS

#define DEBUGCANVAS_ATTRIBUTE_GLYPHS   "glyphs"

Definition at line 136 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_HEIGHT

#define DEBUGCANVAS_ATTRIBUTE_HEIGHT   "height"

Definition at line 148 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_HINTING

#define DEBUGCANVAS_ATTRIBUTE_HINTING   "hinting"

Definition at line 71 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_IMAGE

#define DEBUGCANVAS_ATTRIBUTE_IMAGE   "image"

Definition at line 124 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_IMAGE_INDEX

#define DEBUGCANVAS_ATTRIBUTE_IMAGE_INDEX   "imageIndex"

Definition at line 125 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_IMAGEFILTER

#define DEBUGCANVAS_ATTRIBUTE_IMAGEFILTER   "imagefilter"

Definition at line 123 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_INNER

#define DEBUGCANVAS_ATTRIBUTE_INNER   "inner"

Definition at line 75 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_INTERVALS

#define DEBUGCANVAS_ATTRIBUTE_INTERVALS   "intervals"

Definition at line 110 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICE

#define DEBUGCANVAS_ATTRIBUTE_LATTICE   "lattice"

Definition at line 150 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICEFLAGS

#define DEBUGCANVAS_ATTRIBUTE_LATTICEFLAGS   "flags"

Definition at line 155 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICEXCOUNT

#define DEBUGCANVAS_ATTRIBUTE_LATTICEXCOUNT   "xCount"

Definition at line 151 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICEXDIVS

#define DEBUGCANVAS_ATTRIBUTE_LATTICEXDIVS   "xDivs"

Definition at line 153 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICEYCOUNT

#define DEBUGCANVAS_ATTRIBUTE_LATTICEYCOUNT   "yCount"

Definition at line 152 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LATTICEYDIVS

#define DEBUGCANVAS_ATTRIBUTE_LATTICEYDIVS   "yDivs"

Definition at line 154 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LAYERNODEID

#define DEBUGCANVAS_ATTRIBUTE_LAYERNODEID   "layerNodeId"

Definition at line 161 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LCDRENDERTEXT

#define DEBUGCANVAS_ATTRIBUTE_LCDRENDERTEXT   "lcdRenderText"

Definition at line 96 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LIGHTPOSITION

#define DEBUGCANVAS_ATTRIBUTE_LIGHTPOSITION   "lightPositions"

Definition at line 157 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LIGHTRADIUS

#define DEBUGCANVAS_ATTRIBUTE_LIGHTRADIUS   "lightRadius"

Definition at line 160 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_LINEARTEXT

#define DEBUGCANVAS_ATTRIBUTE_LINEARTEXT   "linearText"

Definition at line 93 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_MASKFILTER

#define DEBUGCANVAS_ATTRIBUTE_MASKFILTER   "maskFilter"

Definition at line 119 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_MATRIX

#define DEBUGCANVAS_ATTRIBUTE_MATRIX   "matrix"

Definition at line 67 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_MODE

#define DEBUGCANVAS_ATTRIBUTE_MODE   "mode"

Definition at line 76 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_NAME

#define DEBUGCANVAS_ATTRIBUTE_NAME   "name"

Definition at line 114 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_OUTER

#define DEBUGCANVAS_ATTRIBUTE_OUTER   "outer"

Definition at line 74 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_PAINT

#define DEBUGCANVAS_ATTRIBUTE_PAINT   "paint"

Definition at line 73 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_PATH

#define DEBUGCANVAS_ATTRIBUTE_PATH   "path"

Definition at line 78 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_PATHEFFECT

#define DEBUGCANVAS_ATTRIBUTE_PATHEFFECT   "pathEffect"

Definition at line 118 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_PHASE

#define DEBUGCANVAS_ATTRIBUTE_PHASE   "phase"

Definition at line 111 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_POINTS

#define DEBUGCANVAS_ATTRIBUTE_POINTS   "points"

Definition at line 77 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_POSITIONS

#define DEBUGCANVAS_ATTRIBUTE_POSITIONS   "positions"

Definition at line 135 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_QUALITY

#define DEBUGCANVAS_ATTRIBUTE_QUALITY   "quality"

Definition at line 105 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_REGION

#define DEBUGCANVAS_ATTRIBUTE_REGION   "region"

Definition at line 99 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_REGIONOP

#define DEBUGCANVAS_ATTRIBUTE_REGIONOP   "op"

Definition at line 100 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_RUNS

#define DEBUGCANVAS_ATTRIBUTE_RUNS   "runs"

Definition at line 134 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SAMPLING

#define DEBUGCANVAS_ATTRIBUTE_SAMPLING   "sampling"

Definition at line 84 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SHADER

#define DEBUGCANVAS_ATTRIBUTE_SHADER   "shader"

Definition at line 117 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SHORTDESC

#define DEBUGCANVAS_ATTRIBUTE_SHORTDESC   "shortDesc"

Definition at line 145 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SIGMA

#define DEBUGCANVAS_ATTRIBUTE_SIGMA   "sigma"

Definition at line 104 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SPOTCOLOR

#define DEBUGCANVAS_ATTRIBUTE_SPOTCOLOR   "spotColor"

Definition at line 159 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SRC

#define DEBUGCANVAS_ATTRIBUTE_SRC   "src"

Definition at line 127 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STARTANGLE

#define DEBUGCANVAS_ATTRIBUTE_STARTANGLE   "startAngle"

Definition at line 142 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STRICT

#define DEBUGCANVAS_ATTRIBUTE_STRICT   "strict"

Definition at line 130 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STROKEJOIN

#define DEBUGCANVAS_ATTRIBUTE_STROKEJOIN   "strokeJoin"

Definition at line 88 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STROKEMITER

#define DEBUGCANVAS_ATTRIBUTE_STROKEMITER   "strokeMiter"

Definition at line 87 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STROKEWIDTH

#define DEBUGCANVAS_ATTRIBUTE_STROKEWIDTH   "strokeWidth"

Definition at line 86 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_STYLE

#define DEBUGCANVAS_ATTRIBUTE_STYLE   "style"

Definition at line 85 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SUBPIXELTEXT

#define DEBUGCANVAS_ATTRIBUTE_SUBPIXELTEXT   "subpixelText"

Definition at line 94 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_SWEEPANGLE

#define DEBUGCANVAS_ATTRIBUTE_SWEEPANGLE   "sweepAngle"

Definition at line 143 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TEXT

#define DEBUGCANVAS_ATTRIBUTE_TEXT   "text"

Definition at line 80 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TEXTSCALEX

#define DEBUGCANVAS_ATTRIBUTE_TEXTSCALEX   "textScaleX"

Definition at line 107 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TEXTSIZE

#define DEBUGCANVAS_ATTRIBUTE_TEXTSIZE   "textSize"

Definition at line 106 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TEXTSKEWX

#define DEBUGCANVAS_ATTRIBUTE_TEXTSKEWX   "textSkewX"

Definition at line 108 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TEXTURECOORDS

#define DEBUGCANVAS_ATTRIBUTE_TEXTURECOORDS   "textureCoords"

Definition at line 141 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_TYPEFACE

#define DEBUGCANVAS_ATTRIBUTE_TYPEFACE   "typeface"

Definition at line 138 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_UNIQUE_ID

#define DEBUGCANVAS_ATTRIBUTE_UNIQUE_ID   "uniqueID"

Definition at line 146 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_USECENTER

#define DEBUGCANVAS_ATTRIBUTE_USECENTER   "useCenter"

Definition at line 144 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_VALUES

#define DEBUGCANVAS_ATTRIBUTE_VALUES   "values"

Definition at line 116 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_VERBS

#define DEBUGCANVAS_ATTRIBUTE_VERBS   "verbs"

Definition at line 113 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_VISIBLE

#define DEBUGCANVAS_ATTRIBUTE_VISIBLE   "visible"

Definition at line 66 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_WIDTH

#define DEBUGCANVAS_ATTRIBUTE_WIDTH   "width"

Definition at line 147 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_X

#define DEBUGCANVAS_ATTRIBUTE_X   "x"

Definition at line 132 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_XFERMODE

#define DEBUGCANVAS_ATTRIBUTE_XFERMODE   "xfermode"

Definition at line 120 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_Y

#define DEBUGCANVAS_ATTRIBUTE_Y   "y"

Definition at line 133 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ATTRIBUTE_ZPLANE

#define DEBUGCANVAS_ATTRIBUTE_ZPLANE   "zPlane"

Definition at line 156 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BEVEL_JOIN

#define DEBUGCANVAS_BEVEL_JOIN   "bevel"

Definition at line 200 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURQUALITY_HIGH

#define DEBUGCANVAS_BLURQUALITY_HIGH   "high"

Definition at line 187 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURQUALITY_LOW

#define DEBUGCANVAS_BLURQUALITY_LOW   "low"

Definition at line 186 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURSTYLE_INNER

#define DEBUGCANVAS_BLURSTYLE_INNER   "inner"

Definition at line 184 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURSTYLE_NORMAL

#define DEBUGCANVAS_BLURSTYLE_NORMAL   "normal"

Definition at line 181 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURSTYLE_OUTER

#define DEBUGCANVAS_BLURSTYLE_OUTER   "outer"

Definition at line 183 of file DrawCommand.cpp.

◆ DEBUGCANVAS_BLURSTYLE_SOLID

#define DEBUGCANVAS_BLURSTYLE_SOLID   "solid"

Definition at line 182 of file DrawCommand.cpp.

◆ DEBUGCANVAS_CAP_BUTT

#define DEBUGCANVAS_CAP_BUTT   "butt"

Definition at line 194 of file DrawCommand.cpp.

◆ DEBUGCANVAS_CAP_ROUND

#define DEBUGCANVAS_CAP_ROUND   "round"

Definition at line 195 of file DrawCommand.cpp.

◆ DEBUGCANVAS_CAP_SQUARE

#define DEBUGCANVAS_CAP_SQUARE   "square"

Definition at line 196 of file DrawCommand.cpp.

◆ DEBUGCANVAS_CLIPOP_DIFFERENCE

#define DEBUGCANVAS_CLIPOP_DIFFERENCE   "difference"

Definition at line 178 of file DrawCommand.cpp.

◆ DEBUGCANVAS_CLIPOP_INTERSECT

#define DEBUGCANVAS_CLIPOP_INTERSECT   "intersect"

Definition at line 179 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_565

#define DEBUGCANVAS_COLORTYPE_565   "565"

Definition at line 205 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_ALPHA8

#define DEBUGCANVAS_COLORTYPE_ALPHA8   "Alpha8"

Definition at line 208 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_ARGB4444

#define DEBUGCANVAS_COLORTYPE_ARGB4444   "ARGB4444"

Definition at line 202 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_BGRA8888

#define DEBUGCANVAS_COLORTYPE_BGRA8888   "BGRA8888"

Definition at line 204 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_GRAY8

#define DEBUGCANVAS_COLORTYPE_GRAY8   "Gray8"

Definition at line 206 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_INDEX8

#define DEBUGCANVAS_COLORTYPE_INDEX8   "Index8"

Definition at line 207 of file DrawCommand.cpp.

◆ DEBUGCANVAS_COLORTYPE_RGBA8888

#define DEBUGCANVAS_COLORTYPE_RGBA8888   "RGBA8888"

Definition at line 203 of file DrawCommand.cpp.

◆ DEBUGCANVAS_EDGING_ALIAS

#define DEBUGCANVAS_EDGING_ALIAS   "alias"

Definition at line 220 of file DrawCommand.cpp.

◆ DEBUGCANVAS_EDGING_ANTIALIAS

#define DEBUGCANVAS_EDGING_ANTIALIAS   "antialias"

Definition at line 221 of file DrawCommand.cpp.

◆ DEBUGCANVAS_EDGING_SUBPIXELANTIALIAS

#define DEBUGCANVAS_EDGING_SUBPIXELANTIALIAS   "subpixelantialias"

Definition at line 222 of file DrawCommand.cpp.

◆ DEBUGCANVAS_FILLTYPE_EVENODD

#define DEBUGCANVAS_FILLTYPE_EVENODD   "evenOdd"

Definition at line 190 of file DrawCommand.cpp.

◆ DEBUGCANVAS_FILLTYPE_INVERSEEVENODD

#define DEBUGCANVAS_FILLTYPE_INVERSEEVENODD   "inverseEvenOdd"

Definition at line 192 of file DrawCommand.cpp.

◆ DEBUGCANVAS_FILLTYPE_INVERSEWINDING

#define DEBUGCANVAS_FILLTYPE_INVERSEWINDING   "inverseWinding"

Definition at line 191 of file DrawCommand.cpp.

◆ DEBUGCANVAS_FILLTYPE_WINDING

#define DEBUGCANVAS_FILLTYPE_WINDING   "winding"

Definition at line 189 of file DrawCommand.cpp.

◆ DEBUGCANVAS_HINTING_FULL

#define DEBUGCANVAS_HINTING_FULL   "full"

Definition at line 218 of file DrawCommand.cpp.

◆ DEBUGCANVAS_HINTING_NONE

#define DEBUGCANVAS_HINTING_NONE   "none"

Definition at line 215 of file DrawCommand.cpp.

◆ DEBUGCANVAS_HINTING_NORMAL

#define DEBUGCANVAS_HINTING_NORMAL   "normal"

Definition at line 217 of file DrawCommand.cpp.

◆ DEBUGCANVAS_HINTING_SLIGHT

#define DEBUGCANVAS_HINTING_SLIGHT   "slight"

Definition at line 216 of file DrawCommand.cpp.

◆ DEBUGCANVAS_MITER_JOIN

#define DEBUGCANVAS_MITER_JOIN   "miter"

Definition at line 198 of file DrawCommand.cpp.

◆ DEBUGCANVAS_POINTMODE_LINES

#define DEBUGCANVAS_POINTMODE_LINES   "lines"

Definition at line 175 of file DrawCommand.cpp.

◆ DEBUGCANVAS_POINTMODE_POINTS

#define DEBUGCANVAS_POINTMODE_POINTS   "points"

Definition at line 174 of file DrawCommand.cpp.

◆ DEBUGCANVAS_POINTMODE_POLYGON

#define DEBUGCANVAS_POINTMODE_POLYGON   "polygon"

Definition at line 176 of file DrawCommand.cpp.

◆ DEBUGCANVAS_ROUND_JOIN

#define DEBUGCANVAS_ROUND_JOIN   "round"

Definition at line 199 of file DrawCommand.cpp.

◆ DEBUGCANVAS_SHADOWFLAG_GEOMETRIC_ONLY

#define DEBUGCANVAS_SHADOWFLAG_GEOMETRIC_ONLY   "geometricOnly"

Definition at line 225 of file DrawCommand.cpp.

◆ DEBUGCANVAS_SHADOWFLAG_TRANSPARENT_OCC

#define DEBUGCANVAS_SHADOWFLAG_TRANSPARENT_OCC   "transparentOccluder"

Definition at line 224 of file DrawCommand.cpp.

◆ DEBUGCANVAS_STYLE_FILL

#define DEBUGCANVAS_STYLE_FILL   "fill"

Definition at line 170 of file DrawCommand.cpp.

◆ DEBUGCANVAS_STYLE_STROKE

#define DEBUGCANVAS_STYLE_STROKE   "stroke"

Definition at line 171 of file DrawCommand.cpp.

◆ DEBUGCANVAS_STYLE_STROKEANDFILL

#define DEBUGCANVAS_STYLE_STROKEANDFILL   "strokeAndFill"

Definition at line 172 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_CLOSE

#define DEBUGCANVAS_VERB_CLOSE   "close"

Definition at line 168 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_CONIC

#define DEBUGCANVAS_VERB_CONIC   "conic"

Definition at line 167 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_CUBIC

#define DEBUGCANVAS_VERB_CUBIC   "cubic"

Definition at line 166 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_LINE

#define DEBUGCANVAS_VERB_LINE   "line"

Definition at line 164 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_MOVE

#define DEBUGCANVAS_VERB_MOVE   "move"

Definition at line 163 of file DrawCommand.cpp.

◆ DEBUGCANVAS_VERB_QUAD

#define DEBUGCANVAS_VERB_QUAD   "quad"

Definition at line 165 of file DrawCommand.cpp.

Function Documentation

◆ alpha_type_name()

static const char * alpha_type_name ( SkAlphaType  alphaType)
static

Definition at line 723 of file DrawCommand.cpp.

723 {
724 switch (alphaType) {
728 default: SkASSERT(false); return DEBUGCANVAS_ALPHATYPE_OPAQUE;
729 }
730}
#define DEBUGCANVAS_ALPHATYPE_OPAQUE
#define DEBUGCANVAS_ALPHATYPE_UNPREMUL
#define DEBUGCANVAS_ALPHATYPE_PREMUL
kUnpremul_SkAlphaType
@ kOpaque_SkAlphaType
pixel is opaque
Definition: SkAlphaType.h:28
@ kPremul_SkAlphaType
pixel components are premultiplied by alpha
Definition: SkAlphaType.h:29
#define SkASSERT(cond)
Definition: SkAssert.h:116

◆ apply_flattenable()

static void apply_flattenable ( const char *  key,
SkFlattenable flattenable,
SkJSONWriter writer,
UrlDataManager urlDataManager 
)
static

Definition at line 917 of file DrawCommand.cpp.

920 {
921 if (flattenable != nullptr) {
922 writer.beginObject(key);
923 DrawCommand::flatten(flattenable, writer, urlDataManager);
924 writer.endObject();
925 }
926}
static void flatten(const SkFlattenable *flattenable, SkJSONWriter &writer, UrlDataManager &urlDataManager)
void beginObject(const char *name=nullptr, bool multiline=true)
Definition: SkJSONWriter.h:114
void endObject()
Definition: SkJSONWriter.h:126

◆ apply_font_edging()

static void apply_font_edging ( const SkFont font,
SkJSONWriter writer 
)
static

Definition at line 763 of file DrawCommand.cpp.

763 {
764 switch (font.getEdging()) {
767 break;
770 break;
774 break;
775 }
776}
#define DEBUGCANVAS_EDGING_ANTIALIAS
#define DEBUGCANVAS_ATTRIBUTE_EDGING
Definition: DrawCommand.cpp:70
#define DEBUGCANVAS_EDGING_SUBPIXELANTIALIAS
#define DEBUGCANVAS_EDGING_ALIAS
@ kAntiAlias
may have transparent pixels on glyph edges
@ kAlias
no transparent pixels on glyph edges
@ kSubpixelAntiAlias
glyph positioned in pixel using transparency
void appendNString(char const (&value)[N])
Definition: SkJSONWriter.h:220
font
Font Metadata and Metrics.

◆ apply_font_hinting()

static void apply_font_hinting ( const SkFont font,
SkJSONWriter writer 
)
static

Definition at line 743 of file DrawCommand.cpp.

743 {
744 SkFontHinting hinting = font.getHinting();
745 if (hinting != SkPaintDefaults_Hinting) {
746 switch (hinting) {
749 break;
752 break;
755 break;
758 break;
759 }
760 }
761}
#define DEBUGCANVAS_HINTING_NORMAL
#define DEBUGCANVAS_ATTRIBUTE_HINTING
Definition: DrawCommand.cpp:71
#define DEBUGCANVAS_HINTING_FULL
#define DEBUGCANVAS_HINTING_NONE
#define DEBUGCANVAS_HINTING_SLIGHT
#define SkPaintDefaults_Hinting
SkFontHinting
Definition: SkFontTypes.h:18
@ kNormal
glyph outlines modified to improve constrast
@ kNone
glyph outlines unchanged
@ kSlight
minimal modification to improve constrast
@ kFull
modifies glyph outlines for maximum constrast

◆ apply_font_typeface()

static void apply_font_typeface ( const SkFont font,
SkJSONWriter writer,
UrlDataManager urlDataManager 
)
static

Definition at line 899 of file DrawCommand.cpp.

901 {
902 SkTypeface* typeface = font.getTypeface();
903 if (typeface != nullptr) {
906 typeface->serialize(&buffer);
907 void* data = sk_malloc_throw(buffer.bytesWritten());
908 buffer.copyTo(data);
909 SkString url = encode_data(
910 data, buffer.bytesWritten(), "application/octet-stream", urlDataManager);
912 sk_free(data);
913 writer.endObject();
914 }
915}
#define DEBUGCANVAS_ATTRIBUTE_DATA
static SkString encode_data(const void *bytes, size_t count, const char *contentType, UrlDataManager &urlDataManager)
#define DEBUGCANVAS_ATTRIBUTE_TYPEFACE
SK_API void sk_free(void *)
static void * sk_malloc_throw(size_t size)
Definition: SkMalloc.h:67
void appendString(const char *value, size_t size)
Definition: SkJSONWriter.h:176
void serialize(SkWStream *, SerializeBehavior=SerializeBehavior::kIncludeDataIfLocal) const
Definition: SkTypeface.cpp:202
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
Definition: switches.h:126
std::shared_ptr< const fml::Mapping > data
Definition: texture_gles.cc:63

◆ apply_paint_cap()

static void apply_paint_cap ( const SkPaint paint,
SkJSONWriter writer 
)
static

Definition at line 803 of file DrawCommand.cpp.

803 {
804 SkPaint::Cap cap = paint.getStrokeCap();
805 if (cap != SkPaint::kDefault_Cap) {
806 switch (cap) {
809 break;
812 break;
815 break;
816 default: SkASSERT(false);
817 }
818 }
819}
#define DEBUGCANVAS_ATTRIBUTE_CAP
Definition: DrawCommand.cpp:89
#define DEBUGCANVAS_CAP_SQUARE
#define DEBUGCANVAS_CAP_BUTT
#define DEBUGCANVAS_CAP_ROUND
@ kDefault_Cap
equivalent to kButt_Cap
Definition: SkPaint.h:338
@ kRound_Cap
adds circle
Definition: SkPaint.h:335
@ kButt_Cap
no stroke extension
Definition: SkPaint.h:334
@ kSquare_Cap
adds square
Definition: SkPaint.h:336
const Paint & paint
Definition: color_source.cc:38

◆ apply_paint_color()

static void apply_paint_color ( const SkPaint paint,
SkJSONWriter writer 
)
static

Definition at line 778 of file DrawCommand.cpp.

778 {
779 SkColor color = paint.getColor();
780 if (color != SK_ColorBLACK) {
783 }
784}
#define DEBUGCANVAS_ATTRIBUTE_COLOR
Definition: DrawCommand.cpp:81
uint32_t SkColor
Definition: SkColor.h:37
constexpr SkColor SK_ColorBLACK
Definition: SkColor.h:103
static void MakeJsonColor(SkJSONWriter &, const SkColor color)
void appendName(const char *name)
Definition: SkJSONWriter.h:90
DlColor color

◆ apply_paint_join()

static void apply_paint_join ( const SkPaint paint,
SkJSONWriter writer 
)
static

Definition at line 821 of file DrawCommand.cpp.

821 {
822 SkPaint::Join join = paint.getStrokeJoin();
824 switch (join) {
827 break;
830 break;
833 break;
834 default: SkASSERT(false);
835 }
836 }
837}
#define DEBUGCANVAS_MITER_JOIN
#define DEBUGCANVAS_BEVEL_JOIN
#define DEBUGCANVAS_ROUND_JOIN
#define DEBUGCANVAS_ATTRIBUTE_STROKEJOIN
Definition: DrawCommand.cpp:88
@ kDefault_Join
equivalent to kMiter_Join
Definition: SkPaint.h:363
@ kRound_Join
adds circle
Definition: SkPaint.h:360
@ kMiter_Join
extends to miter limit
Definition: SkPaint.h:359
@ kBevel_Join
connects outside edges
Definition: SkPaint.h:361
static SkString join(const CommandLineFlags::StringArray &)
Definition: skpbench.cpp:741

◆ apply_paint_maskfilter()

static void apply_paint_maskfilter ( const SkPaint paint,
SkJSONWriter writer,
UrlDataManager urlDataManager 
)
static

Definition at line 839 of file DrawCommand.cpp.

841 {
842 SkMaskFilter* maskFilter = paint.getMaskFilter();
843 if (maskFilter != nullptr) {
845 if (as_MFB(maskFilter)->asABlur(&blurRec)) {
848 switch (blurRec.fStyle) {
851 break;
854 break;
857 break;
860 break;
861 default: SkASSERT(false);
862 }
863 writer.endObject(); // blur
864 } else {
866 DrawCommand::flatten(maskFilter, writer, urlDataManager);
867 writer.endObject(); // maskFilter
868 }
869 }
870}
#define DEBUGCANVAS_ATTRIBUTE_BLUR
#define DEBUGCANVAS_ATTRIBUTE_SIGMA
#define DEBUGCANVAS_BLURSTYLE_SOLID
#define DEBUGCANVAS_ATTRIBUTE_MASKFILTER
#define DEBUGCANVAS_BLURSTYLE_INNER
#define DEBUGCANVAS_BLURSTYLE_OUTER
#define DEBUGCANVAS_BLURSTYLE_NORMAL
#define DEBUGCANVAS_ATTRIBUTE_STYLE
Definition: DrawCommand.cpp:85
@ kOuter_SkBlurStyle
nothing inside, fuzzy outside
Definition: SkBlurTypes.h:14
@ kSolid_SkBlurStyle
solid inside, fuzzy outside
Definition: SkBlurTypes.h:13
@ kInner_SkBlurStyle
fuzzy inside, nothing outside
Definition: SkBlurTypes.h:15
@ kNormal_SkBlurStyle
fuzzy inside and outside
Definition: SkBlurTypes.h:12
SkMaskFilterBase * as_MFB(SkMaskFilter *mf)
void appendFloat(float value)
Definition: SkJSONWriter.h:241

◆ apply_paint_patheffect()

static void apply_paint_patheffect ( const SkPaint paint,
SkJSONWriter writer,
UrlDataManager urlDataManager 
)
static

Definition at line 872 of file DrawCommand.cpp.

874 {
875 SkPathEffect* pathEffect = paint.getPathEffect();
876 if (pathEffect != nullptr) {
877 SkPathEffect::DashInfo dashInfo;
878 SkPathEffect::DashType dashType = pathEffect->asADash(&dashInfo);
879 if (dashType == SkPathEffect::kDash_DashType) {
880 dashInfo.fIntervals = (SkScalar*)sk_malloc_throw(dashInfo.fCount * sizeof(SkScalar));
881 pathEffect->asADash(&dashInfo);
884 for (int32_t i = 0; i < dashInfo.fCount; i++) {
885 writer.appendFloat(dashInfo.fIntervals[i]);
886 }
887 writer.endArray(); // intervals
888 sk_free(dashInfo.fIntervals);
890 writer.endObject(); // dashing
891 } else {
893 DrawCommand::flatten(pathEffect, writer, urlDataManager);
894 writer.endObject(); // pathEffect
895 }
896 }
897}
#define DEBUGCANVAS_ATTRIBUTE_DASHING
#define DEBUGCANVAS_ATTRIBUTE_PATHEFFECT
#define DEBUGCANVAS_ATTRIBUTE_PHASE
#define DEBUGCANVAS_ATTRIBUTE_INTERVALS
void beginArray(const char *name=nullptr, bool multiline=true)
Definition: SkJSONWriter.h:146
void endArray()
Definition: SkJSONWriter.h:158
DashType asADash(DashInfo *info) const
@ kDash_DashType
fills in all of the info parameter
Definition: SkPathEffect.h:62
float SkScalar
Definition: extension.cpp:12
SkScalar fPhase
Offset into the dashed interval pattern.
Definition: SkPathEffect.h:73
int32_t fCount
Number of intervals in the dash. Should be even number.
Definition: SkPathEffect.h:72
SkScalar * fIntervals
Length of on/off intervals for dashed lines.
Definition: SkPathEffect.h:70

◆ apply_paint_style()

static void apply_paint_style ( const SkPaint paint,
SkJSONWriter writer 
)
static

Definition at line 786 of file DrawCommand.cpp.

786 {
787 SkPaint::Style style = paint.getStyle();
788 if (style != SkPaint::kFill_Style) {
789 switch (style) {
792 break;
793 }
796 break;
797 }
798 default: SkASSERT(false);
799 }
800 }
801}
#define DEBUGCANVAS_STYLE_STROKE
#define DEBUGCANVAS_STYLE_STROKEANDFILL
@ kStroke_Style
set to stroke geometry
Definition: SkPaint.h:194
@ kFill_Style
set to fill geometry
Definition: SkPaint.h:193
@ kStrokeAndFill_Style
sets to stroke and fill geometry
Definition: SkPaint.h:195

◆ clipop_name()

static const char * clipop_name ( SkClipOp  op)
static

Definition at line 590 of file DrawCommand.cpp.

590 {
591 switch (op) {
594 default: SkASSERT(false); return "<invalid region op>";
595 }
596}
#define DEBUGCANVAS_CLIPOP_INTERSECT
#define DEBUGCANVAS_CLIPOP_DIFFERENCE

◆ color_type_name()

static const char * color_type_name ( SkColorType  colorType)
static

Definition at line 711 of file DrawCommand.cpp.

711 {
712 switch (colorType) {
719 default: SkASSERT(false); return DEBUGCANVAS_COLORTYPE_RGBA8888;
720 }
721}
#define DEBUGCANVAS_COLORTYPE_GRAY8
#define DEBUGCANVAS_COLORTYPE_565
#define DEBUGCANVAS_COLORTYPE_RGBA8888
#define DEBUGCANVAS_COLORTYPE_ARGB4444
#define DEBUGCANVAS_COLORTYPE_ALPHA8
#define DEBUGCANVAS_COLORTYPE_BGRA8888
@ kARGB_4444_SkColorType
pixel with 4 bits for alpha, red, green, blue; in 16-bit word
Definition: SkColorType.h:23
@ kBGRA_8888_SkColorType
pixel with 8 bits for blue, green, red, alpha; in 32-bit word
Definition: SkColorType.h:26
@ kAlpha_8_SkColorType
pixel with alpha in 8-bit byte
Definition: SkColorType.h:21
@ kGray_8_SkColorType
pixel with grayscale level in 8-bit byte
Definition: SkColorType.h:35
@ kRGB_565_SkColorType
pixel with 5 bits red, 6 bits green, 5 bits blue, in 16-bit word
Definition: SkColorType.h:22
@ kRGBA_8888_SkColorType
pixel with 8 bits for red, green, blue, alpha; in 32-bit word
Definition: SkColorType.h:24
static SkColorType colorType(AImageDecoder *decoder, const AImageDecoderHeaderInfo *headerInfo)

◆ encode_data()

static SkString encode_data ( const void *  bytes,
size_t  count,
const char *  contentType,
UrlDataManager urlDataManager 
)
static

Definition at line 622 of file DrawCommand.cpp.

625 {
627 return urlDataManager.addData(data.get(), contentType);
628}
int count
Definition: FontMgrTest.cpp:50
static sk_sp< SkData > MakeWithCopy(const void *data, size_t length)
Definition: SkData.cpp:111
SkString addData(SkData *, const char *contentType)

◆ make_json_rrect()

static void make_json_rrect ( SkJSONWriter writer,
const SkRRect rrect 
)
static

Definition at line 458 of file DrawCommand.cpp.

458 {
459 writer.beginArray(nullptr, false);
465 writer.endArray();
466}
static void MakeJsonPoint(SkJSONWriter &, const SkPoint &point)
static void MakeJsonRect(SkJSONWriter &, const SkRect &rect)
const SkRect & rect() const
Definition: SkRRect.h:264
SkVector radii(Corner corner) const
Definition: SkRRect.h:271
@ kUpperLeft_Corner
index of top-left corner radii
Definition: SkRRect.h:252
@ kLowerRight_Corner
index of bottom-right corner radii
Definition: SkRRect.h:254
@ kUpperRight_Corner
index of top-right corner radii
Definition: SkRRect.h:253
@ kLowerLeft_Corner
index of bottom-left corner radii
Definition: SkRRect.h:255
SkRRect rrect
Definition: SkRecords.h:232

◆ MakeJsonFont()

static void MakeJsonFont ( const SkFont font,
SkJSONWriter writer,
UrlDataManager urlDataManager 
)
static

Definition at line 955 of file DrawCommand.cpp.

955 {
956 writer.beginObject();
957 store_bool(writer, DEBUGCANVAS_ATTRIBUTE_FAKEBOLDTEXT, font.isEmbolden(), false);
958 store_bool(writer, DEBUGCANVAS_ATTRIBUTE_LINEARTEXT, font.isLinearMetrics(), false);
959 store_bool(writer, DEBUGCANVAS_ATTRIBUTE_SUBPIXELTEXT, font.isSubpixel(), false);
960 store_bool(writer, DEBUGCANVAS_ATTRIBUTE_EMBEDDEDBITMAPTEXT, font.isEmbeddedBitmaps(), false);
961 store_bool(writer, DEBUGCANVAS_ATTRIBUTE_AUTOHINTING, font.isForceAutoHinting(), false);
962
965 store_scalar(writer, DEBUGCANVAS_ATTRIBUTE_TEXTSCALEX, font.getSkewX(), 0.0f);
966 apply_font_edging(font, writer);
967 apply_font_hinting(font, writer);
968 apply_font_typeface(font, writer, urlDataManager);
969 writer.endObject(); // font
970}
#define DEBUGCANVAS_ATTRIBUTE_AUTOHINTING
Definition: DrawCommand.cpp:98
#define DEBUGCANVAS_ATTRIBUTE_FAKEBOLDTEXT
Definition: DrawCommand.cpp:92
#define DEBUGCANVAS_ATTRIBUTE_SUBPIXELTEXT
Definition: DrawCommand.cpp:94
static void apply_font_edging(const SkFont &font, SkJSONWriter &writer)
static void store_bool(SkJSONWriter &writer, const char *key, bool value, bool defaultValue)
static void apply_font_typeface(const SkFont &font, SkJSONWriter &writer, UrlDataManager &urlDataManager)
#define DEBUGCANVAS_ATTRIBUTE_EMBEDDEDBITMAPTEXT
Definition: DrawCommand.cpp:97
#define DEBUGCANVAS_ATTRIBUTE_TEXTSCALEX
static void apply_font_hinting(const SkFont &font, SkJSONWriter &writer)
static void store_scalar(SkJSONWriter &writer, const char *key, SkScalar value, SkScalar defaultValue)
#define DEBUGCANVAS_ATTRIBUTE_TEXTSIZE
#define DEBUGCANVAS_ATTRIBUTE_LINEARTEXT
Definition: DrawCommand.cpp:93
#define SkPaintDefaults_TextSize
#define SK_Scalar1
Definition: SkScalar.h:18

◆ pointmode_name()

static const char * pointmode_name ( SkCanvas::PointMode  mode)
static

Definition at line 598 of file DrawCommand.cpp.

598 {
599 switch (mode) {
603 default: SkASSERT(false); return "<invalid point mode>";
604 }
605}
#define DEBUGCANVAS_POINTMODE_LINES
#define DEBUGCANVAS_POINTMODE_POINTS
#define DEBUGCANVAS_POINTMODE_POLYGON
@ kLines_PointMode
draw each pair of points as a line segment
Definition: SkCanvas.h:1242
@ kPolygon_PointMode
draw the array of points as a open polygon
Definition: SkCanvas.h:1243
@ kPoints_PointMode
draw each point separately
Definition: SkCanvas.h:1241
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive mode
Definition: switches.h:228

◆ store_bool()

static void store_bool ( SkJSONWriter writer,
const char *  key,
bool  value,
bool  defaultValue 
)
static

Definition at line 616 of file DrawCommand.cpp.

616 {
617 if (value != defaultValue) {
618 writer.appendBool(key, value);
619 }
620}
void appendBool(bool value)
Definition: SkJSONWriter.h:229
uint8_t value

◆ store_scalar()

static void store_scalar ( SkJSONWriter writer,
const char *  key,
SkScalar  value,
SkScalar  defaultValue 
)
static

Definition at line 607 of file DrawCommand.cpp.

610 {
611 if (value != defaultValue) {
612 writer.appendFloat(key, value);
613 }
614}

◆ str_append()

static SkString * str_append ( SkString str,
const SkRect r 
)
static

Definition at line 227 of file DrawCommand.cpp.

227 {
228 str->appendf(" [%g %g %g %g]", r.left(), r.top(), r.right(), r.bottom());
229 return str;
230}
void void void appendf(const char format[],...) SK_PRINTF_LIKE(2
Definition: SkString.cpp:550
constexpr float left() const
Definition: SkRect.h:734
constexpr float top() const
Definition: SkRect.h:741
constexpr float right() const
Definition: SkRect.h:748
constexpr float bottom() const
Definition: SkRect.h:755