Tagged Questions
0
votes
1answer
67 views
Get world-position in Vertex shader
I'm wondering how I can get the final position of a vertex. I use glTranslate in my render code, and I'm not getting the world-coordinates correct. My world is devided in chunks and my position get's ...
0
votes
1answer
96 views
GLSL Shaders-> How to manage?
As your game get's bigger and bigger, you will use more and more different shader effects.
Let's take an easy example:
I have clouds in my voxel-based world, and I want to give it a blue-ish tint ...
1
vote
1answer
121 views
How do I create geometry in SceneKit?
I have been experimenting with Apple's new SceneKit for fun, but I cannot seem to figure out how to input vertex data without loading a .dae file.
Does anybody who has been testing SceneKit have any ...
6
votes
1answer
175 views
GLSL vertex shaders with movements vs vertex off the screen
If i have a vertex shader that manage some movements and variations about the position of some vertex in my OpenGL context, OpenGL is smart enough to just run this shader on only the vertex visible on ...
7
votes
1answer
426 views
Best practices with Vertices in Open GL
What is the best practice in regards to storing vertex data in Open GL? I.e:
struct VertexColored {
public:
GLfloat position[];
GLfloat normal[];
byte colours[];
}
...
0
votes
3answers
1k views
Fastest solution to compute normal
A physics engine return a deformed mesh (only geometry vertices).
I take this mesh to render the geometry (~500000 vertices).
What is the fastest solution and the least expensive to compute normal ...
0
votes
1answer
567 views
How to make a 2D Terrain with opengl?
I want to make a simple 2d terrain with just a few bumps and height changes:
I thought about just using random numbers to describe the height of a certain vertex, but I don't see how I can make ...
4
votes
3answers
971 views
OpenGL Vertex Attributes - Normalisation
Alas, I have searched, and have found no definitive answer.
When would you normalize the vertex data in OpenGL using the following command:
glVertexAttribPointer(index, size, type, normalize, ...