IOS GLKIT texture cube

New to IOS OpenGL programming. I have completed some tutorials on the basics of OpenGL ES, and I am able to create a small demo program to draw the cube in the scene where I want I like to apply textures to the faces of a cube, but for some reason this seems to be an almost impossible task. I am using GLKit and I have searched all over and can’t find one on how to do this Simple tutorial without too many other faults. Can anyone point me in the right direction or have a tutorial? This shouldn’t seem to be a difficult thing. I must have missed something..
About this http://www. raywenderlich.com/, please go here to read many tutorials

Or here

http://www.raywenderlich.com/5223/beginning-opengl-es-2 -0-with-glkit-part-1

This one explains the texture in detail:

http://db-in.com/blog/2011/02/all-about- opengl-es-2-x-part-23/

I suggest not to use glkit directly (maybe some helper methods), because it is easier, because it works like opengl 1, gl es 2.0 Most tutorials will not use it and you will be confused.

Use this for glkit to load textures

https://developer.apple.com/library/ios/# documentation/GLkit/Reference/GLKTextureLoader_ClassRef/Reference/Reference.html#//apple_ref/doc/uid/TP40010922

Try to use Google like glkit texture example

This is what I got :

https://github.com/jlamarche/iOS-OpenGLES-Stuff/blob/master/GLKit%20Stuff/GLKBaseEffect%20Drawing%20Example%20with%20Texture/blah/MCViewController.m

On line 119 you can see how to use the texture, I didn’t check it, but it seems to work. I usually prefer to use normal opengl, because even if you have a simple program, the shader file is very simple (Such as less than 10 lines).

Novice IOS OpenGL programming. I have completed some tutorials on the basics of OpenGL ES, and I am able to create a small demo program, Draw the cube in the scene where I want it. I like to apply texture to the cube Decent, but for some reason this seems to be an almost impossible task. I’m using GLKit, I have searched all over and can’t find a simple tutorial on how to do this without too much Other problems. Can anyone point me in the right direction or have a tutorial? This shouldn’t seem to be a difficult thing. I must have missed something..

About this http://www.raywenderlich.com/, please go here to read many tutorials< p>

Or here

http://www.raywenderlich.com/5223/beginning-opengl-es-2-0-with-glkit-part-1

p>

This explains the texture in detail:

http://db-in.com/blog/2011/02/all-about-opengl-es-2-x-part-23/

I suggest not to use glkit directly (maybe some helper methods), because it is easier, because it works like opengl 1, most tutorials of gl es 2.0 will not use it and you will feel Confused.

Use this for glkit to load textures

https://developer.apple.com/library/ios/#documentation/GLkit/Reference/GLKTextureLoader_ClassRef/Reference/Reference. html#//apple_ref/doc/uid/TP40010922

Try to use Google like glkit texture example

This is what I got:

https:// github.com/jlamarche/iOS-OpenGLES-Stuff/blob/master/GLKit%20Stuff/GLKBaseEffect%20Drawing%20Example%20with%20Texture/blah/MCViewController.m

You can see on line 119 How to use textures, I didn’t check it, but it seems to work. I usually prefer to use plain opengl, because even if you have a simple program, the shader file is very simple (such as less than 10 lines).

Leave a Comment

Your email address will not be published.