Graphics

Android graphics are powered by a custom 2D graphics library and OpenGL ES 1.0 for high performance 3D graphics. The most common 2D graphics APIs can be found in the drawable package. OpenGL APIs are available from the Khronos OpenGL ES package, plus some Android OpenGL utilities.

When starting a project, it's important to consider exactly what your graphical demands will be. Varying graphical tasks are best accomplished with varying techniques. For example, graphics and animations for a rather static application should be implemented much differently than graphics and animations for an interactive game or 3D rendering.

Here, we'll discuss a few of the options you have for drawing graphics on Android, and which tasks they're best suited for.

If you're specifically looking for information on drawing 3D graphics, this page won't help a lot. However, the information below, on Drawing with a Canvas (and the section on SurfaceView), will give you a quick idea of how you should draw to the View hierarchy. For more information on Android's 3D graphic utilities (provided by the OpenGL ES API), read 3D with OpenGL and refer to other OpenGL documentation.

0 0

Post a comment