made textures more flexible