image = new Object();
context = new Object();
protocol = new Object();
metadata = new Object();
imageInfoMap = new Object();

//creates object with image information for image req=ctx was just sent for.
function getCurrImageInfo() {
	var rect = image.rect.split(',');
	var imageInfo = new Object();
	imageInfo.width = rect[2];
	imageInfo.height = rect[3];
	imageInfo.iv = image.version;
	return imageInfo;
}

//custom function for swapping out images. looks up image info in 'imageInfoMap' and pass image width, height
//and context id into the setImage call.
function fixSetImage(inImageName, inReset) {
	var imageInfo = imageInfoMap[inImageName];
	if(s7zoom) {
		s7zoom.setImage(inImageName, inReset, imageInfo.width, imageInfo.height, imageInfo.iv);
	}
}

