GLI  0.5.0
texture_cube.hpp
Go to the documentation of this file.
1 
29 #ifndef GLI_CORE_TEXTURE_CUBE_INCLUDED
30 #define GLI_CORE_TEXTURE_CUBE_INCLUDED
31 
32 #include "image.hpp"
33 
34 namespace gli
35 {
36  class texture2D;
37  class textureCubeArray;
38 
40  {
41  public:
46 
47  public:
48  textureCube();
49 
51  explicit textureCube(
52  size_type const & Faces,
53  size_type const & Levels,
54  format_type const & Format,
55  dimensions_type const & Dimensions);
56 
58  explicit textureCube(
59  size_type const & Faces,
60  format_type const & Format,
61  dimensions_type const & Dimensions);
62 
64  explicit textureCube(
65  storage const & Storage);
66 
68  explicit textureCube(
69  storage const & Storage,
70  format_type const & Format,
71  size_type BaseLayer,
72  size_type MaxLayer,
73  size_type BaseFace,
74  size_type MaxFace,
75  size_type BaseLevel,
76  size_type MaxLevel);
77 
79  explicit textureCube(
80  textureCube const & Texture,
81  size_type const & BaseFace,
82  size_type const & MaxFace,
83  size_type const & BaseLevel,
84  size_type const & MaxLevel);
85 
87  explicit textureCube(
88  textureCubeArray const & Texture,
89  size_type const & BaseLayer,
90  size_type const & BaseFace,
91  size_type const & MaxFace,
92  size_type const & BaseLevel,
93  size_type const & MaxLevel);
94 
96  explicit textureCube(
97  texture2D const & Texture,
98  size_type const & BaseLevel,
99  size_type const & MaxLevel);
100 
101  operator storage() const;
102  texture2D operator[] (size_type const & Face) const;
103 
104  bool empty() const;
105  format_type format() const;
106  dimensions_type dimensions() const;
107  size_type layers() const;
108  size_type faces() const;
109  size_type levels() const;
110 
111  size_type size() const;
112  void * data();
113  void const * data() const;
114 
115  template <typename genType>
116  size_type size() const;
117  template <typename genType>
118  genType * data();
119  template <typename genType>
120  genType const * data() const;
121 
122  void clear();
123  template <typename genType>
124  void clear(genType const & Texel);
125 
126  size_type baseLayer() const;
127  size_type maxLayer() const;
128  size_type baseFace() const;
129  size_type maxFace() const;
130  size_type baseLevel() const;
131  size_type maxLevel() const;
132 
133  private:
134  storage Storage;
135  size_type BaseLayer;
136  size_type MaxLayer;
137  size_type BaseFace;
138  size_type MaxFace;
139  size_type BaseLevel;
140  size_type MaxLevel;
141  format_type Format;
142  };
143 }//namespace gli
144 
145 #endif//GLI_CORE_TEXTURE_CUBE_INCLUDED
size_type baseLayer() const
size_type levels() const
glm::uvec2 dimensions2_type
Definition: storage.hpp:60
storage::texcoord3_type texcoord_type
texture2D operator[](size_type const &Face) const
bool empty() const
storage::size_type size_type
dimensions_type dimensions() const
texture2D
Definition: texture2d.hpp:41
OpenGL Image (gli.g-truc.net)
storage::format_type format_type
format_type format() const
std::size_t size_type
Definition: storage.hpp:68
size_type baseFace() const
size_type baseLevel() const
size_type maxFace() const
size_type size() const
size_type layers() const
size_type maxLevel() const
size_type faces() const
storage::dimensions2_type dimensions_type
size_type maxLayer() const
glm::vec3 texcoord3_type
Definition: storage.hpp:66
format
Definition: format.hpp:34