Author Topic: naming the vertex attributes  (Read 1758 times)

Offline MichaelJPCT

  • float
  • ****
  • Posts: 264
    • View Profile
naming the vertex attributes
« on: January 03, 2016, 10:29:06 am »
say i created a plane with ExtendedPrimitives.createPlane,
in the object3d there is a mesh, and the mesh has vertex positions, uv coords, etc.
they are like vertex attributes, but they are not in VertexAttribute objects.

if i want to use shader with this plane and i need to access vertex position, normal, uv coords... how can i access them?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: naming the vertex attributes
« Reply #1 on: January 03, 2016, 10:37:00 am »
Desktop GL provides some magic attributes for that, like gl_position and such. In the wiki, you can find some shader examples for desktop OpenGL that should illustrate that.