Making abutted faces union correctly

This commit is contained in:
Lars Brubaker 2022-05-12 18:15:07 -07:00
parent 2f3888137c
commit 721f41e74d
3 changed files with 13 additions and 7 deletions

View file

@ -368,11 +368,17 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
void SetToSolid()
{
// make sure the render mode is set to shaded or outline
if (sceneContext.ViewState.RenderType != RenderOpenGl.RenderTypes.Shaded
&& sceneContext.ViewState.RenderType != RenderOpenGl.RenderTypes.Outlines)
{
// make sure the render mode is set to outline
sceneContext.ViewState.RenderType = RenderOpenGl.RenderTypes.Outlines;
switch(sceneContext.ViewState.RenderType)
{
case RenderOpenGl.RenderTypes.Shaded:
case RenderOpenGl.RenderTypes.Outlines:
case RenderOpenGl.RenderTypes.Polygons:
break;
default:
// make sure the render mode is set to outline
sceneContext.ViewState.RenderType = RenderOpenGl.RenderTypes.Outlines;
break;
}
var currentOutputType = selectedItem.WorldOutputType();

@ -1 +1 @@
Subproject commit 8b8b6938b05a8780f079d2f2b6f9a69d621e090e
Subproject commit 5754263017523527f1c076b0c667fe56abb6e5bd

View file

@ -625,7 +625,7 @@ namespace MatterControl.Tests.MatterControl
new CancellationToken());
Assert.AreEqual(12, mesh.Faces.Count());
var aabb = mesh.GetAxisAlignedBoundingBox();
Assert.AreEqual(15, aabb.YSize, .001);
Assert.AreEqual(20, aabb.YSize, .001);
}
}