Add and apply gstate.getTextureDimension(level)