Tatooine
texcomponents.h
Go to the documentation of this file.
1#ifndef TATOOINE_GL_TEX_COMPONENTS_H
2#define TATOOINE_GL_TEX_COMPONENTS_H
3//==============================================================================
5#include <tatooine/concepts.h>
6//==============================================================================
7namespace tatooine::gl {
8//==============================================================================
9struct R {
10 static constexpr GLsizei num_components = 1;
11};
12struct RG {
13 static constexpr GLsizei num_components = 2;
14};
15struct RGB {
16 static constexpr GLsizei num_components = 3;
17};
18struct RGBA {
19 static constexpr GLsizei num_components = 4;
20};
21struct BGR {
22 static constexpr GLsizei num_components = 3;
23};
24struct BGRA {
25 static constexpr GLsizei num_components = 4;
26};
27struct Depth {
28 static constexpr GLsizei num_components = 1;
29};
30//==============================================================================
31template <typename T>
33//------------------------------------------------------------------------------
34template <typename T>
35static auto constexpr texture_color_component =
37//==============================================================================
38template <typename T>
40 texture_color_component<T> || texture_depth_component<T>;
41//==============================================================================
42} // namespace tatooine::gl
43//==============================================================================
44#endif
Definition: concepts.h:18
Definition: texcomponents.h:39
Definition: ansiformat.h:6
static auto constexpr texture_depth_component
Definition: texcomponents.h:32
static auto constexpr texture_color_component
Definition: texcomponents.h:35
Definition: texcomponents.h:24
static constexpr GLsizei num_components
Definition: texcomponents.h:25
Definition: texcomponents.h:21
static constexpr GLsizei num_components
Definition: texcomponents.h:22
Definition: texcomponents.h:27
static constexpr GLsizei num_components
Definition: texcomponents.h:28
Definition: texcomponents.h:18
static constexpr GLsizei num_components
Definition: texcomponents.h:19
Definition: texcomponents.h:15
static constexpr GLsizei num_components
Definition: texcomponents.h:16
Definition: texcomponents.h:12
static constexpr GLsizei num_components
Definition: texcomponents.h:13
Definition: texcomponents.h:9
static constexpr GLsizei num_components
Definition: texcomponents.h:10