Make sure we use the sha1 of the MCX so we rebuild correctly

issue: MatterHackers/MCCentral#4625
Changing the scene objects (position) not causing slice to re-calculate
This commit is contained in:
LarsBrubaker 2018-11-24 19:59:05 -08:00
parent db826071e1
commit f0f953ef6b
4 changed files with 5 additions and 6 deletions

View file

@ -171,9 +171,7 @@ namespace MatterHackers.MatterControl.Library.Export
string sourceExtension = $".{firstItem.ContentType}";
string assetPath = await AssetObject3D.AssetManager.StoreMcx(loadedItem, false);
string fileHashCode = Path.GetFileNameWithoutExtension(assetPath);
string gcodePath = printer.GCodePath(fileHashCode);
string gcodePath = printer.GCodePath(Object3D.ComputeFileSHA1(assetPath));
if (ApplicationSettings.ValidFileExtensions.IndexOf(sourceExtension, StringComparison.OrdinalIgnoreCase) >= 0
|| string.Equals(sourceExtension, ".mcx", StringComparison.OrdinalIgnoreCase))