Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

how to make zoom window on image?

Doing it a single display is much more difficult.  You would need to do the following steps in a fast loop:

 

1. Find the location of the mouse in the image (already have this property node).

2. Calculate the pixel coordinates of the rectangle you want to magnify.  This is mouse coords plus/minus delta.

3. Extract the rectangle of pixels from the original image, then expand them by a factor of X (this might be just one step).

4. Insert the magnified pixels into a copy of the original image in the correct location, still centered on mouse coords.

5. Display modified image.

 

I do wonder if this could be done as an overlay.  I know you can overlay bitmaps onto an image, so I would assume it would work.  It would essentially be the same steps.

 

Bruce

Bruce Ammons
Ammons Engineering
0 Kudos
Message 11 of 11
(872 Views)