HEX
Server: Apache
System: Linux web204c0.megawebservers.com 5.14.0-570.37.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Aug 28 10:41:06 UTC 2025 x86_64
User: absolutespace.ca (53202)
PHP: 7.4.33
Disabled: apache_get_modules,apache_get_version,disk_free_space,phpinfo,exec,shell_exec,passthru,system,proc_nice
Upload Files
File: /services/webpages/a/b/absolutespace.ca/public/vtour/belmont/skin/plugins/flatpano_setup.xml
<krpano>
	<!-- krpano 1.18 viewing and controlling setup for flat panos -->

  <!-- view settings -->
	<!-- <view fovtype="HFOV" fov="1.0" fovmax="1.0" maxpixelzoom="2.0" limitview="lookat" /> -->

	<!-- control settings (drag2d for flat pano) -->
	<!-- <control mousetype="drag2d" touchtype="drag2d" zoomtocursor="true" zoomoutcursor="true" bouncinglimits="true" keycodesin="16" keycodesout="17" /> -->


	<!-- events and actions for adjusting the view settings to see the whole image -->
	<events name="flatpano_events" onresize="flatpano_imagefit();" />

	<!-- setup the view to show the whole image at startup -->
	<action name="flatpano_startup">

		div(pano_aspectratio, image.hfov, image.vfov);
		div(screen_aspectratio, area.pixelwidth, area.pixelheight);

		if(pano_aspectratio GT screen_aspectratio,

			set(view.fovtype, HFOV);
			copy(view.fov,    image.hfov);
			copy(view.fovmax, image.hfov);
		,
      
      set(view.fovtype, VFOV);
			copy(view.fov,    image.vfov);
			copy(view.fovmax, image.vfov);
		);
	</action>

	<!-- adjust the fov limits during resizing -->
	<action name="flatpano_imagefit">
		if(image.vfov GT 0,
			div(pano_aspectratio, image.hfov, image.vfov);
			div(screen_aspectratio, area.pixelwidth, area.pixelheight);

			if(pano_aspectratio GT screen_aspectratio,
				if(view.fovtype == VFOV,
						remapfovtype(view.fov, VFOV, HFOV, lastresize_width, lastresize_height);
						set(view.fovtype, HFOV);
						copy(view.fovmax, image.hfov);
				  );
			  ,
				if(view.fovtype == HFOV,
						remapfovtype(view.fov, HFOV, VFOV, lastresize_width, lastresize_height);
						set(view.fovtype, VFOV);
						copy(view.fovmax, image.vfov);
				  );
			  );
		  );

		set(lastresize_width, get(area.pixelwidth));
		set(lastresize_height, get(area.pixelheight));
	</action>

</krpano>