
function vrftutorial() {
	tutorial("img/swf/video_demo_vrf_2.swf", 1152, 782);				
}

function rectutorial() {
	tutorial("img/swf/video_demo_rec.swf", 1152, 782);				
}

function tutorial(relPath, flashW, flashH) {
				var WHrel = flashW / flashH;
				
				if ($J(window).height() < flashH) {
					flashH = $J(window).height() - 80;
					flashW = Math.round(flashH * WHrel);
				}
				else if ($J(window).width() < flashW) {
					flashW = $J(window).width() - 80;
					flashW = Math.round(flashW / WHrel);
				}
				
				$J("#overlay").height($J(window).height());
				$J("#overlay").css({"top" : $J(window).scrollTop(), "opacity" : "0.5", "display" : "block" } );
				$J("#lightwindow").css({"display" : "block", "width" : flashW + "px", "height" : flashH + "px", "margin-top" : "-"+Math.round(flashH/2)+"px", "margin-left" : "-"+Math.round(flashW/2)+"px" } );
				$J("#overlay").fadeIn(200);
				$J("#lightwindow").fadeIn(200);
				
				$J("#overlay").click(function() {
						$J("#lightwindow").hide();
						$J("#overlay").fadeOut(200);
					}
				);

				var so = new SWFObject(relPath, "flashtutorial", flashW, flashH, "8", "");
				so.addParam("quality", "high");
				so.write("lightwindow");
}

function lightWin() {
		
		
}


