I am just looking through all of the iOS performance tips regarding OpenGL ES 2.0 drawing and I am just wondering: “do they all apply equally to Android development?”
Are the processes the same irrespective of Android and iOS and are they just ‘pure’ OpenGL tips?
Specifically, does this tip apply to Android development too? Because it would change the way I currently create my attribute data:
When you are designing your vertex structure, align the beginning of each attribute to an offset that is either a multiple of its component size or 4 bytes, whichever is larger. When an attribute is misaligned, iOS must perform additional processing before passing the data to the graphics hardware.
As a line of principle, the same best practices apply to both platforms since some of them are “common sense” approaches (i.e. batching is one of them).
On the other side, the same golden rules do not necessarily apply to all android devices and I would like to explain what I mean.
the point is mainly due to the GPU architecture. If you read the best practices for the IOS devices, for sure they are referred to the PowerVR GPUs (excellent GPUs) which have certain characteristics that not necessarily respect the one of the other GPUs you will find in the Android massive number of devices.
For instance, in the Android market you will find for sure GPUs being part of the Adreno family, the Mali family and so on.
This means that, in order to benefit the best from all these devices, you should write the code according to the manufacturer’s best practices.
This means that you should study the SDK’s reccomendations of each one of them.
So, to cut a long story short, some of those best practices apply to android as well, some other, could collide with the GPUs specifics of some mobile devices.