Rating:

(9 reviews)
Author: Kevin Brothaler
ISBN : 1937785343
New from $30.97
Format: PDF
Download books file now Free Download OpenGL ES 2 for Android: A Quick-Start Guide (Pragmatic Programmers) Paperback – July 3, 2013 for everyone book 4shared, mediafire, hotfile, and mirror link
Amazon.com Review
Top Five OpenGL ES Tips
1. Avoid expensive operations on the UI and rendering threads.
To avoid frame rate stutters or the dreaded "Application not responding" dialog from appearing, expensive operations should be run asynchronously in a background thread. This is especially important when it comes to the rendering thread, as rendering at 30 frames per second means that each frame has to complete in about 33 milliseconds to avoid frame stutters.
Garbage collection is an expensive operation that happens non-deterministically and can cause rendering stalls, so to avoid this, you'll also want to minimize object allocation during a frame to reduce pressure on the garbage collector. You may even see benefits to doing a manual GC at certain points in the application.
2. Do expensive texture and shader loads during intermissions.
Some expensive operations need to be done on the rendering thread, such as texture loads and shader compilations. These operations can cause noticeable stuttering if they happen in the middle of rendering, so to avoid this, preload these resources at opportune times, such as when the game / application is loaded, or at the beginning of each level.
3. Take advantage of the libraries out there.
There are many libraries out there that support OpenGL ES 2.0 development without boxing you into a framework or a closed-source middleware solution. Libgdx is one of these libraries, and by using a library like libgdx, you can more easily port your code to other platforms, as well as take advantage of the library's math classes and asset loading management.
4. Read the documentation.
The OpenGL specs and manuals are available for free from Khronos.org. Each GPU vendor also shares a wealth of free information on how to use their GPUs, and as you read the documentation, you'll find that they generally share a lot of advice in common, such as "minimize state switches" and "avoid discard in a fragment shader." Reading these documents and specs will give you a lot more insight into how the GPUs work at a lower level, and will help you understand what the pitfalls are, and how to avoid premature pessimization when writing your OpenGL code.
5. Focus on what will impress the end user.
Sometimes it's easy to lose sight of the end goal, and to become focused on optimizing areas that won't make much of a difference to the end user. Does it matter if we get this shader to execute 2% faster? Or will we make much more of a visual impact by finding a better artist? Find out what the most important areas are, and then focus on improving those first.
About the Author
Kevin Brothaler is the founder of Digipom, a mobile software development shop. He has extensive experience in Android development, and he also manages "Learn OpenGL ES":http://www.learnopengles.com/, an online set of OpenGL tutorials for Android and WebGL.
Direct download links available for Free Download OpenGL ES 2 for Android: A Quick-Start Guide – July 3, 2013
- Series: Pragmatic Programmers
- Paperback: 325 pages
- Publisher: Pragmatic Bookshelf (July 3, 2013)
- Language: English
- ISBN-10: 1937785343
- ISBN-13: 978-1937785345
- Product Dimensions: 0.7 x 7.2 x 9 inches
- Shipping Weight: 1.4 pounds (View shipping rates and policies)
Free Download OpenGL ES 2 for Android: A Quick-Start Guide – July 3, 2013
Download Link 1 -
Download Link 2