зеркало из https://github.com/mozilla/pjs.git
Bug 409381 - gif images (with transparency) display corrupted. p=swsnyder@insightbb.com, r,sr=vlad, a=blocking-1.9+
This commit is contained in:
Родитель
3f2844efd4
Коммит
341abaff96
|
@ -73,8 +73,13 @@
|
||||||
// Avoid tortured construction of 32-bit ARGB pixel from 3 individual bytes
|
// Avoid tortured construction of 32-bit ARGB pixel from 3 individual bytes
|
||||||
// of memory plus constant 0xFF. RGB bytes are already contiguous!
|
// of memory plus constant 0xFF. RGB bytes are already contiguous!
|
||||||
// Equivalent to: GFX_PACKED_PIXEL(0xff,r,g,b)
|
// Equivalent to: GFX_PACKED_PIXEL(0xff,r,g,b)
|
||||||
|
#ifndef IS_BIG_ENDIAN
|
||||||
# define GFX_0XFF_PPIXEL_FROM_BPTR(pbptr) \
|
# define GFX_0XFF_PPIXEL_FROM_BPTR(pbptr) \
|
||||||
(GFX_BYTESWAP32(*((PRUint32 *)(pbptr))) >> 8) | (0xFF << 24)
|
(GFX_BYTESWAP32(*((PRUint32 *)(pbptr))) >> 8) | (0xFF << 24)
|
||||||
|
#else
|
||||||
|
# define GFX_0XFF_PPIXEL_FROM_BPTR(pbptr) \
|
||||||
|
(*((PRUint32 *)(pbptr)) >> 8) | (0xFF << 24)
|
||||||
|
#endif /* IS_BIG_ENDIAN */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Fast approximate division by 255. It has the property that
|
* Fast approximate division by 255. It has the property that
|
||||||
|
|
Загрузка…
Ссылка в новой задаче