High/low resolution switch/toggle button?

Special forum to share and discuss skins for Pano2VR and Object2VR
Post Reply
User avatar
hansvw
Posts: 13
Joined: Mon Dec 15, 2008 5:03 pm
Location: Genoa, Italy
Contact:

Hi Thomas,
is there a simple way to make a button that switches high/low res versions? Isn't a sort of pano id needed?
I could do that easily if I had only one panorama, using "open next panorama", switching the visibility of the two resolution buttons (one calling the high res pano from the low res one, and the other doing the opposite). If I had more panoramas, then I should have a couple of hi/low res buttons (HQ/LQ) for each panorama: for example, I'm viewing pano #1 at low res and clicking on the HQ button I get 1) the high res version to load, 2) the HQ button to disappear, 3) the LQ button to show. Then if I want to open a new pano from a hotspot, clicking on it I get 1) pano #2 to load, 2) the pano#1 LQ button to disappear, 3) the pano#2 LQ button to show. And so on.
I would like that each loaded pano could have an id, so that, naming the two swf files "[panoname]_hq" and "[panoname]_lq", the string [panoname] is taken as id (let's say $output.panoid). Doing so, one could use the "open next panorama" and specify something like "($output.panoid)_hq" or "($output.panoid)_lq" as url. That way only a single couple of HQ/LQ buttons would be required. Currently, ($output.filename) can't solve that
Or, hopefully, that stuff could already be done in an even simpler way...
I know I could switch between high and low resolution using html, but it wouldn't be a nice solution.

thanks in advance for your help,
Hans
Last edited by hansvw on Sun Dec 21, 2008 9:57 pm, edited 1 time in total.
User avatar
thomas
Chief Gnome
Posts: 2613
Joined: Fri Sep 01, 2006 3:56 pm
Location: Vienna, Austria
Contact:

You can already do this because if you create a custom hotspot template the $hu is just a place holder for the text in the hotspot URL field. This way you can do smart things like creating a "Wikipedia" hotspot template that uses "http://en.wikipedia.org/wiki/$hu" as "Goto URL" and the hotspot just provides the articles name like "Car" in the URL field. In your case you can do a "$hu_hq.swf" and provide just the pano name in the URL field. I hope this helps.
MfG, Thomas
User avatar
hansvw
Posts: 13
Joined: Mon Dec 15, 2008 5:03 pm
Location: Genoa, Italy
Contact:

Thanks Thomas, for having shared this smart thing (!), but what I understand is that your trick would be fine if I would need a hotspot, but I would like a button object which is referring to the current panorama (or, better, to an ID which is shared by a couple of hq/lq panoramas), not to a specific panorama.
As of now, the only way that I have found is that of creating a couple of hq/lq buttons for each pano, making them visible (hq or lq) when loading their pano, while hiding the previous ones.

Following your advice,
1 - I have created an hotspot and put "room1" as url and "r1" as ID
2 - created an hotspot template, setting the open next panorama url as $hu_hq.swf
Now, clicking on the hotspot the file room1_hq.swf will be loaded,
but, as I said, I need a button to do that. Tried in many ways to pass the $hu to buttons (via proxy) but had no success.
However, even being able to use $hu with buttons, I think that I would still need a couple of hq/lq buttons for each panorama.
Please, tell me that I'm wrong.

Thanks,
Hans
Post Reply