diff options
author | Brian Paul <[email protected]> | 2015-07-21 18:35:38 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2015-07-21 18:35:38 -0600 |
commit | e693fc299f1f78502b9201f1e1e8f333566c9fb6 (patch) | |
tree | 07139006583e68e73a2c6dbce2e44d83f444cca0 /src/mesa/main/debug.c | |
parent | 096371879098c315bc054b6fe1ef6f4b8f18554f (diff) |
mesa: replace Driver.GetTexImage with GetTexSubImage()
The new driver hook has x/y/zoffset and width/height/depth parameters
for the new glGetTextureSubImage() function.
The meta code and gallium state tracker are updated to handle the
new parameters.
Callers to Driver.GetTexSubImage() pass in offsets=0 and sizes equal
to the whole texture size.
v2: update i965 driver code, s/GLint/GLsizei/ in GetTexSubImage hook
Reviewed-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/mesa/main/debug.c')
-rw-r--r-- | src/mesa/main/debug.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c index 3090a007707..5ca7d5ce500 100644 --- a/src/mesa/main/debug.c +++ b/src/mesa/main/debug.c @@ -272,7 +272,9 @@ write_texture_image(struct gl_texture_object *texObj, store = ctx->Pack; /* save */ ctx->Pack = ctx->DefaultPacking; - ctx->Driver.GetTexImage(ctx, GL_RGBA, GL_UNSIGNED_BYTE, buffer, img); + ctx->Driver.GetTexSubImage(ctx, + 0, 0, 0, img->Width, img->Height, img->Depth, + GL_RGBA, GL_UNSIGNED_BYTE, buffer, img); /* make filename */ _mesa_snprintf(s, sizeof(s), "/tmp/tex%u.l%u.f%u.ppm", texObj->Name, level, face); |