private void AnalyseImageHandler() { var pt = new Point(AnalyseOpt["Center X"].Value, AnalyseOpt["Center Y"].Value); var sq = new Point(AnalyseOpt["Features X"].Value, AnalyseOpt["Features Y"].Value); var size = new Point(AnalyseOpt["ROI Width"].Value, AnalyseOpt["ROI Height"].Value); Cam = ChessBoard.Find(chessboardImage.ImageMat, sq, pt, size, ExportRawCorners); ImageData = ImageTypeConverter.Convert(chessboardImage.ImageMat.ToBitmap()); var json = JsonSerializer.Serialize(Cam); _eventAggregator.GetEvent <CameraCalibrationSendEvent>().Publish(json); }
private void OpenImageHandler() { chessboardImage = new ChessBoardImage(); ImageData = ImageTypeConverter.Convert(chessboardImage.ImageMat.ToBitmap()); }
private void AddCrossHandler() { OpenCvSharp.Point center = new OpenCvSharp.Point(1000 * CrossPosX / Cam["X um / px"], 1000 * CrossPosY / Cam["Y um / px"]); Crosshair.Draw(chessboardImage.ImageMat, center); ImageData = ImageTypeConverter.Convert(chessboardImage.ImageMat.ToBitmap()); }