Play/Stop Media - a feature request

Q&A about the latest versions
Post Reply
HaraldJ
Posts: 156
Joined: Wed Oct 10, 2012 2:05 pm
Location: Surrey, United Kingdom
Contact:

At the moment, there seems to be no "Play/Stop Media" option. There is an option for "Play/Pause Media", but that doesn't "rewind" media to the beginning.

Some sound events last a bit longer (like starting an aircraft's jet engine), and some people are at work, in an office, when they click on a sound button in a panorama. If the button is a Play/Pause Media button, then they can at least pause the sound, but the sound will continue where it was stopped when the button is pressed again.

It could be much nicer and cleaner if there would be a real "Play/Stop Media" action. Is there a chance for it in a future version of Pano2VR?

Thanks!

Harald
Harald Joergens
Harald Joergens Photography
Nutfield, Surrey, United Kingdom
User avatar
Hopki
Gnome
Posts: 13029
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi Harald,
It just as easy to stack two buttons on top of each other with hide and show actions.
The norm is to toggle between the play and pause not play and stop but that said I have added this as a feature request.
Regards,
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
HaraldJ
Posts: 156
Joined: Wed Oct 10, 2012 2:05 pm
Location: Surrey, United Kingdom
Contact:

Hi Hopki,

Thanks for your response. I know it can be done this way in the controller, but if it would be an option amongst the media actions, I could use it together with a hotspot.

In the engine room of this steam narrowboat there are several sound hotspots, some of them start longer and loud sounds. If the hotspots could work as start/stop, that would be great!

Would is be possible to stack two sound hotspots together as a component for the V5 skin editor? That would be a short term solution!

Thanks!

Harald
Harald Joergens
Harald Joergens Photography
Nutfield, Surrey, United Kingdom
User avatar
Hopki
Gnome
Posts: 13029
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi Harald,
I was going to suggest make a quick button and highlight all the elements to make a component but I could not remember which version you were running, 4 or 5.
The good thing about making it a component is if you decide to use different button images in another project all you would need to do is change the graphics once dragged out into the skin canvas.

Also I would hide the thumbnail slider on open but then have them show on loaded. That way you don't see all the thumbnail loading, visually tidies up the appearance.

Regards,
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
HaraldJ
Posts: 156
Joined: Wed Oct 10, 2012 2:05 pm
Location: Surrey, United Kingdom
Contact:

Hi Hopki,

Thanks for the suggestion about the filmstrip, I've made that change to another project with loads of filmstrip images, and it looks much better.

Back to the sound start/stop:

If I had one controller button to switch the sound, then I could, as you suggested, use two buttons and toggle their visibility to make them look and behave like a start- and stop button.

But I have various sound events linked to specific locations, so I'm using hotspots. I have a "sound-hotspot" that I assign to a location, and I give it a hotspot proxy ID - "s1".
To actually play the sound I use a marker. This marker is assigned to hotspot proxy ID s1, and has n an action "On mouse click play media X".
All that works very well. And I guess I could have a two hotspots similar to the controller buttons mentioned, like a "sound-start-hotspot" and a "sound-stop-hotspot".

But I would still have only one hotspot proxy ID. How would I stop the sound in this scenario?

Thanks!

Harald
Harald Joergens
Harald Joergens Photography
Nutfield, Surrey, United Kingdom
User avatar
Hopki
Gnome
Posts: 13029
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi Harald,
This is simple enough and does not need to use hotspot proxy ID's.

Example:
Add your sound in the sound mode and set loop to -1.
Give the sound an ID, in this example I have used: snd01

Change to the point hotspot mode and add your point hotspot where you placed the sound spot.
Give it a skin ID that will be unique to a hotspot template, in this example: FX01.
Leave the hotspot to Link Target Type: URL.
Now in the Target text field enter the ID of the sound that will play at this location, in my example I have snd01 and snd02 for the two sounds. As this is the first enter snd01.

Now download the attached and skin and copy and paste the FX01 hotspot template to you skin.

How this works is the hotspot with have a speaker logo. On mouse over this changes to a play button and on click changes to a stop button.
The on click also will play the media file with the ID taken from the hotspot target text box. So if snd01 is in the target text box the sound with the ID snd01 will play.
The stop button also has a place holder to link to the target text box so it can stop the playing sound.

There is also a large rectangle which is a child of the stop button, ID snd_active. This is an active area, example when you click the play button and see the stop button, the sound plays. However to stop the viewer clicking another sound and then having both play at the same time this active area acts as a safeguard. With the sound playing if the mouse moves out of the rectangles area the sound stops resetting the hotspot to show the play button agin.
You can of course make this rectangle as large or as small as you require.

To play a second sound, as above add the sound in sound mode, give it the ID, in this example snd02 and set loop to -1.
In the hotspot mode add the hotspot in the same area as the sound and give it the Skin-ID FX01 so it uses the hotspot template in the skin.
In the hotspot target text field add the sounds ID, snd02.

Thats it just publish out.
When clicked the second sound will play/stop and when the mouse is moved away the sound will stop, you can then click the next sound.
Regards
Hopki
Attachments
snd.ggsk.zip
(3.94 KiB) Downloaded 186 times
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
Hopki
Gnome
Posts: 13029
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

In fact, here is my Pano2VR 5 test project with sound files.
Regards,
Hopki
Attachments
project.zip
(2.26 MiB) Downloaded 213 times
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
HaraldJ
Posts: 156
Joined: Wed Oct 10, 2012 2:05 pm
Location: Surrey, United Kingdom
Contact:

Hi Hopki,

That looks very good indeed, thank you very much! I'll try to add that to various projects.

There is one (small) issue - the hotspot doesn't know when the media has finished playing. Once it has started playing, the "Stop" button is active until it's either clicked, or the cursor moved away. For short time events that are likely to be clicked more than once this can be a bit confusing.

A timer could be added to switch the "stop" button to "start" again, but then the duration of the media would have to be set as well. I guess there is no "media has finished playing" event that could be used to trigger the hotspot?

Best regards

Harald
Harald Joergens
Harald Joergens Photography
Nutfield, Surrey, United Kingdom
ChristofM
Posts: 9
Joined: Mon Nov 30, 2015 4:46 pm
Contact:

Hi,

I have tested this feature. Works fine with PC or Laptop on various browsers. But no sound on mobile devices (iOS & Android).
What do I need to change?

BR, Christof
User avatar
Hopki
Gnome
Posts: 13029
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi Christof,
That would be correct as touch screen devices don't have a mouse enter or leave.
The project uses mouse enter to show the play button so a touch screen divide can not play the sound.
You would have to just have the play button visible from the start and avoid using mouse enter and leave.
Replace the rectangle "cover" with a stop button graphic, but the attached skin works with touch screens.
Regards,
Hopki
Attachments
touch.ggsk
(1.68 KiB) Downloaded 176 times
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
Post Reply