ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 IEVision problem/bug
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

yogiyang

India
725 Posts

Posted - Apr 09 2018 :  00:08:07  Show Profile  Reply
Hello,

I am using the latest version of IEVision (ver 4.0.0.0).

In the demos provided I am using GrabCutSelection for selecting character in an image which is attached here:



GrabCutSelection works perfectly when compiled as Win32 executable with above image. But if we compile it as Win64 it gives following error:



How to solve this please guide.

TIA


Yogi Yang

xequte

38182 Posts

Posted - Apr 11 2018 :  19:24:16  Show Profile  Reply
Hi Yogi

We'll have a fix in the upcoming 4.0.1. In the meantime you can workaround by disabling FP (for both FPU and SSE) exceptions with SetExceptionMask

For example:

procedure TMainForm.ButtonGrabCutSelectClick(Sender: TObject);
var
  gc: TIEVisionGrabCut;
begin
  SetExceptionMask([exInvalidOp, exDenormalized, exZeroDivide, exOverflow, exUnderflow, exPrecision]);
  gc := IEVisionLib().createGrabCut();
  gc.setInputImage(ImageEnView1.IEBitmap.GetIEVisionImage());
  case RadioGroupSelection.ItemIndex of
    0:  // rectangular selection
      begin
        gc.setForegroundRect(IEVisionRect(ImageEnView1.SelectedRect));
        //showmessage(format('%d %d %d %d', [ImageEnView1.SelectedRect.x, ImageEnView1.SelectedRect.y, ImageEnView1.SelectedRect.width, ImageEnView1.SelectedRect.height]));
      end;

    1: // irregular selection
      begin
        gc.setSelectionMask(ImageEnView1.SelectionMask);
      end;
  end;
  gc.run(5);
  ImageEnView1.Deselect;
  gc.getSelectionMask(ImageEnView1.SelectionMask);
  ImageEnView1.SelectCustom();
end;


Nigel
Xequte Software
www.imageen.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: