diff options
author | Ilia Mirkin <[email protected]> | 2014-08-20 19:45:10 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2014-09-12 00:54:55 -0400 |
commit | c113095acdcfedb4ad82da67bc7981056efe9e44 (patch) | |
tree | 9fca2a38a412dac43b9de31949f11157faca1aaa /src/gallium/include | |
parent | 3c81de58512f0615df1d90aa79a22c9a44c7189e (diff) |
gallium: add a texture target to sampler view and a CAP to use it
This allows a sampler view to have a different texture target than the
underlying resource. This will be used to implement the type casting
between 2d arrays and cube maps as specified in ARB_texture_view.
Signed-off-by: Ilia Mirkin <[email protected]>
Reviewed-by: Roland Scheidegger <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/include')
-rw-r--r-- | src/gallium/include/pipe/p_defines.h | 1 | ||||
-rw-r--r-- | src/gallium/include/pipe/p_state.h | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h index aae8229a4e2..93156b952bd 100644 --- a/src/gallium/include/pipe/p_defines.h +++ b/src/gallium/include/pipe/p_defines.h @@ -570,6 +570,7 @@ enum pipe_cap { PIPE_CAP_UMA = 107, PIPE_CAP_CONDITIONAL_RENDER_INVERTED = 108, PIPE_CAP_MAX_VERTEX_ATTRIB_STRIDE = 109, + PIPE_CAP_SAMPLER_VIEW_TARGET = 110, }; #define PIPE_QUIRK_TEXTURE_BORDER_COLOR_SWIZZLE_NV50 (1 << 0) diff --git a/src/gallium/include/pipe/p_state.h b/src/gallium/include/pipe/p_state.h index a82686b23a4..36d253c5157 100644 --- a/src/gallium/include/pipe/p_state.h +++ b/src/gallium/include/pipe/p_state.h @@ -361,6 +361,7 @@ struct pipe_surface struct pipe_sampler_view { struct pipe_reference reference; + enum pipe_texture_target target; /**< PIPE_TEXTURE_x */ enum pipe_format format; /**< typed PIPE_FORMAT_x */ struct pipe_resource *texture; /**< texture into which this is a view */ struct pipe_context *context; /**< context this view belongs to */ |