I was just missing a non-null texture check. - Removed references to texturewidthmask. What was that? SVN r244 (trunk)
SVN r4 (trunk)