performance: 3d portion of the 3d window is drawn only when needed.