I’ve added shadows to my game engine! OpenGL 2.0ES doesn’t support the standard method for shadows because you can’t access the depth buffer. So, my method basically requires packing the depth value into a vec4 and creating a regular texture buffer instead of a depth buffer.
Works great, but very expensive. It will almost certainly need to be disabled for anything below the iPhone5S. It seems the real expensive part isn’t drawing all the geometry twice. It’s the process of drawing it into a texture that is the real bottleneck.
Flatiron has been submitted and is awaiting approval!
I ran into a big roadblock last week, which delayed submission a few days. Apple requires that apps still need to support the iPhone 4S, which has the old 3.5″ screen and a 1.5:1 aspect ratio. Needless to say, all of Flatiron’s graphics were formatted for the newer standard 1.775:1 aspect ratio and they all needed to be re-formatted. Another big issue with the 4S was performance. I couldn’t get my hands on a 4S for testing, but I was able to test on a 5th Gen iPod which has similar hardware (but a 4″ screen). So hopefully it holds up on the 4S. I had to make some changes to get it working though. Most notably, the game will run at 30fps on iPods and 4S phones (it will still run at a smooth 60fps on any other device). This is because the game does a pretty heavy render-to-texture pass in order to simulate the flickery film grain look of old movies. The older devices’ PowerVR GPU just can’t handle it. And the textures used to produce that film grain had to be reduced on those devices to accommodate the limited 512MB RAM. The film-grain won’t look as sharp, but still works well enough.
In the meantime, check out this short and chaotic gameplay video: