| || |
Section 9: Putting a Pano on a Web Page
Choosing a Viewer There are many ways to view VR panoramas on a web site, and each has their good and bad points. Apple started this whole industry with their QuickTime player, but unfortunately, the lack of improvements over the years has lead others to create alternative viewers using Java, Flash, etc. Here's a short list of the free pano viewers commonly used:
There are several non-free viewers as well, but there's really no need to use any of them since the choices among the free ones is so good. All of these players have very similar HTML encoding interfaces, and below I will give a brief description of each.
This is really the only viewer which is guaranteed to display the full resolution of your panorama, and it's probably the most popular of all of the viewers. QuickTime is not the fanciest viewer, that's for sure, but it does what it's supposed to do. All Macintosh computers come with QuickTime installed, so anyone on a Mac will always be able to view QTVR panos on your web site. Windows users, however, have to install QuickTime before this will work. If the HTML is properly coded, then this installation process will be very automatic and easy:
QuickTime has one really nice feature which is progressive download viewing. The user can interact with the pano as the data is still being downloaded. Parts of the pano will appear as they're available. Information on the actual HTML encoding can be found on the PanoTools.org site.
Immervision PurePlayer Viewer
The Immervision PurePlayer Viewer is a free Java and/or Flash viewer that is the best of all the Java/Flash options. Unlike other Java viewers, this one intelligently manages memory. It compresses the texture data so that you can get higher resolution images than is possible with PTViewer, and it resizes images if there isn't enough Java memory for the full-sized version. It is a very powerful viewer with lots of customizable features, even lens flares.
The only downside to this viewer is that you've got to create an XML file for each panorama. For unknown reasons you cannot directly reference your JPEG image in the Java HTML code. Instead they make you reference an XML file that then references your JPEG. Cumbersome, but worth the results. I use the PurePlayer viewer as the default viewer for all of my panos. There is a Java memory limitation which limits you to around 6000 pixels wide for your panos which is pretty good, but borderline for full-screen. For full-screen panos you should use Quicktime.
When you download the PurePlayer viewer it includes a ton of sample code and documentation.
PangeaVR is a plug-in that I wrote because I was not happy with the other options available. Both QuickTime and Java were just too slow in my opinion, so I took it upon myself to write an OpenGL accelerated web browser plug-in for displaying QTVR files. The thing that makes PangeaVR so great is that it is amazingly smooth, so it gives a vivid sense of realism when interacting with a pano.
There are several issues with PangeaVR, however. The main issue is that I wrote it for the Mac. There is no Windows or Linux version of the plug-in... yet. The source code is freely available, so I'm hoping that someone will volunteer to spend a weekend porting it to the PC. The other issue is that the quality of the rendered image depends on the quality of the user's video card. Since OpenGL is rendering the images, the cubic textures have to fit into the card's VRAM. These are huge textures which require a lot of VRAM. If the user has 128MB or more VRAM then PangeaVR will look about as good as QuickTime, but be 40x faster. But as the VRAM drops, so does image quality. The pano's cube textures are shrunken down to fit in the available VRAM, so users with only 16MB of VRAM are going to see a fairly low-rez pano.
What Should You Use?
Hopefully, some day Apple will update QuickTime to render panos with OpenGL, and if that happens I'll say that go with that. Until that time, however, my recommendation is that your web site give the visitor an option to choose how they want to view it. For embedded panos in web sites you should use Immervision's PurePlayer, but for full-screen panos give the user a choice. Many web sites do this, so here are a few examples of how to present the viewing options to your visitors:
| || |