Jump to content

  • Log In with Google      Sign In   
  • Create Account

CookedBird

Member Since 18 Dec 2012
Offline Last Active Nov 14 2013 03:32 PM

Topics I've Started

Help: Telling one mesh from another in the vertex shader

18 December 2012 - 11:09 AM

Sorry if this is vague, but I don't really know what I'm looking for to solve this, and I don't really know what to ask. I have a couple different meshes that I am rendering with different vbos. What I want is to give each mesh a position vector (and possibly more info later on, such as a skeleton animation) that it will use to calculate the new position of the mesh in the vertex shader. Right now I am giving each vertex an attribute called meshID which then gets the mesh's position vector from a uniform vec3 array. I feel like there must be a better way of telling each mesh apart or even assigning attributes to each mesh, but I don't know what it would be.

PARTNERS