mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-29 22:30:24 +01:00
Cell: added spu_unpack_A8R8G8B8()
This commit is contained in:
parent
2f8268aa02
commit
71e6cd0b66
1 changed files with 15 additions and 0 deletions
|
|
@ -91,4 +91,19 @@ spu_unpack_color(uint color)
|
|||
}
|
||||
|
||||
|
||||
static INLINE vector float
|
||||
spu_unpack_A8R8G8B8(uint color)
|
||||
{
|
||||
vector unsigned int color_u4 = spu_splats(color);
|
||||
color_u4 = spu_shuffle(color_u4, color_u4,
|
||||
VEC_LITERAL(vector unsigned char,
|
||||
5, 5, 5, 5,
|
||||
10, 10, 10, 10,
|
||||
15, 15, 15, 15,
|
||||
0, 0, 0, 0));
|
||||
|
||||
return spu_convtf(color_u4, 32);
|
||||
}
|
||||
|
||||
|
||||
#endif /* SPU_COLORPACK_H */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue