Previously, textures that couldn't be found the first time around would not have this fact cached, so we'd run through the whole slow path of find_file with each blockid and data entry. This is what caused the chests texture generation function to take almost 12 seconds on my system, as it is looking for "normal.png" that hasn't existed in Minecraft textures for ages. Shoving the exception, if one is encountered, into the cache, and then re-raising it if we load it from the texture cache brings this number down to about 2 seconds. That's six times as fast! Concerns issue #1604.
211 KiB
211 KiB