add remote logging system using curl, normalize log messages removing \n, fix fra shaders precision issue, enable core and forward comp. in WGL, disable multisampling,
This commit is contained in:
@@ -31,13 +31,13 @@ bool Texture2D::create(int width, int height, GLint format, const uint8_t* data)
|
||||
m_format = format;
|
||||
glGenTextures(1, &m_tex);
|
||||
bind();
|
||||
glTexImage2D(GL_TEXTURE_2D, 0, format, width, height, 0, format, GL_UNSIGNED_BYTE, data);
|
||||
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8, width, height, 0, format, GL_UNSIGNED_BYTE, data);
|
||||
unbind();
|
||||
return true;
|
||||
}
|
||||
bool Texture2D::create(const ui::Image& img)
|
||||
{
|
||||
static GLint formats[] = { 0, 0, GL_RGB, GL_RGBA };
|
||||
static GLint formats[] = { GL_RED, GL_RG, GL_RGB, GL_RGBA };
|
||||
return create(img.width, img.height, formats[img.comp - 1], img.data());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user