diff options
Diffstat (limited to 'src/gallium/drivers/r600/r600_state.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_state.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c index f1480526587..41e9c5dfbdb 100644 --- a/src/gallium/drivers/r600/r600_state.c +++ b/src/gallium/drivers/r600/r600_state.c @@ -649,9 +649,14 @@ boolean r600_is_format_supported(struct pipe_screen *screen, } } - if ((usage & PIPE_BIND_SAMPLER_VIEW) && - r600_is_sampler_format_supported(screen, format)) { - retval |= PIPE_BIND_SAMPLER_VIEW; + if (usage & PIPE_BIND_SAMPLER_VIEW) { + if (target == PIPE_BUFFER) { + if (r600_is_vertex_format_supported(format)) + retval |= PIPE_BIND_SAMPLER_VIEW; + } else { + if (r600_is_sampler_format_supported(screen, format)) + retval |= PIPE_BIND_SAMPLER_VIEW; + } } if ((usage & (PIPE_BIND_RENDER_TARGET | |