function panotry(){  
  document.write ("<applet code='ptviewer.class' height='230' name='ptviewer' width='425' archive='images/ptviewer.jar'>")
  document.write ("<param name='quality' value='1'>")
  document.write ("<param name='barcolor' value='ffffff'>")
  document.write ("<PARAM name=bar_x value='130'>")
  document.write ("<PARAM name=bar_y value='120'>")
  document.write ("<PARAM name=bar_width value='170'>")
  document.write ("<PARAM name=bar_height	value='2'>")
  document.write ("<param name='file' value='ptviewer:0'>")
  for (i=0; i<panoname.length; i++)
  {
  document.write ("<param name='" + panoname[i] + "' value='{file=" + panofile[i] + "}{auto=" + panoauto[i] +  "}{wait=" + panowait[i] + "}{pan=" + panopan[i] + "}{fov=" + panofov[i] + "}{fovmin=" + panofovmin[i] + "}{fovmax="+ panofovmax[i] + "}{tilt=" + panotilt[i] + "}'>")
  }                                                                                 
  document.write ("</applet>")
}

function MM_jumpMenu(targ,selObj,restore){ 
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
function DoAutorotationDown() {
        document.ptviewer.startAutoPan( 0, -1, 1.0 );
}
function DoAutorotationUp() {
        document.ptviewer.startAutoPan( 0, 1, 1.0 );
}
function DoAutorotationLeft() {
        document.ptviewer.startAutoPan( -0.5, 0.0, 1.0 );
}
function DoAutorotationStart() {
        document.ptviewer.startAutoPan( 0.5, 0.0, 1.0 );
}
function DoAutorotationStop() {
        document.ptviewer.stopAutoPan();
}
function DoZoomIn() {
	document.ptviewer.startAutoPan( 0.0, 0.0, 1.0/1.03 );
}
function DoZoomOut() {
	document.ptviewer.startAutoPan( 0.0, 0.0, 1.03 );
}
function DisplayPan() {
	status = document.ptviewer.pan().toString() ;
}
function DisplayTilt() {
	status = document.ptviewer.tilt().toString() ;
}
function DisplayFov() {
	status = document.ptviewer.fov().toString() ;
}


function mousehs(n) {
	if( n== -1 )
   			document.cn.hsnum.value = "---" ;
	else
   			document.cn.hsnum.value = n ;
}
function getview(p,t,f) {
   document.cn.pan.value = p ;
   document.cn.tilt.value = t ;
   document.cn.fov.value = f ;
}


function startPano(n) {
        document.ptviewer.newPanoFromList(n);
        
}        
        
function NewPano(  ) {
	document.ptviewer.newPanoFromList(0);
}

