Dynamic Field of View for Embedded QTVRs
Large panoramas can offer more detail, and allow zooming in to much higher level, but come at the cost of larger file sizes and longer downloads. Typical suggestions for the size of the source equirectangular images for cubic VR movies for web presentation is 5000x2500, which is roughly the full resolution for circular fisheye lenses on 1.5x crop factor SLR cameras. Much larger source images can be obtained from full-frame fisheye lenses, or rectilinear lenses, often shot in multiple rows to cover the entire sphere. Though QTVR movies made from sources images of 10000x5000 pixels or more are larger files (up to 10MB or more, depending on quality settings), increasing bandwidth availability means that it is icnreasingly less difficult to downloading these high-res panos.
Since most casual viewers do not zoom in on movies, such a large download can be wasted, even for full-screen panorama display, if the initial field of view is too large. Most of the detail available will not be seen. Full-screen display on large monitors means that even at a modestly wide initial zoom, most or all of the detail in a given panorama will be visible. The table below lists the vertical field of view required on monitor windows of a given height to achieve 1:1 pixel mapping from the source panorama to the display:
For instance, for a large 10000x5000 pixel equirectangular-source pano, the vertical field of view on a 1200 pixel high screen required to achieve 1:1 mapping of panorama pixels to display pixels is 41.3 degrees. Remember that toolbars, headers, etc. can reduce the vertical display size from the full monitor size.
In the header, you can enable full-screen by expanding the window as much as possible, and then compute an approximate window height. Remember to take into account any headers or other material which uses up vertical pixels in the fudge factor:
Note that this requires access to the width of the panorama's equirectangular source ($pano_width here). This can be supplied by hand or replaced via other methods (e.g. server-side processing).
Then the embed tag can then be written in the body where you'd like the QTVR to appear: