Texture mipmap fix

Closes #254
Closes #256