BGA检测面板: 修复无检测结果时叠加层未清除、结果图不透明、窗口尺寸调整

This commit is contained in:
李伟
2026-04-29 10:34:40 +08:00
parent 36083993ea
commit 6eff24e27b
2 changed files with 193 additions and 155 deletions
@@ -221,17 +221,18 @@ namespace XplorePlane.ViewModels.ImageProcessing
private void ShowResultOnOverlay(BitmapSource resultBmp)
{
if (_canvas == null || resultBmp == null) return;
if (_canvas == null) return;
// 移除旧的结果图层
RemoveResultOverlay();
if (resultBmp == null) return;
// 创建新的结果图层叠加到 canvas 上(插入到背景图之后、ROI之前)
_resultOverlayImage = new System.Windows.Controls.Image
{
Source = resultBmp,
IsHitTestVisible = false,
Opacity = 0.85,
Stretch = System.Windows.Media.Stretch.Fill
};
_resultOverlayImage.SetBinding(System.Windows.FrameworkElement.WidthProperty,