- Game Development Patterns and Best Practices
- John P. Doran Matt Casanova
- 215字
- 2021-07-02 23:43:43
The graphics engine
This book isn't about creating a graphics engine but we do need one to draw to the screen. Similar to how the M5App class encapsulates important OS function calls, our M5Gfx class encapsulates our graphics API. We want to make sure there is a clear separation between any API calls and our game logic. This is important so we can port our game to another system. For example, we may want to develop our game for PC, XBox One, and PlayStation 4. This will mean supporting multiple graphics APIs since a single API isn't available for all platforms. If our game logic contains API code, then those files will need to be modified for every platform.
We won't be going deep into the details of how to implement a full graphics engine, but we give an overview of how graphics works. Think of this as a primer to the world of graphics engines.
This class allows us manipulate and draw textures, as well as control the game camera and find the visible extents of the world. M5Gfx also manages two arrays of graphics components, one for world space and one for screen space. The most common use of the screen space components is for creating User Interface (UI) elements such as buttons.
- VMware View Security Essentials
- 軟件界面交互設計基礎
- Neo4j Essentials
- Java Web程序設計
- Python機器學習實戰
- STM32F0實戰:基于HAL庫開發
- MySQL數據庫管理與開發實踐教程 (清華電腦學堂)
- Full-Stack React Projects
- Kali Linux Wireless Penetration Testing Beginner's Guide(Third Edition)
- Mastering Google App Engine
- 基于Swift語言的iOS App 商業實戰教程
- 小程序開發原理與實戰
- MATLAB for Machine Learning
- Python大學實用教程
- SpringBoot從零開始學(視頻教學版)