Page 1 of 1

SetZoom Similar function in Gdpicture.net

Posted: Thu Jun 28, 2012 4:40 am
by edmundTing
HI,

I have 2 gdviewer control to display 2 different images. I need to zoom these 2 images simultaneously. Now i can only use the ZoomIn / ZoomOut function to zoom this 2 images at the same time. But when i change the gdViewer1 control mousemode to autoZoom mode, i can zoom the gdviewer1 image but i am unable to zoom the gdviewer 2 image.

There is a Function name SetZoom(zoompercentage as integer) for previous Gdpicture Pro toolkit where i am currently using. So my question is how can i zoom 2 images simultaneously when i using autozoom mode..

Re: SetZoom Similar function in Gdpicture.net

Posted: Thu Jun 28, 2012 10:13 am
by SamiKharma
Hi,
It is simple, can be done in three steps:
1. GdViewer1, once you autozoom you need to get the RECT coordinates:
https://www.gdpicture.com/guides/gdpicture/v8/html/con ... teger.html
2. GdViewer2, set those coordinates to make an ROI on GdViewer2:
https://www.gdpicture.com/guides/gdpicture/v8/html/con ... teger.html
3. GdViewer2 ZoomToRect:
https://www.gdpicture.com/guides/gdpicture/v8/html/con ... mRect.html

Hope this helps.
Best Regards,
Sami

Re: SetZoom Similar function in Gdpicture.net

Posted: Thu Jun 28, 2012 10:46 am
by edmundTing
Hi Sami,

Thank For your Reply...

But the problem is the GetRecCoordinates Function only will return value when you set the mouse mode = area selection.

So for my case, when my mouse mode = auto zoom, even there is a area selection but the GetRecCoordinates Function doesn't return me any value..

Please advice again...

Re: SetZoom Similar function in Gdpicture.net

Posted: Thu Jun 28, 2012 11:48 am
by SamiKharma
Hi,

You are right, there is a function for that:
https://www.gdpicture.com/guides/gdpicture/v8/html/con ... teger.html

Best Regards,
Sami