Skip to main content

Questions tagged [vertex-attribute]

Filter by
Sorted by
Tagged with
2 votes
1 answer
220 views

GLSL wrong data read from attribute

I'm developping an OpenGLes 3.0 app with Java and I started writing the shader code. For some reason, it seems to mix up the attributes data locations and I don't understand why. Here's the code : ...
Gyoo's user avatar
  • 286
2 votes
1 answer
3k views

What is the use of multiple vertex color sets

I noticed that Assimp supports meshes with multiple vertex color sets, but what is the use of multiple vertex color sets? I mean are multiple vertex color sets are really used in any games, and if yes,...
convert's user avatar
1 vote
1 answer
420 views

Puting all vertex attributes of a scene into a single VBO

I'm rendering various elements in OpenGL ES 2 on Android, and I'd like to pack the vertex attributes of the whole scene into a single vertex buffer object (VBO). My question is, if these objects have ...
Rodia's user avatar
  • 313
0 votes
1 answer
126 views

Easy way to generate colour-per-vertex models for input to Blender

I procedurally generate 3D planet models that I would like to import into Blender. I use colour per vertex rendering in my shaders (In practice, I use the same colour for all vertices of a face, but ...
Bram's user avatar
  • 3,734
1 vote
0 answers
677 views

OpenGL VAO buffer rebinding vs binding switching

I'm considering two different approaches to vertex buffer management in my OpenGL game engine. The first one seems to be pretty usual, but I haven't seen the second one being proposed or used anywhere....
Jacajack's user avatar
  • 111
0 votes
1 answer
655 views

Turning on Vertex Attribute Divisor With Instanced Rendering Renders Nothing

When I render with glDrawArraysInstanced with the vertex attribute divisor set to zero, the triangle appears as expected. But when the divisor is set to any value other than zero, the triangle ...
user121143's user avatar
0 votes
1 answer
955 views

OpenGL glVertexAttribFormat vs glVertexAttribPointer

I am attempting to change my code from using glVertexAttribPointer to glVertexAttribFormat as I have heard it;s more efficiend ...
Makogan's user avatar
  • 270
2 votes
2 answers
188 views

Easy way to edit vertex attributes

I'm trying to edit large amounts of vertex attributes in my models for my game. The main attributes I really care about are strength (so wind can interact with them) and a couple of other things so ...
J4S's user avatar
  • 173
1 vote
1 answer
80 views

Combining varying vertex variable and vertex variable in OpenGL. How to? [duplicate]

Let's say I have 2 triangles sharing an edge defined by 4 vertices. Though the normals for these 2 triangles are unique for each triangle and are defined per vertex. So say I have 4 vertices, 6 ...
user18490's user avatar
  • 132
1 vote
1 answer
2k views

How to pass array of dozens of floats to OpenGL 3.0 vertex shader?

I use PyOpengl and Python 3. I have 50 thousand vertices. Position of each vertex could be calculated in vertex shader as ...
Charlie's user avatar
  • 113
0 votes
1 answer
750 views

In game engine, how to get the vertices buffers of different vertex formats for render from the mesh file properly?

I'm a fresher on engine programming. I have a question of how we can get the vertices buffers of vertex formats from the mesh file. For example, in OBJ file or FBX file, we save the positions, ...
LLL's user avatar
  • 3
0 votes
1 answer
287 views

OpenGL won't interpret attributes correctly when trying to apply textures

I'm going through open.gl tutorials. I'm at the point where I want to apply textures. The tutorial first introduces texture coordinates to the vertices[] array, and ...
Varaquilex's user avatar
0 votes
1 answer
299 views

What data to store along a vertex

Is there any other recommended data I should store in the vertex buffers aside from a vertex' coordinates, normals and texture coordinates? For example data I'd need for a feature that almost every ...
Moritz Gunz's user avatar
0 votes
0 answers
410 views

How can I set the attribute index location?

I am trying to set up a shader which takes three input parameters. I have the following code: ...
Dan Nestor's user avatar
10 votes
2 answers
9k views

Vertex buffers - interleaved or separate? [closed]

Interleaved - all vertex data (position, normal, texcoord...) kept in 1 vertex buffer, separate - each vertex attribute is kept in a separate vertex buffer (1 for positions, 1 for normals...). I know ...
NPS's user avatar
  • 2,334