[REBOL] Image routines
From: atruter::hih::com::au at: 17-Jan-2002 18:11
Hi all, been a lurker for a while so time to give something back . . . ;)
For those interested in basic image manipulation, I have written a simple
object to handle scrolling and zooming operations (plus rotate and emboss).
The only big restriction at this stage is the fact that the image window
size (400x400 below) must be square. Enjoy!
view layout [
button "Rotate 0" [image/rotate img 0]
button "Rotate 90" [image/rotate img 90]
button "Rotate 180" [image/rotate img 180]
button "Rotate 270" [image/rotate img 270]
toggle "Emboss" [image/emboss img]
button "Reset" [image/reset img]
img: image 400x400 image/binary effect copy image/effect
arrow up keycode[up] [image/scroll/up img]
arrow down keycode[down] [image/scroll/down img]
arrow left keycode[left] [image/scroll/left img]
arrow right keycode[right] [image/scroll/right img]
button 24x24 "+" keycode[page-up] [image/zoom/in img]
button 24x24 "-" keycode[page-down] [image/zoom/out img]
text "NOTE: The arrow (up, down, left, right) and page up/down keys will also work."