Exemplo n.º 1
0
        public void ShapeMatch(Bitmap bmp, ref List <PositionInfo> _Resultlist)
        {
            try
            {
                EImageC24 EC24Image1     = new EImageC24(); // EImageC24 instance
                EROIC24   EC24Image1Roi1 = new EROIC24();   // EROIC24 instance
                EC24Image1.SetSize(bmp.Width, bmp.Height);
                EC24Image1 = ConvertBitmapToEImageC24(bmp);

                _ShapeMatch(EC24Image1, ref _Resultlist);
            }
            catch (EException)
            {
                // Insert exception handling code here
            }
        }
Exemplo n.º 2
0
 private void _ShapeMatch(EROIC24 EC24Image1, ref List <PositionInfo> _Resultlist)
 {
     try
     {
         m_match.Match(EC24Image1);
         for (int i = 0; i < m_match.NumPositions; i++)
         {
             PositionInfo   info = new PositionInfo();
             EMatchPosition pos  = m_match.GetPosition(i);
             info.CenterX = pos.CenterX;
             info.CenterY = pos.CenterY;
             info.angle   = pos.Angle;
             info.scaleX  = pos.ScaleX;
             info.scaleY  = pos.ScaleY;
             info.score   = pos.Score;
             _Resultlist.Add(info);
         }
     }
     catch (EException)
     {
         // Insert exception handling code here
     }
 }