IIPZoom is a fast and lightweight Flash client for IIPImage which is fast and fluid with super-smooth zooming and panning. It’s built using the open source OpenZoom SDK. It requires users to have Flash 9 or greater installed.
Check out the demos and download the binary distribution. Inside you will also find not only the swf flash binary, but also an example HTML file showing how to use and configure the flash object with javascript. The source code is available in our SVN repositories.
The IIPZoom installation package consists of the IIPZoom.swf flash binary and some example HTML to get your started.
Options
IIPZoom can take 5 parameters. The image path is the only mandatory parameter:
- image:
- (required) The full absolute system path to the TIFF (or JPEG2000) image. On Windows as on other systems this should be a UNIX style path such as “/path/to/image.tif”. Note that this is an absolute system path and not the path relative to the webserver root
- server:
- (optional) The path to the iipsrv server. If this is not set, the default ‘/fcgi-bin/iipsrv.fcgi’ is used
- navigation:
- (optional) true or false. Sets whether or not to show a navigation window. True by default
- credit:
- (optional) information or credit message to be added to the bottom right of the image
- viewportBounds
- (optional) Start the viewer with an initial view at a particular location and zoom level. Normalized ratios (0-1): left,right,width,height. For example
viewportBounds=0.2,0.5,0.5,0.4
Example Usage
Here is an example HTML page showing how to cleanly embed the flash object into your page using swfobject:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <script type="text/javascript" src="swfobject.js"></script> <script type="text/javascript"> var flashvars = { server: "/fcgi-bin/iipsrv.fcgi", image: /path/test.tif", navigation: true, credit: "copyright or information message" } var params = { scale: "noscale", bgcolor: "#000000", allowfullscreen: "true", allowscriptaccess: "always" } swfobject.embedSWF("IIPZoom.swf", "container", "100%", "100%", "9.0.0","expressInstall.swf", flashvars, params); </script> </head> <body> <div id="container"></div> </body> </html>