diff options
| author | 2014-11-19 15:24:46 -0500 | |
|---|---|---|
| committer | 2014-11-19 15:24:46 -0500 | |
| commit | c0cd0fa78edc37795176c6fb45a52c1d015f3690 (patch) | |
| tree | 237f15dd9d986309000c995fde07088625e62239 /src/video_core/utils.h | |
| parent | Merge pull request #208 from lioncash/statics (diff) | |
| parent | Remove tabs in all files except in skyeye imports and in generated GL code (diff) | |
| download | yuzu-c0cd0fa78edc37795176c6fb45a52c1d015f3690.tar.gz yuzu-c0cd0fa78edc37795176c6fb45a52c1d015f3690.tar.xz yuzu-c0cd0fa78edc37795176c6fb45a52c1d015f3690.zip | |
Merge pull request #211 from linkmauve/master
Remove trailing spaces from the entire project
Diffstat (limited to 'src/video_core/utils.h')
| -rw-r--r-- | src/video_core/utils.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/video_core/utils.h b/src/video_core/utils.h index 9cb3d4d43..21380a908 100644 --- a/src/video_core/utils.h +++ b/src/video_core/utils.h | |||
| @@ -12,24 +12,24 @@ namespace FormatPrecision { | |||
| 12 | 12 | ||
| 13 | /// Adjust RGBA8 color with RGBA6 precision | 13 | /// Adjust RGBA8 color with RGBA6 precision |
| 14 | static inline u32 rgba8_with_rgba6(u32 src) { | 14 | static inline u32 rgba8_with_rgba6(u32 src) { |
| 15 | u32 color = src; | 15 | u32 color = src; |
| 16 | color &= 0xFCFCFCFC; | 16 | color &= 0xFCFCFCFC; |
| 17 | color |= (color >> 6) & 0x03030303; | 17 | color |= (color >> 6) & 0x03030303; |
| 18 | return color; | 18 | return color; |
| 19 | } | 19 | } |
| 20 | 20 | ||
| 21 | /// Adjust RGBA8 color with RGB565 precision | 21 | /// Adjust RGBA8 color with RGB565 precision |
| 22 | static inline u32 rgba8_with_rgb565(u32 src) { | 22 | static inline u32 rgba8_with_rgb565(u32 src) { |
| 23 | u32 color = (src & 0xF8FCF8); | 23 | u32 color = (src & 0xF8FCF8); |
| 24 | color |= (color >> 5) & 0x070007; | 24 | color |= (color >> 5) & 0x070007; |
| 25 | color |= (color >> 6) & 0x000300; | 25 | color |= (color >> 6) & 0x000300; |
| 26 | color |= 0xFF000000; | 26 | color |= 0xFF000000; |
| 27 | return color; | 27 | return color; |
| 28 | } | 28 | } |
| 29 | 29 | ||
| 30 | /// Adjust Z24 depth value with Z16 precision | 30 | /// Adjust Z24 depth value with Z16 precision |
| 31 | static inline u32 z24_with_z16(u32 src) { | 31 | static inline u32 z24_with_z16(u32 src) { |
| 32 | return (src & 0xFFFF00) | (src >> 16); | 32 | return (src & 0xFFFF00) | (src >> 16); |
| 33 | } | 33 | } |
| 34 | 34 | ||
| 35 | } // namespace | 35 | } // namespace |