summaryrefslogtreecommitdiff
path: root/src/video_core
diff options
context:
space:
mode:
authorGravatar Tony Wasserka2014-12-04 20:41:01 +0100
committerGravatar Tony Wasserka2014-12-09 16:37:34 +0100
commit79bb403089ff91c24b8356ad8d5bc5f7666a0d11 (patch)
tree83907606411e146ec64434438345d093bee696ca /src/video_core
parentSome code cleanup. (diff)
downloadyuzu-79bb403089ff91c24b8356ad8d5bc5f7666a0d11.tar.gz
yuzu-79bb403089ff91c24b8356ad8d5bc5f7666a0d11.tar.xz
yuzu-79bb403089ff91c24b8356ad8d5bc5f7666a0d11.zip
More coding style fixes.
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/pica.h18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/video_core/pica.h b/src/video_core/pica.h
index c1f35a011..b463a32ef 100644
--- a/src/video_core/pica.h
+++ b/src/video_core/pica.h
@@ -131,16 +131,22 @@ struct Regs {
131 }; 131 };
132 132
133 static unsigned BytesPerPixel(TextureFormat format) { 133 static unsigned BytesPerPixel(TextureFormat format) {
134 if (format == TextureFormat::RGBA8) 134 switch (format) {
135 case TextureFormat::RGBA8:
135 return 4; 136 return 4;
136 else if (format == TextureFormat::RGB8) 137
138 case TextureFormat::RGB8:
137 return 3; 139 return 3;
138 else if (format == TextureFormat::RGBA5551 || 140
139 format == TextureFormat::RGB565 || 141 case TextureFormat::RGBA5551:
140 format == TextureFormat::RGBA4) 142 case TextureFormat::RGB565:
143 case TextureFormat::RGBA4:
141 return 2; 144 return 2;
142 else // placeholder 145
146 default:
147 // placeholder for yet unknown formats
143 return 1; 148 return 1;
149 }
144 } 150 }
145 151
146 BitField< 0, 1, u32> texturing_enable; 152 BitField< 0, 1, u32> texturing_enable;