diff options
author | Tiago Conceição <Tiago_caza@hotmail.com> | 2022-10-04 03:12:12 +0300 |
---|---|---|
committer | Tiago Conceição <Tiago_caza@hotmail.com> | 2022-10-04 03:12:12 +0300 |
commit | 6c38a83c056644d8582b559ac947816c3b3c19eb (patch) | |
tree | d97637d1751928ccd100c8deb0336443d28d01a7 | |
parent | a43a8cb2d5e322918047fcb9544d9690554c8bc6 (diff) |
v3.6.8v3.6.8
- (Fix) Occasional crash when detecting islands and/or repair issues (#568, #569)
-rw-r--r-- | CHANGELOG.md | 4 | ||||
-rw-r--r-- | RELEASE_NOTES.md | 26 | ||||
-rw-r--r-- | UVtools.Core/Managers/IssueManager.cs | 15 | ||||
-rw-r--r-- | UVtools.Core/UVtools.Core.csproj | 2 | ||||
-rw-r--r-- | UVtools.WPF/UVtools.WPF.csproj | 2 |
5 files changed, 16 insertions, 33 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 0cb7c51..1042e5a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 04/10/2022 - v3.6.8 + +- (Fix) Occasional crash when detecting islands and/or repair issues (#568, #569) + ## 01/10/2022 - v3.6.7 - **Layer:** diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 14d79fa..f07d248 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,26 +1,2 @@ -- **Layer:** - - (Add) Property: `LayerMatBoundingRectangle` - - (Add) Property: `LayerMatModelBoundingRectangle` - - (Add) Method: `GetLayerMat(roi)` -- **Issues:** - - **Islands:** - - (Improvement) Islands detection performance - - (Improvement) Required area to consider an island is now real area instead of bounding box area - - (Fix) Logic bug when combining with overhangs - - **Overhangs:** - - (Improvement) Overhangs detection performance - - (Improvement) Overhangs are now split and identified as separately in the layer - - (Improvement) Overhangs now shows the correct issue area and able to locate the problem region more precisely - - (Improvement) Compress overhangs into contours instead of using whole pixels, resulting in better render performance and less memory to hold the issue - - (Fix) Bug in overhang logic causing to detect the problem twice when combined with supports - - (Improvement) Touching bounds check logic to spare cycles -- **Tool - Raise platform on print finish:** - - (Add) Preset "Minimum": Sets to the minimum position - - (Add) Preset "Medium": Sets to half-way between minimum and maximum position - - (Add) Preset "Maximum": Sets to the maximum position - - (Add) Wait time: Sets the ensured wait time to stay still on the desired position. - This is useful if the printer firmware always move to top and you want to stay still on the set position for at least the desired time. - Note: The print time calculation will take this wait into consideration and display a longer print time. -- (Add) FileFormat: AnyCubic custom machine (.pwc) -- (Downgrade) OpenCV from 4.5.5 to 4.5.4 due a possible crash while detecting islands (Windows) +- (Fix) Occasional crash when detecting islands and/or repair issues (#568, #569) diff --git a/UVtools.Core/Managers/IssueManager.cs b/UVtools.Core/Managers/IssueManager.cs index 6ef1473..2a3f333 100644 --- a/UVtools.Core/Managers/IssueManager.cs +++ b/UVtools.Core/Managers/IssueManager.cs @@ -494,17 +494,18 @@ public sealed class IssueManager : RangeObservableCollection<MainIssue> using var islandRoi = image.RoiMat.Roi(rect); using var previousIslandRoi = previousImage.RoiMat.Roi(rect); - if (overhangImage is null) + var islandOverhangMat = overhangImage; + if (islandOverhangMat is null) { - overhangImage = new Mat(); - CvInvoke.Subtract(islandRoi, previousIslandRoi, overhangImage); - CvInvoke.Threshold(overhangImage, overhangImage, 127, 255, ThresholdType.Binary); + islandOverhangMat = new Mat(); + CvInvoke.Subtract(islandRoi, previousIslandRoi, islandOverhangMat); + CvInvoke.Threshold(islandOverhangMat, islandOverhangMat, 127, 255, ThresholdType.Binary); - CvInvoke.Erode(overhangImage, overhangImage, EmguExtensions.Kernel3x3Rectangle, + CvInvoke.Erode(islandOverhangMat, islandOverhangMat, EmguExtensions.Kernel3x3Rectangle, EmguExtensions.AnchorCenter, overhangConfig.ErodeIterations, BorderType.Default, default); } - using var subtractedImage = overhangImage.Roi(rect); + using var subtractedImage = islandOverhangMat.Roi(rect); var subtractedSpan = subtractedImage.GetDataByteSpan2D(); var subtractedStep = subtractedImage.GetRealStep(); @@ -522,6 +523,8 @@ public sealed class IssueManager : RangeObservableCollection<MainIssue> overhangPixels++; } + if(!ReferenceEquals(overhangImage, islandOverhangMat)) islandOverhangMat.Dispose(); + if (overhangPixels < overhangConfig.RequiredPixelsToConsider) // No overhang = no island { island = null; diff --git a/UVtools.Core/UVtools.Core.csproj b/UVtools.Core/UVtools.Core.csproj index 020fa6a..7e4e895 100644 --- a/UVtools.Core/UVtools.Core.csproj +++ b/UVtools.Core/UVtools.Core.csproj @@ -10,7 +10,7 @@ <RepositoryUrl>https://github.com/sn4k3/UVtools</RepositoryUrl> <PackageProjectUrl>https://github.com/sn4k3/UVtools</PackageProjectUrl> <Description>MSLA/DLP, file analysis, calibration, repair, conversion and manipulation</Description> - <Version>3.6.7</Version> + <Version>3.6.8</Version> <Copyright>Copyright © 2020 PTRTECH</Copyright> <PackageIcon>UVtools.png</PackageIcon> <Platforms>AnyCPU;x64</Platforms> diff --git a/UVtools.WPF/UVtools.WPF.csproj b/UVtools.WPF/UVtools.WPF.csproj index 4953dff..172952c 100644 --- a/UVtools.WPF/UVtools.WPF.csproj +++ b/UVtools.WPF/UVtools.WPF.csproj @@ -12,7 +12,7 @@ <PackageLicenseFile>LICENSE</PackageLicenseFile> <RepositoryUrl>https://github.com/sn4k3/UVtools</RepositoryUrl> <RepositoryType>Git</RepositoryType> - <Version>3.6.7</Version> + <Version>3.6.8</Version> <Platforms>AnyCPU;x64</Platforms> <PackageIcon>UVtools.png</PackageIcon> <PackageReadmeFile>README.md</PackageReadmeFile> |