Is Dealing with Opengl ES 2 worth the trouble?

Member
Posts: 27
Joined: 2011.04
Post: #1
I'm just starting iphone game development, and I was wondering if dealing with the added complexity of Opengl ES 2 is worth it if you arent planning on using any of the new features? The game wont be very graphics intense so any added performance by OpenGL ES 2 may not be neccessary, and it's not going to be using any fancy shaders. There is a nice tutorial on 71squared.com that walks you through the proccess of taking the OpenGl ES template from Xcode 4 and converting it from using version 2 back into version 1. I'm planning to follow this tutorial as I dont think version 2 is neccessary, and I have a tutorial book that uses version 1 that I also may use as neccessary. I was just wondering if there are any other reasons to consider using the newer version 2 of OpenGl ES even when the added features aren't neccessary? (As an added bonus, is a viewcontroller needed for an openGL project? As far as im concerned it may only add more complexity, as i wanted my project to stay away from the UI stuff as much as possible for concistencies sake, even not using a MainWindow nib file. But does a viewController add any needed feature support, such as help with device orientation, memory management, or different devices [iphone vs. ipad]?) And if you've reached this point, thx for staying with me Grin

A 14 year old app developer...god help me...
Quote this message in a reply
Moderator
Posts: 1,560
Joined: 2003.10
Post: #2
Shaders give you a lot more control over what you're rendering, and the potential for better performance than ES1's fixed function pipeline. Learning GLSL and ES2's patterns will make you a better OpenGL programmer in general. That said, as far as I know, ES1 is still a perfectly viable choice if you don't need the fancy stuff.
Quote this message in a reply
Member
Posts: 27
Joined: 2011.04
Post: #3
Alright thanks for the reply. I'll stick with version 1 for my first project, as I'm new to development and it's simpler to use. But I will definetly try out version 2 later to keep up with progression.

A 14 year old app developer...god help me...
Quote this message in a reply
Member
Posts: 27
Joined: 2011.04
Post: #4
But does anyone have some input for my second question?

A 14 year old app developer...god help me...
Quote this message in a reply
Apprentice
Posts: 19
Joined: 2010.03
Post: #5
Quote:is a viewcontroller needed for an openGL project?

strictly speaking I don't think so, I got away without one for months.... but now I'm reaching the end of the project I wanted to add a 'mail a link to this game to your friends button' and I found that in order to use an MFMailComposeViewController I need to set a view controller as a delegate so I plopped on in to the code for that sole reason.
Quote this message in a reply
Member
Posts: 27
Joined: 2011.04
Post: #6
Oh ok, thats true, modal viewcontrollers do need a delegate to another view controller to be presented or dismissed. Thanks for that reason, that may needed, but I suppose it isnt too hard to squeeze a viewcontroller in if you dont have one.

A 14 year old app developer...god help me...
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #7
a view controller is a good place to setup the timer, have the main loop and do odd stuff like changing chapters, restarting the game, handle touch, accelerator input and saving and restoring game state, etc.

respect,
pk

iFrog is coming.
Quote this message in a reply
Member
Posts: 27
Joined: 2011.04
Post: #8
Thats true, I just thought you could still do that suff in the EAGLView. I' not entirely good on the relationship of viewcontrollers vs views, so I was asking if viewcontrollers have any specific advantages over view that may add specific features(such as device orientation and memory management). One good one is that modal viewcontrollers need a viewcontroller delegate to function. viewcontrollers can help with device orientation, but you can still do that in the EAGLView by modifying the projection matrix (i think thats the right matrix Ponder ).

A 14 year old app developer...god help me...
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #9
One thing that's useful for handling the device orientation with the controller is that you can make it the whole view (EAGLView + HUD if you're using UI components for it) orientate automatically to how the user is holding the device.

respect,
pk

iFrog is coming.
Quote this message in a reply
Member
Posts: 27
Joined: 2011.04
Post: #10
Yes, but im not planning on using UIKit elements over a EAGLView because that can slow performance quite a lot. I'm also trying to keep my game away from UIKit things as much as possible as i want to stick to c++ as much as possible to not overwhelm myself with Objective-C complications Wacko .

A 14 year old app developer...god help me...
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Dealing with inverted textures in OpenGL johncmurphy 7 7,117 Jun 15, 2009 08:11 AM
Last Post: Skorche
  Dealing with GLUT and OpenGL... RingoEST 10 5,836 Aug 16, 2008 12:24 AM
Last Post: RingoEST
  Dealing with Battery Low Warning During Full Screen AnotherJake 8 5,775 Feb 8, 2008 12:26 PM
Last Post: OneSadCookie
  Trouble turning an SDL surface into an OpenGL texture Joseph Duchesne 4 5,787 May 22, 2007 05:14 PM
Last Post: Joseph Duchesne
  The real meaning of GL_NICEST when dealing with fog. TomorrowPlusX 13 7,722 Jun 11, 2005 02:57 AM
Last Post: Andrew