| 0.6.1

- Main Page
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

texture2d.hpp
Go to the documentation of this file.
1
29 #pragma once
30
31 #include "image.hpp"
32
33 namespace gli
34 {
35 class texture2DArray;
36 class textureCube;
37 class textureCubeArray;
38
40 class texture2D : public texture
41 {
42 public:
43 typedef dim2_t dim_type;
44 typedef vec2 texcoord_type;
45
46 public:
47 texture2D();
48
50 explicit texture2D(
51 size_type const & Levels,
52 format_type const & Format,
53 dim_type const & Dimensions);
54
56 explicit texture2D(
57 format_type const & Format,
58 dim_type const & Dimensions);
59
61 explicit texture2D(
62 storage const & Storage);
63
65 explicit texture2D(
66 storage const & Storage,
67 format_type const & Format,
68 size_type BaseLayer, size_type MaxLayer,
69 size_type BaseFace, size_type MaxFace,
70 size_type BaseLevel, size_type MaxLevel);
71
73 explicit texture2D(
74 texture2D const & Texture,
75 size_type const & BaseLevel,
76 size_type const & MaxLevel);
77
79 explicit texture2D(
80 texture2DArray const & Texture,
81 size_type const & BaseLayer,
82 size_type const & BaseLevel, size_type const & MaxLevel);
83
85 explicit texture2D(
86 textureCube const & Texture,
87 size_type const & BaseFace,
88 size_type const & BaseLevel, size_type const & MaxLevel);
89
91 explicit texture2D(
92 textureCubeArray const & Texture,
93 size_type const & BaseLayer, size_type const & BaseFace,
94 size_type const & BaseLevel, size_type const & MaxLevel);
95
96 operator storage() const;
97 image operator[] (size_type const & Level) const;
98
99 dim_type dimensions() const;
100 glm::ivec4 swizzle() const;
101
102 template <typename genType>
103 genType fetch(dim_type const & TexelCoord, size_type const & Level);
104 };
105 }//namespace gli
106
107
gli::texture::size_type
size_t size_type
Definition: texture.hpp:38
gli::vec2
glm::vec2 vec2
Definition: type.hpp:52
gli::texture2D
texture2D
Definition: texture2d.hpp:40
gli::texture::MaxLayer
size_type const MaxLayer
Definition: texture.hpp:93
gli::texture2D::operator[]
image operator[](size_type const &Level) const
image.hpp
OpenGL Image (gli.g-truc.net)
gli::format
format
Definition: format.hpp:33
gli::texture2D::swizzle
glm::ivec4 swizzle() const
gli::texture2D::dimensions
dim_type dimensions() const
gli::ivec4
glm::ivec4 ivec4
Definition: type.hpp:56
gli::texture::BaseFace
size_type const BaseFace
Definition: texture.hpp:94
gli::dim2_t
glm::tvec2< size_t > dim2_t
Definition: type.hpp:48
gli::storage
Definition: storage.hpp:56
gli::texture::BaseLayer
size_type const BaseLayer
Definition: texture.hpp:92
gli::textureCubeArray
Definition: texture_cube_array.hpp:38
gli::texture::MaxFace
size_type const MaxFace
Definition: texture.hpp:95
gli::texture2D::texcoord_type
vec2 texcoord_type
Definition: texture2d.hpp:44
gli::texture2D::fetch
genType fetch(dim_type const &TexelCoord, size_type const &Level)
gli::texture::Storage
storage Storage
Definition: texture.hpp:90
gli::texture::MaxLevel
size_type const MaxLevel
Definition: texture.hpp:97
gli::texture::Format
format_type const Format
Definition: texture.hpp:91
gli::image
Image.
Definition: image.hpp:41
gli::textureCube
Definition: texture_cube.hpp:38
gli::texture::BaseLevel
size_type const BaseLevel
Definition: texture.hpp:96
gli::texture2DArray
Definition: texture2d_array.hpp:35
gli
Definition: addressing.hpp:33
gli::texture2D::dim_type
dim2_t dim_type
Definition: texture2d.hpp:43
gli::texture2D::texture2D
texture2D()
gli::texture
Definition: texture.hpp:35