aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/state_tracker/st_cb_drawpixels.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-02-05 08:22:00 +0100
committermarha <marha@users.sourceforge.net>2013-02-05 08:23:51 +0100
commit76c527be60066b647468ad66f8e4d7dd18fa1769 (patch)
tree2e4653dc3adf874409cf9baba399fd64537115d4 /mesalib/src/mesa/state_tracker/st_cb_drawpixels.c
parenta6d5f8de1394c338d01b65be7dba3520bf8bdf4b (diff)
downloadvcxsrv-76c527be60066b647468ad66f8e4d7dd18fa1769.tar.gz
vcxsrv-76c527be60066b647468ad66f8e4d7dd18fa1769.tar.bz2
vcxsrv-76c527be60066b647468ad66f8e4d7dd18fa1769.zip
fontconfig mesa xkeyboard-config git update 5 feb 2013
xkeyboard-config commit b4be67b48fb11989f1824dd0b1c8c399430162b0 fontconfig commit 95af7447dba7c54ed162b667c0bb2ea6500e8f32 mesa commit 86536a321d9d26137587affe687a07da71f0b526
Diffstat (limited to 'mesalib/src/mesa/state_tracker/st_cb_drawpixels.c')
-rw-r--r--mesalib/src/mesa/state_tracker/st_cb_drawpixels.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/mesalib/src/mesa/state_tracker/st_cb_drawpixels.c b/mesalib/src/mesa/state_tracker/st_cb_drawpixels.c
index c944b81f6..26d1923b5 100644
--- a/mesalib/src/mesa/state_tracker/st_cb_drawpixels.c
+++ b/mesalib/src/mesa/state_tracker/st_cb_drawpixels.c
@@ -489,12 +489,14 @@ make_texture(struct st_context *st,
intFormat = internal_format(ctx, format, type);
baseInternalFormat = _mesa_base_tex_format(ctx, intFormat);
- mformat = st_ChooseTextureFormat_renderable(ctx, intFormat,
- format, type, GL_FALSE);
- assert(mformat);
-
- pipeFormat = st_mesa_format_to_pipe_format(mformat);
- assert(pipeFormat);
+ /* Choose a pixel format for the temp texture which will hold the
+ * image to draw.
+ */
+ pipeFormat = st_choose_format(pipe->screen, intFormat, format, type,
+ PIPE_TEXTURE_2D, 0, PIPE_BIND_SAMPLER_VIEW,
+ FALSE);
+ assert(pipeFormat != PIPE_FORMAT_NONE);
+ mformat = st_pipe_format_to_mesa_format(pipeFormat);
pixels = _mesa_map_pbo_source(ctx, unpack, pixels);
if (!pixels)
@@ -1462,8 +1464,8 @@ st_CopyPixels(struct gl_context *ctx, GLint srcx, GLint srcy,
driver_vp = make_passthrough_vertex_shader(st, GL_FALSE);
if (st->pixel_xfer.pixelmap_enabled) {
- sv[1] = st->pixel_xfer.pixelmap_sampler_view;
- num_sampler_view++;
+ sv[1] = st->pixel_xfer.pixelmap_sampler_view;
+ num_sampler_view++;
}
}
else {
@@ -1499,14 +1501,16 @@ st_CopyPixels(struct gl_context *ctx, GLint srcx, GLint srcy,
if (type == GL_DEPTH) {
texFormat = st_choose_format(screen, GL_DEPTH_COMPONENT,
GL_NONE, GL_NONE, st->internal_target,
- sample_count, PIPE_BIND_DEPTH_STENCIL);
+ sample_count, PIPE_BIND_DEPTH_STENCIL,
+ FALSE);
assert(texFormat != PIPE_FORMAT_NONE);
}
else {
/* default color format */
texFormat = st_choose_format(screen, GL_RGBA,
GL_NONE, GL_NONE, st->internal_target,
- sample_count, PIPE_BIND_SAMPLER_VIEW);
+ sample_count, PIPE_BIND_SAMPLER_VIEW,
+ FALSE);
assert(texFormat != PIPE_FORMAT_NONE);
}
}