mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 14:16:07 -06:00
GLDraw: Fixed NVIDIA problem with DrawGL
git-svn-id: svn://ultimatepp.org/upp/trunk@14535 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
42c4056af0
commit
681981d94f
2 changed files with 4 additions and 2 deletions
|
|
@ -27,6 +27,7 @@ static GLuint LoadShader(const char *src, GLenum type) {
|
|||
glGetShaderInfoLog(shader, infoLen, NULL, infoLog);
|
||||
error << ~infoLog;
|
||||
}
|
||||
DLOG(error);
|
||||
Panic(error);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -10,14 +10,15 @@ void GLTriangles::Draw(const GLContext2D& dd)
|
|||
static GLCode program(R"(
|
||||
#version 130
|
||||
attribute vec3 p;
|
||||
attribute uvec3 c;
|
||||
attribute uvec3 col;
|
||||
uniform vec2 offset;
|
||||
uniform vec2 scale;
|
||||
varying vec4 v_color;
|
||||
void main()
|
||||
{
|
||||
gl_Position = vec4(scale * p.xy + offset, 0, 1);
|
||||
v_color = vec4(1/255.0 * c.rgb, p.z);
|
||||
vec3 c = col;
|
||||
v_color = vec4(1/255.0 * c.x, 1/255.0 * c.y, 1/255.0 * c.z, p.z);
|
||||
}
|
||||
)", R"(
|
||||
varying vec4 v_color;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue