问题
I'm in the middle of a difficult choice. I'd like to learn a language that can help me create application with a strong artistic/creative/graphic component and use it for commercial projects for my customers.
My first choice was OpenGL ES, i think of it as the "Standard" way to go through. But, in the meanwhile, i discovered this site : http://www.creativeapplications.net/ where i found many cool apps for ios, for most built using OpenFramewors and Cinder.
My question is: why choose this 2 "wrapper" instead of OpenGL? I need to understand benefits and disadvantages.
I'm not sure that using these frameworks i can mix in a easy (and standard) way (As for OpenGL) UIKit/Cocoa and Graphics. At the moment i still prefer OpenGL because i know that this's the way suggested by apple (i mean... proposed by Apple) and i'm sure that i can take advantage of it for my customer too. While i' not sure that using OF and Cinder i can fully manage UIKit and Cocoa without tricks.
回答1:
The benefits of using a framework are, as stated by Ruben, that you're not re-inventing the wheel. OpenGL doesn't come with a lot of classes you would normally need: Vectors, matrices, cameras, colour, images etc and the methods that you will need to work with them: normalise, arithmetic, cross product etc
Of course you can implement all this in OpenGL but if someone's done it before, why not just leverage that instead? Your choice of framework or library will depend on what implementation you prefer. OF will do things differently to Cinder which is different to another library instead.
You don't have to use everything a framework provides. If you don't like the base application (like Cinder for example) you can create your own contexts and what not and just use the framework's 3d maths libraries, or its image library, or whatever other part you want. Just include the relevant headers you want.
Alternatively you can just use a 3d math library if you are so inclined and do away with frameworks all together. This gives you more control over your rendering pipeline and also potentially decreases application size.
Ultimately what you choose will depend on its features and your preference for a particular style. I would suggest going with a framework or library you are comfortable with and that has been used in production (unless you are just playing around with stuff). Documentation is also important. If the docs/resources aren't very good I would shy away from using something.
Of course, if you want to learn the ins and outs (never a bad idea), by all means write your own library.
回答2:
I think the main advantage of choosing OF and Cinder is that you can focus on your creation better than loosing lots of hours dealing with the OpenGL library. Cinder even includes image downloading and memory treatment. However, you must be patient because these frameworks are being imported to the iOS platform right now.
In some months or years, everybody will use these frameworks that abstract all the stuff behind the graphics programming to bring them the full potential and time to make art!
回答3:
If you don't miss anything, i think you'd be OK with OpenGL alone.
Cinder offers some additional goodies, see http://libcinder.org/features/. Maybe triangulation, loading of system fonts, matrix support etc might be interesting for you in the future.
Also Cinder's Tinderbox makes creating new projects very easy.
回答4:
Now both Cinder and OF fully support iOS platform and you can use them easily in an iOS application.
also note that these frameworks are designed specially with designers and creative artists/coders in mind, but OpenGL is a technical standard for dealing with graphic hardwares.
回答5:
Note: I'm the author of this framework.
I've spent some time creating Rend, an Objective-C based OpenGL ES 2.0 framework for iOS. It's lightweight and focusing on pure rendering which may be appropriate for some projects.
Also, if you're creating your own framework, you may be able to use it for inspiration and code snippets.
http://github.com/antonholmquist/rend-ios
来源:https://stackoverflow.com/questions/5776839/opengl-es-openframeworks-cinder-and-ios-creative-development