No description
AI Reading Assistant
Whole-book reading guide from stratified index samples; jump to passages in the text
AI guide
# Beginning Android Games — Reading Guide
## 【One-Line Pitch】
A practical, project-driven guide for programmers who want to build 2D games for Android from scratch—covering everything from SDK setup and game design fundamentals to OpenGL ES rendering and performance optimization. Ideal for Java developers with some Android experience who want to move from "hello world" apps to shipping actual games.
## 【Book Arc】
- **Opening (~0%–13%)**: Introduces Android as a gaming platform—its history, architecture (kernel, Dalvik runtime, system libraries), and why mobile gaming differs from desktop/console development. Sets expectations about hardware fragmentation and market realities.
- **Early (~13%–23%)**: Walks through setting up the development environment (JDK, Android SDK, Eclipse) and covers game design fundamentals—genres, core mechanics, story, art style, and screen/transition management. Also introduces the essential code components: input, file I/O, audio, graphics, and the game framework concept.
- **Early–Middle (~23%–39%)**: Dives into Android-specific development—the manifest file, audio programming (sound effects vs. streaming music), basic graphics programming, and best practices. Then builds a reusable game framework (file I/O, audio, input handlers including accelerometer and touch, graphics with pixmaps, and a fast render view loop).
- **Middle (~39%–48%)**: Presents a complete sample game ("Mr. Nom") using the framework, then transitions to OpenGL ES—explaining the programming model, projections, matrices, rendering pipeline, and GLSurfaceView. Covers drawing triangles, per-vertex colors, and texture mapping.
- **Late (~48%+)**: Focuses on 2D game programming tricks and performance optimization—measuring frame rate, reducing state changes, minimizing texture sizes, cutting OpenGL ES/JNI calls, and vertex binding techniques.
## 【Key Takeaways】
- **Mobile gaming is a different beast** (Early): Unlike desktop gaming, Android games must account for hardware fragmentation, constant connectivity, casual vs. hardcore audiences, and small developer opportunities. Design decisions should start from these constraints.
- **Game design precedes code** (Early): Core mechanics, story, and art style should be defined before implementation. Screens and transitions are the structural backbone of any game—plan them explicitly.
- **A reusable framework saves your sanity** (Early–Middle): Building abstractions for file I/O, audio, input (keyboard, touch, accelerometer), and graphics lets you focus on game logic rather than platform plumbing. The book's framework (AndroidFileIO, AndroidAudio, AndroidInput, AndroidGraphics) is the model.
- **Input handling is multi-modal** (Early–Middle): Accelerometer, keyboard, and touch handlers each have distinct patterns and quirks. A coordinator class (AndroidInput) that unifies them simplifies game code enormously.
- **OpenGL ES is about understanding the pipeline** (Middle): Projections, matrices, normalized device space, and the rendering pipeline are the conceptual foundation. Once you grasp these, drawing triangles and texture mapping become mechanical.
- **Performance is a constant concern** (Late): Frame rate measurement, reducing state changes, shrinking textures, and minimizing OpenGL ES/JNI calls are the levers that keep games smooth on limited mobile hardware.
- **Texture management matters** (Middle): Texture coordinates, filtering, uploading bitmaps, and disposal are all part of the workflow—getting these right prevents visual artifacts and memory leaks.
## 【Reading Tips】
- **Skim the Android history and market analysis** (Opening): Interesting context, but not actionable for coding. Move quickly to Chapter 2's setup instructions.
- **Deep-read the game framework chapters** (Early–Middle): The framework design is the book's core value—understand how each class (FileIO, Audio, Input, Graphics, FastRenderView) fits together before building your own games.
- **Treat Chapter 7 (OpenGL ES) as a conceptual primer**: If you're new to OpenGL, read the analogy and programming model sections carefully; the matrix and projection material is dense but essential. Don't skip the "red triangle" example—it's the minimum viable render.
- **Use the Mr. Nom game as a reference implementation**: When the framework or OpenGL concepts feel abstract, see how they're applied in a complete, working game.
- **Pay attention to performance sections even if you're a beginner**: The optimization techniques (state changes, texture size, JNI calls) are the difference between a game that runs and one that runs well on real devices.
## 【Coverage Limits】
The excerpts cover roughly the first half of the book (through early 2D game programming tricks). Later chapters on advanced topics (3D graphics, physics, AI, publishing) are not covered in this guide.
##
Page 3
or information on translations, please e-mail rights@apress.com, or visit www.apress.com. Apress and friends of ED books may be purchased in bulk for academi...
View in text
Page 7
........................... 26 Installing Eclipse ..............................................................................................................
View in text
Page 8
............................................................ 194 KeyboardHandler: Up, Up, Down, Down, Left, Right . . . ........................................
View in text
Page 9
............................................................ 310 A Texture Class ...............................................................................
View in text
Page 5
....... 442 Implementing Super Jumper ..........................................................................................................................
View in text
Page 8
.......... 565 Implementing an OBJ Loader ......................................................................................................................
View in text
Page 14
y Chambers, Antigen, Wixel, Light Racer, and Light Racer 3D. Before diving full-time into mobile video game development and publishing, Robert worked for sof...
View in text
Page 17
is book’s code from which other readers can benefit as well. • A discussion group that is free for everybody to join and discuss the contents of the book. I’...
View in text
Tags
AI categories
Java移动Programming Language
Text Preview (First 20 pages)
Registered users can read the full content for free
Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.
Generating text preview…
Loading comments...
Reply to Comment
Edit Comment