Here ya go.
Works best in Pro... in Classic for some unknown reason each box drawn is automatically synced so it's real slow.
sync rate 0
sync on
` Zoom rate A setting of 1 in no zoom.
Zoom=3
load image "background.png",1,1
do
paste image 1,0,0,1
` Show the area around the mouse that's being zoomed
ink rgb(0,255,0),0
line mousex()-26,mousey()-26,mousex()-26,mousey()+26
line mousex()+26,mousey()-26,mousex()+26,mousey()+26
line mousex()-26,mousey()-26,mousex()+26,mousey()-26
line mousex()-26,mousey()+26,mousex()+26,mousey()+26
` Set the upper left corner relative to the mouse
` to start reading the pixels color
mx=mousex()-25:my=mousey()-25
` The starting x and y of the zoomed in boxes
zx=0:zy=0
` This does a 50x50 area around the mouse to zoom
for y=my to my+50
for x=mx to mx+50
` Get the color of one pixel
a=point(x,y)
` Change the current color to the color of the pixel
ink a,0
` Make a box in the zoomed area
box zx,zy,zx+Zoom,zy+Zoom
inc zx,Zoom
next x
zx=0
inc zy,Zoom
next y
sync
loop
The above puts the zoom on the same screen but it would be better to work on a different screen and show the zoom on the main screen... that way you don't have to worry about the zoom interferring with getting the colors of the pixels.
If you (or anybody) has any questions about the code ask away.
Note: Attached is the image I used but you can use any image you want.