Timeline for OpenGL color overlay
Current License: CC BY-SA 3.0
4 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 21, 2016 at 21:29 | vote | accept | The Coding Wombat | ||
Jan 15, 2016 at 20:24 | comment | added | Draco18s no longer trusts SE | I would have to check my own quad-drawing code, which is on another computer. I practically stole Minecraft's GUI setup and Tessellator "GL-helper" class. It was a much cleaner way of doing the menus than what I'd been doing in Unity prior (second camera in orthographic mode). It was a huge hassle to translate the calls, though. Not as much GL access as in Java. | |
Jan 15, 2016 at 20:21 | comment | added | The Coding Wombat |
I now call this method before drawing anything but it doesn't appear: public static void DrawQuad(float x, float y, float width, float height) { glColor4f(.3f, .3f, .3f, .3f); glBegin(GL_QUADS); glVertex3f(x, y, 1); //Top left corner glVertex3f(x + width, y, 1); //Top right corner glVertex3f(x + width, y + height, 1); //Bottom right corner glVertex3f(x, y + height, 1); //Bottom left corner glEnd(); } For all the other things I use glVertex2f does that have something to do with it?
|
|
Jan 15, 2016 at 20:09 | history | answered | Draco18s no longer trusts SE | CC BY-SA 3.0 |