You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Texture::Texture(std::string name, constvoid* data, GLenum target, int width, int height, int depth, GLint internalFormat, GLenum format, GLenum type, bool isUserTexture)
48
+
: m_target(target)
49
+
, m_name(std::move(name))
50
+
, m_width(width)
51
+
, m_height(height)
52
+
, m_depth(depth)
53
+
, m_isUserTexture(isUserTexture)
54
+
, m_internalFormat(internalFormat)
55
+
, m_format(format)
56
+
, m_type(type)
57
+
{
58
+
glGenTextures(1, &m_textureId);
59
+
Update(data);
60
+
}
61
+
46
62
Texture::~Texture()
47
63
{
48
64
if (m_textureId > 0)
@@ -94,6 +110,11 @@ auto Texture::Height() const -> int
94
110
return m_height;
95
111
}
96
112
113
+
autoTexture::Depth() const -> int
114
+
{
115
+
return m_depth;
116
+
}
117
+
97
118
autoTexture::IsUserTexture() const -> bool
98
119
{
99
120
return m_isUserTexture;
@@ -104,11 +125,40 @@ auto Texture::Empty() const -> bool
0 commit comments