Page 1 of 1

Toggle Hotspots alpha/visibility in HTML5

Posted: Tue Oct 07, 2014 8:35 am
by sigurd.eliassen
Hello,

I'm trying to create a "Toggle hotspot on/off" button to clean up the interface. The Mouse Click --> Toggle element visibility --> _preferred object_ (or toggle element alpha) action works fine on images, rectangles etc, but NOT on hotspots when exporting to HTML5. However, it works fine in Flash. I've also tried to access the text and icon/image chidren of the hotspot. No luck.

Am I doing something wrong, or is this a bug? I've seen examples of this functionality before. I've added an example project with work files + flash and html5 export. I'm working on an internal work project, so I can't post real panoramas on the forum.

Appreciate any help.

Sigurd.

Re: Toggle Hotspots alpha/visibility in HTML5

Posted: Wed Oct 08, 2014 12:42 pm
by Chu
Hi Sigurd,
I would recommend using Set Element Scale, not Toggle Visibility. You would create two buttons which are in the same position, one to show (set scales of hotspots to 1/1) and another to hide (set scale to 0/0). Obviously each button would set its own scale to 0/0 and set scale of the other button' to 1/1.

I create hotspots with unique prefixes, so I can target them with wildcard actions:

Code: Select all

#hs.*
This would target all hotspots that begin with 'hs'

Hope this helps

Re: Toggle Hotspots alpha/visibility in HTML5

Posted: Wed Oct 08, 2014 4:55 pm
by Hopki
Hi,
If addressing Hotspots or their images you need to place either a % or a # in front of the target.
Example:
Mouse Click => Toggle Element Alpha => Alpha: 0.2 => Target: %hs_std

This is because there is many instances of hs_std that will appear in all panoramas.
Also if you have 6 rectangles all with the same ID, rectangle_01 and you want to hide and show all of them you would need, Target: %rectangle_01 otherwise only the first rectangle in the file tree will hide and show.

Regards,
Hopki

Re: Toggle Hotspots alpha/visibility in HTML5

Posted: Mon Oct 13, 2014 7:29 am
by sigurd.eliassen
Thank you both for your response. Hopki: The "#" worked exactly as intended. Thanks!