MCPcopy Create free account
hub / github.com/comaps/comaps / GetBytesPerPixel

Function GetBytesPerPixel

libs/drape/texture_types.hpp:47–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45};
46
47inline uint8_t GetBytesPerPixel(TextureFormat format)
48{
49 uint8_t result = 0;
50 switch (format)
51 {
52 case TextureFormat::RGBA8: result = 4; break;
53 case TextureFormat::Red: result = 1; break;
54 case TextureFormat::RedGreen: result = 2; break;
55 case TextureFormat::DepthStencil: result = 4; break;
56 case TextureFormat::Depth: result = 4; break;
57 default: ASSERT(false, ()); break;
58 }
59 return result;
60}
61} // namespace dp

Callers 5

CreateMethod · 0.85
UpdateStateMethod · 0.85
StaticTextureMethod · 0.85
CreateMethod · 0.85
UploadDataMethod · 0.85

Calls 1

ASSERTFunction · 0.85

Tested by

no test coverage detected