Merge: gamnit: replace missing textures by a checker texture
authorJean Privat <jean@pryen.org>
Thu, 15 Jun 2017 19:43:37 +0000 (15:43 -0400)
committerJean Privat <jean@pryen.org>
Thu, 15 Jun 2017 19:43:37 +0000 (15:43 -0400)
Use a checker texture to replace textures that fail to load. This replaces the previous behavior where an invalid texture name was passed to OpenGL ES which displayed it as full black.

In support, revamp the implementation of `CheckerTexture` to be only black and white and to have a size of 32 pixels by default. The new color is more neutral while being easier to spot and report by an end user (see the tower in the screenshot below). And the new size will make it easier to see than the previous 2x2 on non-scaled 2D sprites.

Also intro `CustomTexture`, a texture build programmatically by setting the color of each pixel. This can be used to create very simple textures (like the crosshair or the fuel indicator in the screenshot) or to represent end user drawings. This API is not very optimized, but clients can still subclass `Texture` for performance critical textures.

![screenshot from 2017-06-10 14 30 13](https://user-images.githubusercontent.com/208057/27045782-11600cde-4f70-11e7-80ac-742e3ab96204.png)

Pull-Request: #2490


Trivial merge