Advertisement

VBO and GLSL

Started by February 18, 2006 02:54 AM
1 comment, last by todi1856 18 years, 6 months ago
Hello, i am building terrain using VBO's and GLSL, and i have some problems transfering data per vertex, cause my vertices, texture coords are all puted inside VBO, so how can i pass attribute data to shader ?!
You can pass one or two colors trough the VBO that i know of, possibly even more types of data.
Now i don't know what type of atribute data you want but 8 floats per vertic should do for a while at least.
Advertisement
Well i've found what i was looking for :)

http://www.lighthouse3d.com/opengl/glsl/index.php?oglattribute

Passing attribute to shader per vertex is very useful, as i noticed now.

Thx for reply, but i cant pass color through vbo and use it in shader, cause i'm using it for lighting .

This topic is closed to new replies.

Advertisement