IIPMooViewer is a high performance Ajax-based javascript image streaming and zooming client for the IIPImage system compatible with Firefox / Mozilla (and other gecko-based browsers), Internet Explorer versions 6 & 7, Safari and Opera. It is based on the Mootools javascript framework. Version 1.1 of IIPMooViewer requires Mootools version 1.2. The distribution contains all the necessary library files in both compressed and uncompressed formats. Modify the parameters in the iipmooviewer.html example file provided.

Example Usage

Here is a very minimal html example:

<?xml version="1.0" encoding="UTF">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
<link rel="stylesheet" type="text/css" media="all" href="css/iip.css" />
<script type="text/javascript" src="javascript/mootools-1.2-core.js"></script>
<script type="text/javascript" src="javascript/mootools-1.2-more.js"></script>
<script type="text/javascript" src="javascript/iipmooviewer-1.1.js"></script>

<script type="text/javascript">
iip = new IIP( "targetframe", { image: '/path/to/image.tif' } );
<div id="targetframe" style="width:99%;height:99%"></div>

Note that you must name the div within which the viewer will be embedded “targetframe” and that you must assign the variable “iip” to your newly created IIP object. The “targetframe” div can be positioned to whatever size and position you wish within your page. Unlike in version 1.0, it’s size must be specified independently. If mootools clashes with javascript in the rest of your page, consider putting the viewer within an iframe.


The IIP constructor can take a range of options. The only mandatory option is to set the “image” path:

The full system path to the 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
The address of the IIPImage server. [default : "/fcgi-bin/iipsrv.fcgi"]
a credit, copyright or information to be shown on the image itself
the initial zoom level on start-up
the way in which tiles are rendered. Either ‘random’ where the tiles are fetched and rendered randomly or ‘spiral’ where the tiles are rendered from the center outwards [default : 'random']
whether to show the navigation buttons on start up: true or false [default : true]
pixels per mm

Note that the page must have a standard-compliant XHTML declaration at the beginning. There is an example HTML page included in the IIPMooViewer distribution: just unpack the distribution, modify the server and image paths to get it working.

Advanced Application Development

The viewer can also be used as a component within an imaging application. See the multispectral visualization example for a good example of how the viewer can be easily used to create an advanced custom application. In this example, image blending is accomplished by loading an array of images and dynamically changing the opacity level of a layer of tiles. The spectral graph is drawn within a <canvas> (or VML in IE) element created via the cross browser MooCanvas library.

Ajax Security

Note also that due to the Ajax security model, the IIP server must point to the same host as that from which your page has been served. If you want to host the IIP image server on a different machine, you will need to forward proxy requests to this other machine via your web server. See the server page for more details on how to do this.


See the demo page to see the client in action.

New in Version 1.1

  • Updated to use Mootools 1.2
  • Can now be embedded within page
  • Navigation buttons
  • Navigation window can be dragged anywhere within window
  • Support for image layers and image blending
  • Download progress bar
  • Several bug fixes
  • Cosmetic enhancements
  • etc.


IIPMooViewer must be used in conjunction with the IIPImage server. You can download the latest versions of both the server and IIPMooViewer on the download page.

Flattr this

Donations appreciated Bookmark and Share
Get IIPImage at SourceForge.net. Fast, secure and Free Open Source software downloads