public LevelingDataDrawable(ISceneContext sceneContext) { this.sceneContext = sceneContext; if (sceneContext.Printer is PrinterConfig printer) { levelingDataMesh = LevelingMeshVisualizer.BuildMeshFromLevelingData(printer); } }
public LevelingDataDrawable(ISceneContext sceneContext) { this.sceneContext = sceneContext; if (sceneContext.Printer is PrinterConfig printer) { try { levelingDataMesh = LevelingMeshVisualizer.BuildMeshFromLevelingData(printer); } catch { // Create empty mesh if exception thrown building leveling mesh levelingDataMesh = new Mesh(); } } }