Remove notion of default rendertarget. This doesn't map well to usage patterns outside sample app. Make binding between SkGpuDevice and a GrRenderTarget more explicit. Create method on GrContext to wrap the current target in the 3D API with a GrRenderTarget.
git-svn-id: http://skia.googlecode.com/svn/trunk@706 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/gpu/src/GrGpuGL.h b/gpu/src/GrGpuGL.h
index 8c2cd80..611485d 100644
--- a/gpu/src/GrGpuGL.h
+++ b/gpu/src/GrGpuGL.h
@@ -42,9 +42,7 @@
intptr_t platformRenderTarget,
int width, int height);
- virtual GrRenderTarget* defaultRenderTarget();
-
- virtual void setDefaultRenderTargetSize(uint32_t width, uint32_t height);
+ virtual GrRenderTarget* createRenderTargetFrom3DApiState();
virtual void eraseColor(GrColor color);
@@ -98,7 +96,7 @@
// sampler state (filtering, tiling)
// FBO binding
// line width
- void flushGLStateCommon(PrimitiveType type);
+ bool flushGLStateCommon(PrimitiveType type);
// set when this class changes the rendertarget.
// Subclass should notice at flush time, take appropriate action,
@@ -114,8 +112,6 @@
GrGLExts fExts;
private:
- GrGLRenderTarget* fDefaultRenderTarget;
-
void resetContextHelper();
// notify callbacks to update state tracking when related