OpenGL ES 2 would be an excellent choice.
Maybe not trivial but not that bad either. It's certainly worth considering further.
It's not trivial to use GL for 2D graphics though. The android Java 2d lib is a wrapper over skia. It's not part of the NDK, but if you compile your own build of it you might be able to use that to render 2d graphics in native code.Pepijn
On 26 Aug 2010, at 20:10, mingw android <mingw....@gmail.com> wrote:
> OpenGL ES 2 would be an excellent choice.
>
> > I have an existing large application in C code tha...
--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
...
To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.
You absolutely should not be using the private Skia APIs. Your app *will* break on different devices and platform versions.
On 26 Aug 2010 20:48, "Pepijn Van Eeckhoudt" <pep...@vaneeckhoudt.net> wrote:
It's not trivial to use GL for 2D graphics though. The android Java 2d lib is a wrapper over skia. It's not part of the NDK, but if you compile your own build of it you might be able to use that to render 2d graphics in native code.
Yes, definitely don't use the internal Android skia, it changes ABI frequently.
You can get a "standalone" version of skia from
http://code.google.com/p/skia/ and use that just like you would any
other drawing library (and link it in to your app statically). When
using skia (or any other drawing library) in this way though it
obviously has to be generic code and you can't really use any hardware
optimisations.
The only way you are going to get hardware accelerated blits,
stretches, etc is via OpenGLES - the downside for 2D work is that
frequent texture uploads/downloads can be slow enough to outweigh the
hardware accelerated portions of your code, so if you go this way you
want to try to do as much as possible inside GL.
- Gus
--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.