Unity 4: AAA graphics and performance for your mobile games
Hi from the Unity Mobile team,
With Unity 4, you will have 10 platforms to which you can publish your awesome game. But in this blog, we’ll focus on the updates and new features for mobile development. You can start by taking a look at this video, which gives a nice overview of the features for mobile development. For more technical information on each feature, just keep reading! Thanks.
Unity 4 includes one of your most requested features: dynamic shadows on mobile devices! Mobile hardware is getting faster and faster, and with Unity 4, you can now cast hard dynamic shadows from directional lights.
Dynamic Fonts on Mobile
In Unity 4 you will be able to use dynamic fonts on mobile devices. You can include any OS fonts without having to include font data in your build. At runtime a font sheet is dynamically created with only the characters that are currently needed. This allows you to keep the build size down. If you do not want to use an OS font you can also embed ttf files (and fall back to OS fonts for missing characters / languages). Using dynamic fonts (embedded or not) saves runtime texture memory in languages where you have many characters, but typically do not use all of them. Additionally, Unity 4 also supports using HTML-like markup when rendering text. This allows for easy insertion of styles in an inline manner.
Both dynamic fonts and HTML like markup are part of the core unity product and are not limited to mobile platforms.
Normal maps considered when lightmapping
Lightmaps are a great way to improve the graphical fidelity of a game. In Unity 4 it is possible to bake lightmaps so that normal maps are included in the baking process. This means that it is possible to see the normal map information in static lighting. This works in all rendering modes and is not just limited to mobile hardware. This feature helps make lightmaps look amazing.
Automatic upscaling when rendered in lower resolution
In Unity 4 it’s possible to set a resolution for rendering that is different to the native device resolution. This allows you to render your game at a resolution lower than the screen resolution then for display upscale to the devices’ native resolution. Because you are rendering to a smaller buffer for the majority of rendering you will see good performance gains.
Eclipse project generation for Android
When building to Android you can now generate an Eclipse project instead of directly publishing from Unity. Doing this allows for easier integration and iteration when using third party libraries and you can also add Android specific code at this step. Once deployed to a device debugging can also be done via Eclipse.
GPU Profiling for Android devices with Tegra
When trying to squeeze the most of out of a game it’s important to profile. Profiling helps identify areas in your game that are running too slow, and areas that could have more assets added to them. You can now perform GPU profiling on a mobile game for Android with a Tegra chip. By using the Unity profiling tools you can profile on Tegra the same way that you would on a PC game. This includes getting individual draw call timings and being able to examine on a per frame basis the state of the rendering pipeline (memory usage, render texture usage, etc).