Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 182

OpenGL (Open Graphics Library) is a graphics standard and API which is platform-independent and available for desktop, workstation and mobile devices. It is designed to provide hardware-accelerated rendering, and hence gives greatly improved performance over traditional software rendering. OpenGL is used for applications like CAD software and computer games. The OpenGL standard, as well as OpenGL ES, is controlled by the Khronos group.

4 votes

Errors on Compiling my first program on OpenGL on Ubuntu

You need to link with the OpenGL library. Try adding -lgl to the compilation command. …
3 votes

How to convert from glBegin() and glEnd() to VBOs?

Back when I did the transition from immediate mode to vertex buffer object (VBO) in my own code base, I have found it easier to proceed with these steps: From naive immediate mode code... The origin …
11 votes
Accepted

OpenGL GLSL - Sobel Edge Detection Filter

The best results strongly depend on your use case. They also depend on what effect you want to achieve. Sobel is just an edge detection filter: the edges will depend on the input signal, choosing tha …
2 votes

Is it possible to find out how many fragments made it through the stencil test?

If what you are interested in is the area, you could downsize the stencil buffer until you reach one pixel and deduce that area from its color. Steps would be: Copy the stencil to a texture, using …
10 votes
1 answer
2k views

What is the modern equivalent of display lists?

Display lists were an OpenGL feature that could, in theory, accelerate any part of the API by storing a group of commands for later use. …
15 votes
2 answers
15k views

GL_STATIC_DRAW vs GL_DYNAMIC_DRAW vs GL_STREAM_DRAW: does it matter?

In OpenGL the buffer object functions (glBufferData, glBufferSubData, and probably a few others) have a parameter usage, described by the documentation as a hint of the intended usage, likely meant to … It is perfectly legal OpenGL code to modify a STATIC buffer after it has been created, or to never modify a STREAM buffer. [...] …
2 votes

GLSL - Merge two textures

The simplest solution would be just a multiplication, which would give black edges: combinedColor = sceneColor * edgeRGB.r; For more control I would suggest something very similar to what @PaulHK p …
0 votes
Accepted

How can I use multiple texturing with shadow mapping?

If multi-texturing is supported, texture coordinate generation will affect the active texture unit (quote from the documentation, emphasis is mine): When the ARB_multitexture extension is supporte …
2 votes
Accepted

Project vertex onto plane

To answer your question we just need to write it as linear algebra equations and solve them. Although your question doesn't state it, I assume that $v$ and $d$ are unit vectors. Let's call the project …
2 votes
Accepted

How to dynamically calculate texture coordinates in a vertex shader with OpenGL?

Update to your additional questions and details: OpenGL throws an INVALID_OPERATION error OpenGL error handling is quite tricky, since you have to poll for errors yourself, and it uses the same few … The number of vertices is irrelevant on the shader side, but it must be consistent on the OpenGL declaration side. …
11 votes
1 answer
297 views

Do the alignement and declaration order of uniforms matter?

I assume a similar rule will apply to the OpenGL equivalent, Uniform Buffer Objects, since they map to the same hardware feature. What about vanilla uniforms though? …