Writing a basic shader for large input files
Posted
by
Zoltan Varadi
on Game Development
See other posts from Game Development
or by Zoltan Varadi
Published on 2012-07-31T07:40:17Z
Indexed on
2012/08/30
9:51 UTC
Read the original article
Hit count: 227
I started writing a shader for my iOS app and instead of starting from scratch i used this tutorial here: http://www.raywenderlich.com/3664/opengl-es-2-0-for-iphone-tutorial
I wrote an import function, first to import wavefront .obj models. My problem is that with I can't handle larger inputs (with a simple cube it was working). I realized that the indices array is an array of GLubyte values, which is unsigned char, so as a result i cant have more than 256 indexes. I modified it to GLuint, but then only get a blank screen.
What else needs to me modified?
p.s.: the source can be downloaded from here: http://d1xzuxjlafny7l.cloudfront.net/downloads/HelloOpenGL.zip
© Game Development or respective owner