Yonggang Luo
a37e3b7199
util: #include "c11/threads.h" instead of #include "util/u_cpu_detect.h" u_format.c
...
As it does not access any symbols in util/u_cpu_detect.h but accessed symbols in "c11/threads.h"
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19266 >
2022-10-25 11:06:05 +00:00
James Zhu
9055ab9de3
util/format: add util format y8_400_unorm
...
Signed-off-by: James Zhu <James.Zhu@amd.com >
Signed-off-by: Sathishkumar S <sathishkumar.sundararaju@amd.com >
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com >
Reviewed-by: Boyuan Zhang <Boyuan.Zhang@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18914 >
2022-10-07 15:14:39 +00:00
Kai Wasserbäch
e52d3d5f1c
fix: util/format: unused variable ‘desc’ [-Wunused-variable]
...
Only used in debug builds.
Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org >
Reviewed-by: Mihai Preda <mhpreda@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18643 >
2022-09-19 22:02:16 +00:00
Erik Faye-Lund
a6ed406d9f
util/format: implement rgtc -> r8 / r8g8 unpack
...
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Acked-by: Eric Engestrom <eric@igalia.com >
Tested-by: Eric Engestrom <eric@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18248 >
2022-09-15 08:16:01 +00:00
Erik Faye-Lund
dfbcd94041
util/format: allow unpacking less than a block from rgtc
...
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Acked-by: Eric Engestrom <eric@igalia.com >
Tested-by: Eric Engestrom <eric@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18248 >
2022-09-15 08:16:01 +00:00
Erik Faye-Lund
6e1c3e98cd
util/format: fix broken indentation
...
This file had a mixture of tabs and spaces for indent.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Acked-by: Eric Engestrom <eric@igalia.com >
Tested-by: Eric Engestrom <eric@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18248 >
2022-09-15 08:16:01 +00:00
Erik Faye-Lund
a321d157c6
util: allow unpacking less than a block from dxt
...
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Acked-by: Eric Engestrom <eric@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18180 >
2022-09-06 12:55:02 +00:00
Rhys Perry
dfbb4b384a
util/format,vulkan/format: update p_format for Vulkan vertex buffers
...
We need to move some earlier (so they are <= 255 like the comment says)
and add a few 64-bit ones.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17894 >
2022-08-30 19:02:11 +00:00
Erik Faye-Lund
253b521b6e
mesa/main: remove always-true define
...
We don't include this header anwhere where BPTC_BLOCK_DECODE isn't
already true, so let's remove it.
Acked-by: Marek Olšák <marek.olsak@amd.com >
Acked-by: Soroush Kashani <soroush.kashani@imgtec.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18012 >
2022-08-30 08:36:47 +00:00
Yonggang Luo
075b72ea06
util: Fixes invalid assumption that return non null by function util_format_fetch_rgba_func
...
Fixes: e342081c ("util/format: Assert that formats are valid")
Closes #7020
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18024 >
2022-08-12 18:06:36 +00:00
Mike Blumenkrantz
a5b2725894
util/format: handle SRGB in util_format_luminance_to_red()
...
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17687 >
2022-08-12 14:24:52 +00:00
Marek Olšák
788dce46a3
radeonsi: add a randomized blit test
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17864 >
2022-08-03 00:57:16 +00:00
Marek Olšák
2208ff7a5b
util/format: add util_format_rgbx_to_rgba helper
...
Image stores don't like RGBX on AMD. This is required by compute blits.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17864 >
2022-08-03 00:57:16 +00:00
Konstantin Seurer
c48497593a
util/format: Remove format desc null checks
...
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17490 >
2022-07-21 12:48:01 +00:00
Konstantin Seurer
e342081c37
util/format: Assert that formats are valid
...
It should be the responsibility of the driver to make sure, that "format" is a valid pipe_format.
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17490 >
2022-07-21 12:48:01 +00:00
Konstantin Seurer
2b02ac2779
util/format: Use an explicit length for the descs
...
The script that generates the format tables does not set every pipe_format.
In practice, the length of the format tables is equal to PIPE_FORMAT_COUNT.
I just added the explicit size to future-proof it.
(If the largest valid format is not part of the format tables,
there will be a mismatch between the array length and PIPE_FORMAT_COUNT)
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17490 >
2022-07-21 12:48:01 +00:00
Mike Blumenkrantz
ba09a00a5c
format_utils: properly parenthesize macro params
...
this otherwise breaks evaluation of the parameters on arm64
cc: mesa-stable
fixes #6496
Reviewed-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16860 >
2022-06-04 13:15:57 +00:00
Erik Faye-Lund
9ec514ded7
util: add missing c99_compat.h includes
...
These headers use the "restrict" keyword, so they need to include
c99_compat.h in case they get included from C++.
Right now, we include c99_compat.h in many needless places, which saves
us. But we're about to stop doing that.
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16812 >
2022-06-02 13:09:15 +00:00
Sil Vilerino
b2b907f052
util/u_format: Drop assert that has valid/well-defined behavior
...
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16286 >
2022-05-17 21:02:24 +00:00
Marek Olšák
2d4067a6fb
util: change util_format_snorm8_to_sint8 -> snorm_to_sint for radeonsi
...
Convert all SNORM formats to SINT.
This fixes SNORM blits for radeonsi.
Reviewed-by: Emma Anholt <emma@anholt.net >
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16132 >
2022-04-28 12:44:13 +00:00
Marek Olšák
09d6ebac7e
util: add pipe formats R10G10B10X2_SINT, B10G10R10X2_SINT, G16R16_SINT
...
needed by radeonsi
Reviewed-by: Emma Anholt <emma@anholt.net >
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16132 >
2022-04-28 12:44:13 +00:00
Dave Airlie
783cab811d
util/format: add new z24/s8 packing helper to pack z32/s8.
...
If zink runs on top of a vulkan impl with no 24-bit float support
it needs support to pack into 24-bit for GL.
To avoid having to make a temp copy, add a new helper to convert
and pack.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15516 >
2022-03-26 01:22:15 +00:00
Yonggang Luo
d9c3601e29
util: trim trailing space for files src/util/**/*
...
Using the following bash script doing that
```
cd src/util
find . -type f -print0 | xargs -0 -n1 sed -i 's/[ \t]*$//'
```
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15093 >
2022-03-21 17:57:15 +00:00
Emma Anholt
2e6810a06a
util/format: Add G8_B8R8_420_UNORM to match Vulkan.
...
turnip was playing fast and loose with the name, using the R8_G8B8 format
name but actually setting the descriptors up to read G8_B8R8 like Vulkan
(sensibly) wants. This caused trouble when trying to make freedreno and
turnip share code. By having both orderings as format names, we can share
the descriptor code and also confuse readers less.
Reviewed-by: Rob Clark <robdclark@chromium.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13443 >
2021-11-11 00:10:57 +00:00
Emma Anholt
271b6cb981
util: Rename PIPE_FORMAT_G8_B8_R8_420_UNORM.
...
The only user, turnip, was actually treating it as this layout, matching
vulkan's specification of how the planes map to RGB values. (Y=G means
that Cb=B and Cr=R).
Reviewed-by: Rob Clark <robdclark@chromium.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13443 >
2021-11-11 00:10:57 +00:00
Matt Turner
e0a74c7cad
util/format: Add PIPE_FORMAT_Y8_UNORM as an "other" layout format
...
freedreno has a different layout for tiled Y8 planes from normal R8
textures, so we need to be able to talk about them separately.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6792 >
2021-10-22 11:25:30 +00:00
Emma Anholt
68f8bbb37e
util: Move freedreno's snorm-to-unorm to util/, adding remaining cases.
...
I want it in turnip too.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13379 >
2021-10-21 08:46:31 +00:00
Emma Anholt
e47b4ba629
util/format: Add an RGB planar format for YV12, like we have for NV12.
...
Turnip will use this for mapping the to the corresponding hardware format,
and we could also extend mesa/st to avoid adding extra samplers for
external image sampling of YV12 on freedreno.
Reviewed-by: Rob Clark <robdclark@chromium.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13046 >
2021-10-05 20:09:17 +00:00
Adrian Bunk
7155676618
util/format: NEON is not available with the soft-float ABI
...
Fixes: 80923e8d58 ("util/format: Add some NEON intrinsics-based u_format_unpack.")
Reviewed-by: Emma Anholt <emma@anholt.net >
Tested-by: Ross Burton <ross.burton@arm.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12569 >
2021-09-01 15:18:02 +00:00
Eric Engestrom
f1eae2f8bb
python: drop python2 support
...
Signed-off-by: Eric Engestrom <eric@engestrom.ch >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Dylan Baker <dylan@pnwbakers.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3674 >
2021-08-14 21:44:32 +00:00
Axel Davy
6a0e703512
util: Fix translate from block compressed to rgba
...
Since
2b5178ee util: Switch the non-block formats to unpacking rgba rows instead of rects,
compressed formats define unpack_rgba_8unorm_rect instead
of unpack_rgba_8unorm.
Fixes the u_format_translate check to take this into account.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5201
Fixes: 2b5178ee ("util: Switch the non-block formats to unpacking rgba rows instead of rects")
Signed-off-by: Axel Davy <davyaxel0@gmail.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12315 >
2021-08-12 20:30:42 +00:00
Ian Romanick
72259a870f
util: Add and use functions to calculate min and max int for a size
...
Many places need to know the maximum or minimum possible value for a
given size integer... so everyone just open-codes their favorite
version. There is some potential to hit either undefined or
implementation-defined behavior, so having one version that Just Works
seems beneficial.
v2: Fix copy-and-pasted bug (INT64_MAX instead of INT64_MIN) in
u_intmin. Noticed by CI. Lol. Rename functions
`s/u_(uint|int)(min|max)/u_\1N_\2/g`. Suggested by Jason. Add some
unit tests that would have caught the copy-and-paste bug before wasting
CI time. Change the implementation of u_intN_min to use the same
pattern as stdint.h. This avoids the integer division. Noticed by
Jason.
v3: Add changes to convert_clear_color
(src/gallium/drivers/iris/iris_clear.c). Suggested by Nanley.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Suggested-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12177 >
2021-08-03 12:55:02 -07:00
Marek Olšák
4a713c568b
gallium: add multi-component 64-bit UINT formats for raw double vertex attribs
...
This is the distinction between formats:
- PIPE_FORMAT_R64_FLOAT is the legacy "convert-to-float" vertex format.
- PIPE_FORMAT_R64_UINT is the raw double format.
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11370 >
2021-08-02 19:58:28 +00:00
Sergii Melikhov
8251bd216e
util/format: Change the pointer offset.
...
Changed the pointer offset to 2 to account for the second structure variable.
Fixes: 90f98b56f8 ("mesa: Deduplicate _mesa_pack_uint_z_row().")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/4685
Signed-off-by: Sergii Melikhov <sergii.v.melikhov@globallogic.com >
Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11060 >
2021-06-03 04:44:24 +00:00
Eric Anholt
7403463508
u_format: Use the computed BE channels/swizzles for bitmask formats.
...
No more error-prone encoding of swizzles in the .csv for non-planar
formats!
No change to generated u_format_table.c
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
1c1997267f
u_format: Sanity check that BE swizzles are appropriately mapped from LE.
...
Once you read enough of them, there's an obvious pattern that we can just
write a little code for instead of making every dev write it out each time.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
36569b9f8c
u_format: Sanity check the BE channels for all bitmask formats.
...
Just check against the CSV (which has its codegen now tested with
u_format_test in CI) for now, so we know that our computed channels are
correct.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
9d77cecf88
u_format: Fix the BE channel ordering for R5G5B5A1_UINT.
...
It notably didn't fit the pattern of RGB5_A1_UNORM, and violated the
general pattern for bitmask format BE channels (channels are ordered
right-to-left in the BE columns in the CSV due to the parser walking them
in that order for historical reasons).
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
4dac360d5a
u_format: Define tests for r3g3b2 formats and fix BE swizzles for them.
...
These tests passed for LE, and the BE channel ordering specified obviously
didn't fit the pattern of the other BE formats (channels are listed
right-to-left in the BE columns for historical reasons).
Note that we can't write pure-integer format tests in u_format_tests.c
currently.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
c144f988e1
u_format: Assert that array formats don't include BE swizzles.
...
Z32_FLOAT_S8X24_UINT and X32_S8X24_UINT are in fact the only non-bitmask
formats that have BE swizzles specified, but sorting out those two is
harder.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Emma Anholt
397e80762e
u_format: Use the nice helper for reversing an array.
...
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
c8ef4f3615
u_format: Move the BE swizzle computation into Format init.
...
I wanted to do the next set BE changes here where I have Format's helper
functions available.
No changes in generated u_format_table.c.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
8a40780466
u_format: Drop redundant .name init.
...
It's the first member that's set.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Eric Anholt
a7fdddb133
u_format: Fix some pep8 in u_format_parse.py.
...
My editor likes to enforce pep8, here's some low hanging fruit so I don't
have to do too much add -p.
Acked-by: Adam Jackson <ajax@redhat.com >
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505 >
2021-06-03 00:12:39 +00:00
Ian Romanick
517247a8d9
util/format: Add Y21x formats
...
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9610 >
2021-05-21 01:40:22 +00:00
Ian Romanick
0820f1f3d0
util/format: Add Y41x formats
...
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9610 >
2021-05-21 01:40:22 +00:00
Ian Romanick
9e9bedfdcb
util/format: Delete trailing whitespace
...
The angry red marks in Emacs were annoying me.
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9610 >
2021-05-21 01:40:22 +00:00
Adam Jackson
4770d6c01d
format/fxt1: Clean up fxt1_variance's argument list
...
gcc 11 warns:
../src/util/format/u_format_fxt1.c:940:22: warning: ‘fxt1_variance.constprop’ accessing 128 bytes in a region of size 64 [-Wstringop-overflow=]
940 | int32_t maxVarR = fxt1_variance(NULL, &input[N_TEXELS / 2], n_comp);
But, suspiciously, if you inline fxt1_variance the warning goes away.
What's happening is that the 2nd arg is uint8_t[N_TEXELS][MAX_COMP], so
it looks like we're passing too small of an array in since gcc knows
that `input` is also [N_TEXELS][MAX_COMP]. Fair enough. Fix the
signature to reflect what's actually going on, and remove some unused
arguments while we're at it.
Reviewed-by: Matt Turner <mattst88@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10671 >
2021-05-06 21:25:47 +00:00
Eric Anholt
02e85777cb
u_format: Add missing BE swizzles for R8SG8SB8UX8U_NORM
...
Compare to the swizzles for PIPE_FORMAT_R10G10B10A2_UNORM and
R5SG5SB6U_NORM. This should fix our last BE pack/unpack failure.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7776 >
2021-04-28 09:51:09 +00:00
Eric Anholt
82c6f2ea32
u_format: Fix z32_s8x24 s8 unpacking on big-endian.
...
The s8x24 is a packed group in the format, and for packing we properly
write our s8 in the low bits of the 32, but for unpacking we tried
treating it as a byte array.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7776 >
2021-04-28 09:51:09 +00:00