| 25 | } |
| 26 | |
| 27 | std::uint32_t TextureFormat::numChannels() const |
| 28 | { |
| 29 | switch (format_) { |
| 30 | case GL_RED: |
| 31 | return 1; |
| 32 | case GL_RG: |
| 33 | return 2; |
| 34 | case GL_RGB: |
| 35 | return 3; |
| 36 | case GL_RGBA: |
| 37 | #if !defined(WITH_OPENGLES) |
| 38 | case GL_BGRA: |
| 39 | #else |
| 40 | case GL_BGRA_EXT: |
| 41 | #endif |
| 42 | default: |
| 43 | return 4; |
| 44 | } |
| 45 | } |
| 46 | |
| 47 | void TextureFormat::bgrFormat() |
| 48 | { |
no outgoing calls
no test coverage detected