Fixed critical error with texture wrapping.