- Bug Fix: Pixelated aurora on some devices
We end up fixing this sort of thing here and there. Generally, it has to do with a texture effect slowly losing its integrity over time, until eventually it just looks like a smear of color. What's up with that?
Basically, 3D hardware operates at a fairly low level of accuracy. So long as you keep your numbers small, everything is fine, but bigger numbers get more and more granular. When you have a number like, say 1.0006 -- that goes down to one ten-thousandth. At small values, the hardware maintains enough accuracy for that to hold up just fine. There might actually be ten-thousand increments between 1 and 2.
If you go bigger though, this stops being true. If I had a value like 1000.0006 it might just get lopped off and be the same as 1000 is. At high values it might only have a handful of fractions between whole numbers. The higher you go, the less accurate the increments get. Mostly this is okay when it comes to real-time 3D rendering. A rough approximation is just fine.
So what does this have to do with pixelated aurora effects? Well, the aurora effect in Snowfall consists of a few overlapping animated models, each of which has a shader on it that's built out of a few layers of textures. One of these layers scrolls horizontally (the one mixing in the rainbow colors). As it moves, the colors drift across the screen.
How much that layer has moved at any given frame is based on the amount of time elapsed. This means if you've had the wallpaper running for a long time -- a few days perhaps -- that number is starting to get pretty big. That means we're up into the thousands or tens of thousands, and all of a sudden when the hardware goes to render the texture it's starting to get all blocky.
It's easy to fix this sort of problem itself once you know where it is -- in this case using the modulous operator to make sure the value doesn't ever get very large. The problem is that it's easy to miss doing that even when you know it might be an issue, and these sorts of bugs are easy to overlook since they take a long time to
show up. While we we make a point of testing every release, it may not have been left to
run for hours and hours at any given time.
Anyway, long update for a short change list. Hopefully that informs someone. :)