Scaling
Although scrolling is a popular and long-standing way to deal with large content, dynamically shrinking or enlarging content to “just fit” in a given space is more appropriate for several scenarios. For example, it doesn’t make sense for most games to change the shape of their game surface. Whether the game board or playing field must maintain a specific aspect ratio, or you want to avoid giving widescreen players an unfair advantage by seeing more of the scrolling world ahead, the typical approach is to scale up the game surface as much as possible and use letterboxing to fill any extra space (or perhaps show extra UI elements like game stats). If your app uses vector graphics, then you can scale to your heart’s content. If it uses bitmaps, ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access