uses gdip

Screen 640,480,2
sys font= LoadFont ("arial",24)
'SetPixelMode 4

Function Absv(single n) as single
   iF n<0 
      Return n*-1
   Else 
      Return n
   End iF   
End Function

Function Euclid(sys x1,y1,z1) as sys
x1 = Abs(x1) 
   y1 = Abs(y1)
   z1 = Abs(z1)
   Return sqr((x1^2)+(y1^2)+(z1^2))
End Function

sys x,y,z,ix,s1
s1= LoadImage "png/tux.png",0

While Key(27)=0 
ClsColor 255,20,200,248

For x=0 To 200 step 16
 For y=0 To 100 step 28
  ix= Euclid(x,x,20)
  ZoomImage s1,-x+600,ix,x,x
  ix= Euclid(x,y,y)
  ZoomImage s1,x,ix,ix,x
 Next
Next
Flip
SetFps 60
Wend
Ends