summaryrefslogtreecommitdiff
path: root/cogl/cogl-texture-2d.c
diff options
context:
space:
mode:
authorRobert Bragg <robert@linux.intel.com>2012-11-08 23:35:45 +0000
committerRobert Bragg <robert@linux.intel.com>2013-01-22 17:48:08 +0000
commit38921701e533b7fda38a236cc45aec2ed3afef8a (patch)
treef529208549a114abb25d278f0bbf7db9038622ea /cogl/cogl-texture-2d.c
parente8eb9793e66cd78162626f65e02922b63a0f9b26 (diff)
downloadcogl-38921701e533b7fda38a236cc45aec2ed3afef8a.tar.gz
blit: avoid referring to framebuffer stack
This make _cogl_framebuffer_blit take explicit src and dest framebuffer pointers and updates all the texture blitting strategies in cogl-blit.c to avoid pushing/popping to/from the the framebuffer stack. The removes the last user of the framebuffer stack which we've been aiming to remove before Cogl 2.0 Reviewed-by: Neil Roberts <neil@linux.intel.com> (cherry picked from commit 598ca33950a93dd7a201045c4abccda2a855e936)
Diffstat (limited to 'cogl/cogl-texture-2d.c')
-rw-r--r--cogl/cogl-texture-2d.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/cogl/cogl-texture-2d.c b/cogl/cogl-texture-2d.c
index 8517d237..853e646f 100644
--- a/cogl/cogl-texture-2d.c
+++ b/cogl/cogl-texture-2d.c
@@ -343,6 +343,7 @@ _cogl_texture_2d_externally_modified (CoglTexture *texture)
void
_cogl_texture_2d_copy_from_framebuffer (CoglTexture2D *tex_2d,
+ CoglFramebuffer *src_fb,
int dst_x,
int dst_y,
int src_x,
@@ -350,15 +351,10 @@ _cogl_texture_2d_copy_from_framebuffer (CoglTexture2D *tex_2d,
int width,
int height)
{
- CoglContext *ctx;
- CoglFramebuffer *read_fb = _cogl_get_read_framebuffer ();
-
- _COGL_RETURN_IF_FAIL (cogl_is_texture_2d (tex_2d));
-
- ctx = COGL_TEXTURE (tex_2d)->context;
+ CoglContext *ctx = COGL_TEXTURE (tex_2d)->context;
ctx->driver_vtable->texture_2d_copy_from_framebuffer (tex_2d,
- read_fb,
+ src_fb,
dst_x,
dst_y,
src_x,