| Index: src/gpu/GrDrawTarget.h
|
| ===================================================================
|
| --- src/gpu/GrDrawTarget.h (revision 8448)
|
| +++ src/gpu/GrDrawTarget.h (working copy)
|
| @@ -655,24 +655,35 @@
|
| }
|
| const SkRect* getDevBounds() const { return fDevBounds; }
|
|
|
| + // NULL if no copy of the dst is needed for the draw.
|
| + const GrDeviceCoordTexture* getDstCopy() const {
|
| + if (NULL != fDstCopy.texture()) {
|
| + return &fDstCopy;
|
| + } else {
|
| + return NULL;
|
| + }
|
| + }
|
| +
|
| private:
|
| DrawInfo() { fDevBounds = NULL; }
|
|
|
| friend class GrDrawTarget;
|
|
|
| - GrPrimitiveType fPrimitiveType;
|
| + GrPrimitiveType fPrimitiveType;
|
|
|
| - int fStartVertex;
|
| - int fStartIndex;
|
| - int fVertexCount;
|
| - int fIndexCount;
|
| + int fStartVertex;
|
| + int fStartIndex;
|
| + int fVertexCount;
|
| + int fIndexCount;
|
|
|
| - int fInstanceCount;
|
| - int fVerticesPerInstance;
|
| - int fIndicesPerInstance;
|
| + int fInstanceCount;
|
| + int fVerticesPerInstance;
|
| + int fIndicesPerInstance;
|
|
|
| - SkRect fDevBoundsStorage;
|
| - SkRect* fDevBounds;
|
| + SkRect fDevBoundsStorage;
|
| + SkRect* fDevBounds;
|
| +
|
| + GrDeviceCoordTexture fDstCopy;
|
| };
|
|
|
| private:
|
| @@ -714,6 +725,10 @@
|
| void releasePreviousVertexSource();
|
| void releasePreviousIndexSource();
|
|
|
| + // Makes a copy of the dst if it is necessary for the draw. Returns false if a copy is required
|
| + // but couldn't be made. Otherwise, returns true.
|
| + bool setupDstReadIfNecessary(DrawInfo* info);
|
| +
|
| enum {
|
| kPreallocGeoSrcStateStackCnt = 4,
|
| };
|
|
|