Merge remote-tracking branch 'upstream/development' into development
This commit is contained in:
commit
ec910f0540
7 changed files with 32 additions and 30 deletions
|
|
@ -521,7 +521,6 @@ namespace MatterHackers.MatterControl
|
|||
switch (PrinterConnectionAndCommunication.Instance.FirmwareType)
|
||||
{
|
||||
case PrinterConnectionAndCommunication.FirmwareTypes.Repetier:
|
||||
new EePromRepetierWidget();
|
||||
if (openEePromRepetierWidget != null)
|
||||
{
|
||||
openEePromRepetierWidget.BringToFront();
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ namespace MatterHackers.MatterControl
|
|||
|
||||
ImageBuffer buildingThumbnailImage = new Agg.Image.ImageBuffer();
|
||||
ImageBuffer noThumbnailImage = new Agg.Image.ImageBuffer();
|
||||
ImageBuffer tumbnailImage = new Agg.Image.ImageBuffer();
|
||||
ImageBuffer thumbnailImage = new Agg.Image.ImageBuffer();
|
||||
|
||||
// all the color stuff
|
||||
public double BorderWidth = 0; //Don't delete this - required for OnDraw
|
||||
|
|
@ -125,7 +125,7 @@ namespace MatterHackers.MatterControl
|
|||
ImageIO.LoadImageData(this.GetImageLocation(noThumbnailFileName), noThumbnailImage);
|
||||
ImageIO.LoadImageData(this.GetImageLocation(buildingThumbnailFileName), buildingThumbnailImage);
|
||||
}
|
||||
this.tumbnailImage = new ImageBuffer(buildingThumbnailImage);
|
||||
this.thumbnailImage = new ImageBuffer(buildingThumbnailImage);
|
||||
|
||||
// Add Handlers
|
||||
this.Click += new ButtonEventHandler(OnMouseClick);
|
||||
|
|
@ -160,7 +160,7 @@ namespace MatterHackers.MatterControl
|
|||
{
|
||||
if (thumbnailWidget.printItem == null)
|
||||
{
|
||||
thumbnailWidget.tumbnailImage = new ImageBuffer(thumbnailWidget.noThumbnailImage);
|
||||
thumbnailWidget.thumbnailImage = new ImageBuffer(thumbnailWidget.noThumbnailImage);
|
||||
thumbnailWidget.Invalidate();
|
||||
return;
|
||||
}
|
||||
|
|
@ -171,9 +171,9 @@ namespace MatterHackers.MatterControl
|
|||
{
|
||||
case ImageSizes.Size115x115:
|
||||
{
|
||||
ImageIO.LoadImageData(this.GetImageLocation("icon_sd_card_115x115.png"), thumbnailWidget.tumbnailImage);
|
||||
thumbnailWidget.tumbnailImage.SetRecieveBlender(new BlenderPreMultBGRA());
|
||||
Graphics2D graphics = thumbnailWidget.tumbnailImage.NewGraphics2D();
|
||||
ImageIO.LoadImageData(this.GetImageLocation("icon_sd_card_115x115.png"), thumbnailWidget.thumbnailImage);
|
||||
thumbnailWidget.thumbnailImage.SetRecieveBlender(new BlenderPreMultBGRA());
|
||||
Graphics2D graphics = thumbnailWidget.thumbnailImage.NewGraphics2D();
|
||||
Ellipse outline = new Ellipse(new Vector2(115 / 2.0, 115 / 2.0), 50);
|
||||
graphics.Render(new Stroke(outline, 4), RGBA_Bytes.White);
|
||||
}
|
||||
|
|
@ -181,9 +181,9 @@ namespace MatterHackers.MatterControl
|
|||
|
||||
case ImageSizes.Size50x50:
|
||||
{
|
||||
ImageIO.LoadImageData(this.GetImageLocation("icon_sd_card_50x50.png"), thumbnailWidget.tumbnailImage);
|
||||
thumbnailWidget.tumbnailImage.SetRecieveBlender(new BlenderPreMultBGRA());
|
||||
Graphics2D graphics = thumbnailWidget.tumbnailImage.NewGraphics2D();
|
||||
ImageIO.LoadImageData(this.GetImageLocation("icon_sd_card_50x50.png"), thumbnailWidget.thumbnailImage);
|
||||
thumbnailWidget.thumbnailImage.SetRecieveBlender(new BlenderPreMultBGRA());
|
||||
Graphics2D graphics = thumbnailWidget.thumbnailImage.NewGraphics2D();
|
||||
Ellipse outline = new Ellipse(new Vector2(50 / 2.0, 50 / 2.0), 22);
|
||||
graphics.Render(new Stroke(outline, 1.5), RGBA_Bytes.White);
|
||||
}
|
||||
|
|
@ -205,8 +205,8 @@ namespace MatterHackers.MatterControl
|
|||
{
|
||||
Mesh loadedMesh = StlProcessing.Load(thumbnailWidget.PrintItem.FileLocation);
|
||||
|
||||
thumbnailWidget.tumbnailImage = new ImageBuffer(thumbnailWidget.buildingThumbnailImage);
|
||||
thumbnailWidget.tumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
thumbnailWidget.thumbnailImage = new ImageBuffer(thumbnailWidget.buildingThumbnailImage);
|
||||
thumbnailWidget.thumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
bigRender = BuildImageFromSTL(loadedMesh, stlHashCode, bigRenderSize);
|
||||
if (bigRender == null)
|
||||
{
|
||||
|
|
@ -226,9 +226,9 @@ namespace MatterHackers.MatterControl
|
|||
halfWay2.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
halfWay2.NewGraphics2D().Render(halfWay1, 0, 0, 0, (double)halfWay2.Width / halfWay1.Width, (double)halfWay2.Height / halfWay1.Height);
|
||||
|
||||
thumbnailWidget.tumbnailImage = new ImageBuffer(50, 50, 32, new BlenderBGRA());
|
||||
thumbnailWidget.tumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
thumbnailWidget.tumbnailImage.NewGraphics2D().Render(halfWay2, 0, 0, 0, (double)thumbnailWidget.tumbnailImage.Width / halfWay2.Width, (double)thumbnailWidget.tumbnailImage.Height / halfWay2.Height);
|
||||
thumbnailWidget.thumbnailImage = new ImageBuffer(50, 50, 32, new BlenderBGRA());
|
||||
thumbnailWidget.thumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
thumbnailWidget.thumbnailImage.NewGraphics2D().Render(halfWay2, 0, 0, 0, (double)thumbnailWidget.thumbnailImage.Width / halfWay2.Width, (double)thumbnailWidget.thumbnailImage.Height / halfWay2.Height);
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
@ -238,9 +238,9 @@ namespace MatterHackers.MatterControl
|
|||
halfWay1.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
halfWay1.NewGraphics2D().Render(bigRender, 0, 0, 0, (double)halfWay1.Width / bigRender.Width, (double)halfWay1.Height / bigRender.Height);
|
||||
|
||||
thumbnailWidget.tumbnailImage = new ImageBuffer(115, 115, 32, new BlenderBGRA());
|
||||
thumbnailWidget.tumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
thumbnailWidget.tumbnailImage.NewGraphics2D().Render(halfWay1, 0, 0, 0, (double)thumbnailWidget.tumbnailImage.Width / halfWay1.Width, (double)thumbnailWidget.tumbnailImage.Height / halfWay1.Height);
|
||||
thumbnailWidget.thumbnailImage = new ImageBuffer(115, 115, 32, new BlenderBGRA());
|
||||
thumbnailWidget.thumbnailImage.NewGraphics2D().Clear(new RGBA_Bytes(255, 255, 255, 0));
|
||||
thumbnailWidget.thumbnailImage.NewGraphics2D().Render(halfWay1, 0, 0, 0, (double)thumbnailWidget.thumbnailImage.Width / halfWay1.Width, (double)thumbnailWidget.thumbnailImage.Height / halfWay1.Height);
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
@ -254,7 +254,7 @@ namespace MatterHackers.MatterControl
|
|||
|
||||
void EnsureImageUpdated(object state)
|
||||
{
|
||||
tumbnailImage.MarkImageChanged();
|
||||
thumbnailImage.MarkImageChanged();
|
||||
Invalidate();
|
||||
}
|
||||
|
||||
|
|
@ -419,7 +419,7 @@ namespace MatterHackers.MatterControl
|
|||
{
|
||||
graphics2D.Render(rectBorder, this.HoverBackgroundColor);
|
||||
}
|
||||
graphics2D.Render(tumbnailImage, Width / 2 - tumbnailImage.Width / 2, Height / 2 - tumbnailImage.Height / 2);
|
||||
graphics2D.Render(thumbnailImage, Width / 2 - thumbnailImage.Width / 2, Height / 2 - thumbnailImage.Height / 2);
|
||||
base.OnDraw(graphics2D);
|
||||
|
||||
RectangleDouble Bounds = LocalBounds;
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@
|
|||
<DebugType>full</DebugType>
|
||||
<Optimize>False</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>TRACE;DEBUG;</DefineConstants>
|
||||
<DefineConstants>TRACE;DEBUG;USE_OPENGL</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<AllowUnsafeBlocks>True</AllowUnsafeBlocks>
|
||||
|
|
|
|||
|
|
@ -278,7 +278,7 @@ namespace MatterHackers.MatterControl
|
|||
{
|
||||
if (Path.GetExtension(arg).ToUpper() == ".STL")
|
||||
{
|
||||
new PartPreviewMainWindow(new PrintItemWrapper(new DataStorage.PrintItem(Path.GetFileName(arg), Path.GetFullPath(arg))), View3DTransformPart.AutoRotate.Enabled);
|
||||
QueueData.Instance.AddItem(new PrintItemWrapper(new DataStorage.PrintItem(Path.GetFileName(arg), Path.GetFullPath(arg))));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -301,6 +301,9 @@ namespace MatterHackers.MatterControl
|
|||
[STAThread]
|
||||
public static void Main()
|
||||
{
|
||||
// Make sure we have the right woring directory as we assume everything relative to the executable.
|
||||
Directory.SetCurrentDirectory(Path.GetDirectoryName(System.Reflection.Assembly.GetEntryAssembly().Location));
|
||||
|
||||
Datastore.Instance.Initialize();
|
||||
|
||||
// try and open our window matching the last size that we had for it.
|
||||
|
|
@ -319,9 +322,6 @@ namespace MatterHackers.MatterControl
|
|||
|
||||
public override void OnClosed(EventArgs e)
|
||||
{
|
||||
// save the last size of the window so we can restore it next time.
|
||||
ApplicationSettings.Instance.set("WindowSize", string.Format("{0},{1}", Width, Height));
|
||||
ApplicationSettings.Instance.set("DesktopPosition", string.Format("{0},{1}", DesktopPosition.x, DesktopPosition.y));
|
||||
PrinterConnectionAndCommunication.Instance.Disable();
|
||||
//Close connection to the local datastore
|
||||
Datastore.Instance.Exit();
|
||||
|
|
@ -349,6 +349,10 @@ namespace MatterHackers.MatterControl
|
|||
string confirmExit = "Confirm Exit".Localize();
|
||||
public override void OnClosing(out bool CancelClose)
|
||||
{
|
||||
// save the last size of the window so we can restore it next time.
|
||||
ApplicationSettings.Instance.set("WindowSize", string.Format("{0},{1}", Width, Height));
|
||||
ApplicationSettings.Instance.set("DesktopPosition", string.Format("{0},{1}", DesktopPosition.x, DesktopPosition.y));
|
||||
|
||||
//Save a snapshot of the prints in queue
|
||||
QueueData.Instance.SaveDefaultQueue();
|
||||
|
||||
|
|
|
|||
|
|
@ -26,8 +26,6 @@ The views and conclusions contained in the software and documentation are those
|
|||
of the authors and should not be interpreted as representing official policies,
|
||||
either expressed or implied, of the FreeBSD Project.
|
||||
*/
|
||||
//#define RUN_MATTER_SLICE_IN_PROCESS
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
|
|
@ -234,7 +232,8 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
|
|||
break;
|
||||
}
|
||||
|
||||
if (OsInformation.OperatingSystem == OSType.Mac
|
||||
bool runInProcess = false;
|
||||
if (runInProcess || (OsInformation.OperatingSystem == OSType.Mac)
|
||||
&& ActivePrinterProfile.Instance.ActiveSliceEngineType == ActivePrinterProfile.SlicingEngineTypes.MatterSlice)
|
||||
{
|
||||
itemCurrentlySlicing = itemToSlice;
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ infill_first = 0
|
|||
infill_only_where_needed = 0
|
||||
infill_overlap_perimeter = .06
|
||||
infill_speed = 60
|
||||
infill_type = GRID
|
||||
infill_type = TRIANGLES
|
||||
layer_gcode =
|
||||
layer_height = 0.4
|
||||
min_extrusion_before_retract = .1
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ infill_first|Do Infill Before Perimeters|CHECK_BOX||Sets infill to happen before
|
|||
infill_only_where_needed|Only Infill Where Needed|CHECK_BOX||Creates infill only where it will be used as internal support.
|
||||
infill_overlap_perimeter|Infill Overlap|POSITIVE_DOUBLE|mm|The amount the infill edge will push into the preimiter. Helps ensure the infill is connected to the edge.
|
||||
infill_speed|Infill|POSITIVE_DOUBLE|mm/s|The speed to print infill.
|
||||
infill_type|Infill Type|LIST|GRID,LINES,TRIANGLES,CONCENTRIC|The type of support to create inside of parts.
|
||||
infill_type|Infill Type|LIST|CONCENTRIC,GRID,LINES,TRIANGLES|The type of support to create inside of parts.
|
||||
layer_gcode|Layer Change G-Code|MULTI_LINE_TEXT||This gcode will be inserted right after the change in z height for the next layer.
|
||||
layer_height|Layer Height|POSITIVE_DOUBLE|mm|Sets the height of each layer of the print. A smaller number will create more layers and more vertical accuracy but also a slower print.
|
||||
max_fan_speed|Max Fan Speed|INT|%|This is the maximum speed that your fan can run at.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue