TGSI has a different model for precise than GLSL, so we have to mark
all outputs that has gotten an precise operation output to it as
precise.
This only implements part of the 'precise' keyword (still lacking
support on individual operations), but it's enough to pass some dEQP
tests, in particular:
- dEQP-GLES31.functional.tessellation.common_edge.triangles_equal_spacing_precise
- dEQP-GLES31.functional.tessellation.common_edge.triangles_fractional_odd_spacing_precise
- dEQP-GLES31.functional.tessellation.common_edge.triangles_fractional_even_spacing_precise
- dEQP-GLES31.functional.tessellation.common_edge.quads_equal_spacing_precise
- dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_odd_spacing_precise
- dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_even_spacing_precise
v2: flipped ordering of "invariant" and "precise", to avoid compiler
errors if both are emitted.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
v2: use str_match_no_case to fix _SAT_PRECISE detection
v4: usd is_digit_alpha_underscore to match end of mods
Signed-off-by: Karol Herbst <karolherbst@gmail.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
[cherry-picked from 4611343bcc05c75bcc9697243dabbb083f7078de in mesa]
Signed-off-by: Dave Airlie <airlied@redhat.com>
Only implemented for glsl->tgsi. Other converters just set precise to 0.
v2: remove precise paramter from ureg_tex_insn and ureg_memory_insn
Signed-off-by: Karol Herbst <karolherbst@gmail.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
[cherry-picked from d0dfdf704d6ef974a3bbac826cfd7e511e918f4b in mesa]
Signed-off-by: Dave Airlie <airlied@redhat.com>
OpenGL ES 3.1 does not have glPrimitiveRestart; only OpenGL 3.1
does. So let's avoid making the renderer thing calling this is OK.
Otherwise, it'd be possible to generate evil commands from a rouge
guest-driver that can crash the VM.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Otherwise, it'd be possible to generate evil commands from a rouge
guest-driver that can crash the VM.
This is a bit trickier than the previous one, because we were already
mixing calls to the OpenGL 3.0 version and the GL_NV_conditional_render
version, which indicates that this was previously only safe if *both*
were supported, that is OpenGL 3.0 *with* GL_NV_conditional_render.
Now, this code should match the caps we generate, which shouldn't give
any percieved feature-regressions or gl-versions supported.
v2: do not set have_gl_conditional_render if on GLES 3.0 or above.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Tested-by: Po-Hsien Wang <pwang@chromium.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Otherwise, it'd be possible to generate evil commands from a rouge
guest-driver that can crash the VM.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Otherwise, it'd be possible to generate evil commands from a rouge
guest-driver that can crash the VM.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
This pulls the code out from the gles31 development,
and modifies the caps to support two different limits
(so far I've only found fs/cs vs everyone else limits differ)
v2: fix buffer creation paths, limit maximums, handle indirect
(don't pass -1 into gl funcs when we don't need to).
v3: free ssbo locs
v4: use two caps fields
Co-authors: Gurchetan Singh <gurchetansingh@chromium.org>
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
This passes the structs into translate_tex and cleans up after.
(Inspired while look at merging some stuff from gles tree)
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh at chromium.org>
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
Three component formats are not very helpful, at least the Intel driver doesn't
expose them as color renderable, and other drivers most likely also just emulate
them using RGBX textur formats. RGB32* we have to keep though because it is needed
for ARB_rbo_rgb32 which in turn is needed for OpenGL 4.0.
To handle the latter, mesa/virgl will take care that RGB32* textures are only
allocated as buffers objects.
Reviewed-by: Gurchetan Singh <gurchetansingh at chromium.org>
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
When the host is gles >= 3.2, gl >= 4.3, or when the extension
GL_(ARB|EXT|OES)_copy_image is available, memcopy like blitting and region
copying can be done for many color format combinations by using
glCopyImageSubData.
This fixes a number of tests from the subset
dEQP-GLES31.functional.copy_image.non_compressed.viewclass_*
v2: - Clean list of canonical formats (Gurchetan Singh)
- Use size of canonical formats to decide whether they can be copied via
gCopyImageSubData
- Also honour the render state when deciding whether glCopyImageSubData
will do, or whether we need to do a blit.
v3: - replace format size check by compatibility check (Gurchetan Singh) but
keep the check seperate because we need to add logic for compressed
texture later
Reviewed-by: Gurchetan Singh <gurchetansingh at chromium.org>
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
I had some missunderstanding about what glEnable(sRGB) did when I added this
warning. As in GLES there is no need to do glEnable(sRGB) at all since it is
implied from the framebuffer.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
Fixes a bunch of non-compute related dEQP-GLES31.functional.shaders.opaque_type_indexing.*
tests.
Example test cases:
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.uniform.vertex.sampler2dshadow
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.dynamically_uniform.tessellation_control.samplercubearrayshadow
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.dynamically_uniform.tessellation_evaluation.samplercubearrayshadow
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.uniform.geometry.sampler2dshadow
Reviewed-by: Dave Airlie <airlied@redhat.com>
Sampler arrays don't work with shadow textures. Let's move sampler
array functionality into emit_sampler_decl to de-deuplicate logic.
Reviewed-by: Dave Airlie <airlied@redhat.com>
Otherwise, we risk missing stuff like negation modifiers.
Fixes the following dEQP failures for me:
- dEQP-GLES31.functional.tessellation.common_edge.quads_equal_spacing
- dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_odd_spacing
- dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_even_spacing
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
There's a few minor mistakes in the old license statement, for
instance:
- missing the year 2014 from the copyright
- "without limitation the" instead of "without limitation on the"
Apart from that it's just minor details like wrapping, and adding
"(including the next paragraph)". None of this seems to change
anything from a legal standpoint.
This matches the copyright-header we have for the same file in
Mesa, and makes it a bit less noisy to update the file there.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Acked-by: Dave Airlie <airlied@redhat.com>
This header isn't used anywhere, and just seems like cruft from the
past. Let's just get rid of it.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Acked-by: Dave Airlie <airlied@redhat.com>
The protocol will never send negative numbers, so use uints
to avoid having to compare to 0 and other warnings.
Reviewed-by: Po-Hsien Wang <pwang@chromium.org>
This is required to implement glMinSampleShading().
Sadly, we've been setting has_sample_shading for a while, even
though this is needed. So we need to set a capability so mesa will
know that it's safe to emit this command.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
When we use independent blending, we need to check every rendertarget
indevidually, not just once for all, otherwise we end up using the
wrong blend-mode for some render-targets.
Fixes these test-cases:
dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.0
dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.6
dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.14
[airlied: rebased onto master hopefully correct]
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Otherwise, we'll end up destroying the state when restoring after
clears.
Fixes these test-cases:
dEQP-GLES31.functional.draw_buffers_indexed.random.max_required_draw_buffers.7
dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.13
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
When a texture is bound in its original form then the swizzle states and
the sRGB state were updated and if a texture view of this texture was bound
later it was assumed that the state is already submitted. However, it seems
that a texture view has its own, separate state that must be set separately,
so keep track of it on a per-view basis.
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Query the number of supported samples and the sample position and
store these to the caps.v2 structure. We support only up to 16 samples.
This implementation requires a GL host backend.
v2: - glTexImage2Dmultisample is not available on a gles 3.1 host
and trying to call it crashed qemu (Jakob Bornecrantz)
Use glTexStorage2DMultisample instead and delete texture each
round because the texture becomes immutable.
- move call to get sample positions only when caps v2 needs to be
filled.
v3: - rebase against master
- take care of nits (Dave)
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
TGSI defines TGSI_SEMANTIC_SAMPLEMASK to be a four-compoent integer
vector, with the x component set to the same value as gl_SampleMask,
and the y, z and w components set to 0.
Fixes the following failures:
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_pixel.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_pixel.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_pixel.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_sample.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_sample.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_sample.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_two_samples.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_two_samples.multisample_texture_{1,2}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_two_samples.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bit_count_per_two_samples.multisample_rbo_{1,2}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bits_unique_per_sample.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bits_unique_per_sample.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask_in.bits_unique_per_two_samples.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_pixel.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_pixel.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_pixel.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_pixel.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_pixel.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_sample.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_sample.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_sample.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_sample.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_sample.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_two_samples.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_two_samples.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_two_samples.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_two_samples.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.discard_half_per_two_samples.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_pixel.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_pixel.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_pixel.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_pixel.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_pixel.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_sample.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_sample.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_sample.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_sample.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_sample.multisample_rbo_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_two_samples.default_framebuffer
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_two_samples.singlesample_texture
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_two_samples.multisample_texture_{1,2,4,8,16}
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_two_samples.singlesample_rbo
dEQP-GLES31.functional.shaders.sample_variables.sample_mask.inverse_per_two_samples.multisample_rbo_{1,2,4,8,16}
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
In 0ea74890db, I had a typo that
made GL_ARB_gpu_shader5 being injected into vertex-shaders that
doesn't need them.
This is obviously a big problem when running on for instance GLES
2.0, where this extension isn't supported. So let's fix this.
Tested-by: Jakob Bornecrantz <jakob@collabora.com>
Reviewed-by: Jakob Bornecrantz <jakob@collabora.com>
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
This just moves the code to a function, it doesn't change any
of the expected code. It should make it easier to spot fixes.
Reviewed-by: Elie Tournier <elie.tournier@collabora.com>
If a shader uses TGSI_INTERPOLATE_LOC_SAMPLE, we need to emit
the "sample"-keyword for the input-variable in the fragment
shader.
Since the "sampler"-keyword is a GLSL 4.00 feature, this
requires us to enable GL_ARB_gpu_shader5. Unfortunately, opting
in carefully on this is a bit trickier than for most other
extensions, because we patch up vertex, geometry or tesselation
evaluation shader outputs to match the fragment shader inputs.
Since the previous patch adds padding for the require-statement
directly after the #version string, we can just overwrite that
padding with the require statement.
This fixes the following tests:
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_texture_1
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_texture_2
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_texture_4
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_texture_8
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_texture_16
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_rbo_1
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_rbo_2
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_rbo_4
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_rbo_8
dEQP-GLES31.functional.shaders.multisample_interpolation.sample_qualifier.multisample_rbo_16
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_texture_1
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_texture_2
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_texture_4
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_texture_8
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_texture_16
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_rbo_1
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_rbo_2
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_rbo_4
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_rbo_8
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_sample.at_sample_id.multisample_rbo_16
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_texture_1
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_texture_2
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_texture_4
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_texture_8
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_texture_16
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_rbo_1
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_rbo_2
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_rbo_4
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_rbo_8
dEQP-GLES31.functional.shaders.multisample_interpolation.interpolate_at_offset.at_sample_position.multisample_rbo_16
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
The following patch will need enough padding to inject a line like
this into the start of the shader for vertex, geometry and
tesselation evaluation shaders:
So, let's add some appropriately sized space-padding that we can
search for and replace later.
Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
[airlied: rebased back to master]
Reviewed-by: Dave Airlie <airlied@redhat.com>
For multisample textures glTexStorage*DMultisample was only used on GLES
and not when the GL host provided it. Texture views need the texture to be
immutable and this is achieved by allocating them using glTexStorage.
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
I've come up with a workaround on the mesa side that should be
backwards compatible with old vtests and vice-versa.
It involves sending both caps 2 and 1 queries back to back,
and taking the first response an indication of what to expect,
v1.1: Check max_size is > 0 before mallocing
Reviewed-by: Jakob Bornecrantz <jakob@collabora.com>
This adds the renderer support for exposing texture views.
The change adds support to sampler views and surfaces for the backing
object to be a separately allocated textureview instead of the actual
resource. It also adds support for parsing the updated packet where
we put the sampler view target in the top 8 bits of the format,
which should be safe as up until now it's always 0.
This doesn't do the final enable of the extension, but it will
cause us to use views in a few places we didn't before so could have
some other side effects
v2: check for buffers on surface creation, reword comment
to better explain if statement.
v3: fix logic bug (Gert). This uncovered a wierd corner case, possibly
due to how the state tracker allocates textures, but it tries to create
a surface with more layers than there are, I think it then reallocate
the whole texture object in the guest and it works out in the end,
this adds check to catch this, and to avoid creating a texture view
in that case.
v4: realise the problem with v3 was 3D textures and use
util_max_layer to fix the logic properly.
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
OpenGL defaults GL_TEXTURE_MIN_FILTER=GL_NEAREST_MIPMAP_LINEAR and
GL_TEXTURE_MAX_LEVEL=1000, and expects all these mip-map levels to be
defined. With glTexStorage this is set apropriately, but when the mip-map
levels are initialiazed manually, then the GL_TEXTURE_MAX_LEVEL must be set.
Tested-by: Jakob Bornecrantz <jakob@collabora.com>
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Signed-off-by: Jakob Bornecrantz <jakob@collabora.com>
This just makes the two functions look a lot more like each other,
since for texture views I have to add some more code to them.
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
I want to change the incoming format to use some bits for texture
view support, so this is precursor to avoid causing problems.
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>