improved back objects alpha

This commit is contained in:
LarsBrubaker 2021-04-12 07:25:50 -07:00
parent 4a997d725b
commit 6abec0ca68
8 changed files with 641 additions and 16 deletions

View file

@ -53,9 +53,9 @@ namespace MatterHackers.Plugins.EditorTools
private Vector3 initialHitPosition;
private readonly Mesh minXminYMesh;
private AxisAlignedBoundingBox mouseDownSelectedBounds;
private Matrix4X4 transformOnMouseDown = Matrix4X4.Identity;
private Matrix4X4 transformAppliedByThis = Matrix4X4.Identity;
private double DistToStart => 10 * GuiWidget.DeviceScale;
private double LineLength => 35 * GuiWidget.DeviceScale;
@ -188,11 +188,11 @@ namespace MatterHackers.Plugins.EditorTools
// don't draw if any other control is dragging
if (MouseIsOver)
{
GLHelper.Render(minXminYMesh, theme.PrimaryAccentColor, TotalTransform, RenderTypes.Shaded);
GLHelper.Render(minXminYMesh, theme.PrimaryAccentColor.WithAlpha(e.Alpha0to255), TotalTransform, RenderTypes.Shaded);
}
else
{
GLHelper.Render(minXminYMesh, theme.TextColor.Blend(theme.BackgroundColor, .25), TotalTransform, RenderTypes.Shaded);
GLHelper.Render(minXminYMesh, theme.TextColor.Blend(theme.BackgroundColor.WithAlpha(e.Alpha0to255), .35), TotalTransform, RenderTypes.Shaded);
}
}
}