mirror of
https://github.com/NoelFB/blah.git
synced 2024-11-29 17:08:56 +08:00
forgot to include renderer updates from Texture commit
This commit is contained in:
parent
4c04fdd72f
commit
4fcd29b82f
|
@ -274,7 +274,7 @@ namespace Blah
|
|||
return m_format;
|
||||
}
|
||||
|
||||
void set_data(unsigned char* data) override
|
||||
void set_data(const u8* data) override
|
||||
{
|
||||
// bounds
|
||||
D3D11_BOX box;
|
||||
|
@ -295,7 +295,7 @@ namespace Blah
|
|||
0);
|
||||
}
|
||||
|
||||
void get_data(unsigned char* data) override
|
||||
void get_data(u8* data) override
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
|
|
|
@ -254,7 +254,7 @@ typedef char GLchar;
|
|||
GL_FUNC(BindTexture, void, GLenum target, GLuint id) \
|
||||
GL_FUNC(BindRenderbuffer, void, GLenum target, GLuint id) \
|
||||
GL_FUNC(BindFramebuffer, void, GLenum target, GLuint id) \
|
||||
GL_FUNC(TexImage2D, void, GLenum target, GLint level, GLenum internalFormat, GLint width, GLint height, GLint border, GLenum format, GLenum type, void* data) \
|
||||
GL_FUNC(TexImage2D, void, GLenum target, GLint level, GLenum internalFormat, GLint width, GLint height, GLint border, GLenum format, GLenum type, const void* data) \
|
||||
GL_FUNC(FramebufferRenderbuffer, void, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer) \
|
||||
GL_FUNC(FramebufferTexture2D, void, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level) \
|
||||
GL_FUNC(TexParameteri, void, GLenum target, GLenum name, GLint param) \
|
||||
|
@ -709,14 +709,14 @@ namespace Blah
|
|||
}
|
||||
}
|
||||
|
||||
virtual void set_data(unsigned char* data) override
|
||||
virtual void set_data(const u8* data) override
|
||||
{
|
||||
renderer->gl.ActiveTexture(GL_TEXTURE0);
|
||||
renderer->gl.BindTexture(GL_TEXTURE_2D, m_id);
|
||||
renderer->gl.TexImage2D(GL_TEXTURE_2D, 0, m_gl_internal_format, m_width, m_height, 0, m_gl_format, m_gl_type, data);
|
||||
}
|
||||
|
||||
virtual void get_data(unsigned char* data) override
|
||||
virtual void get_data(u8* data) override
|
||||
{
|
||||
renderer->gl.ActiveTexture(GL_TEXTURE0);
|
||||
renderer->gl.BindTexture(GL_TEXTURE_2D, m_id);
|
||||
|
|
Loading…
Reference in New Issue
Block a user