Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently December 23rd, 2024, 7:59 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Mute sequential waves on a timeline (on a specific channel)
PostPosted: March 11th, 2009, 3:09 pm 
Offline

Joined: March 4th, 2008, 6:49 pm
Posts: 11
Hello everyone.

I have several audio files on a timeline, all playing on sound channel 2.

A button action "Change Volume to Zero" works great when I apply it to "All Wave Sounds". --Essentially this creates a "Mute" button which works for the duration of the timeline (and the page).

But when I apply this action to Channel 2, or any specific channel (instead of the whole wave output), the button only mutes the FIRST wave in the timeline sequence. --The next waves will begin playing at default volumes when the timeline reaches their positions.

It is important for my publication to have a mute button for a specific sequence of narration tracks on a timeline, all set to the same audio channel.

Can anyone think of a way to make this work without muting the entire wave output?

--Many thanks,
--Mark

_________________
Development Platform Info:
License A-Opus Pro 6/WinXP SP2 Pentium D 3.39GHz 2GB
License B-Opus Creator 6/WinXP SP2 Core2 Duo 2.4GHz 2GB


Top
 Profile  
 
 Post subject:
PostPosted: March 12th, 2009, 1:58 am 
Offline
Godlike
Godlike

Joined: November 12th, 2005, 1:56 am
Posts: 1474
Location: SFBay Area
Opus: OpusPro v9.0x, & Evol.
OS: Vista32
System: Core 2 duo 2Ghz, RAM 3GB, Nvidia Go 7700 - laptop
Mark,

Quote:
the button only mutes the FIRST wave in the timeline sequence. --The next waves will begin playing at default volumes

I would bet that if you press the Button before the First .wav plays, the soundfile would still play at the Initial Volume you specified in the Timeline action Play Sound.

One solution could be this.
- set up a Page var or Pub var for Chan5volume
- in a Script Object, create a function. Name it as you like.
Code:
function PlayAudioFile( whichfile)
{
PlaySound( whichfile, false, 1, Chan5volume,0,-1, 0, 0,true, 5, true )
//modify parameters as needed
}


When you want to 'mute', simply change the value of the variable Chan5volume ( 0 to 100 )
[Edit:] I should clarify. Once the soundfile is playing, this does not change the volume. Use other methods to do that. The variable is a way to set or change what the initial, starting volume is.

-- In the Timeline, instead of an action to PlaySound, put in a Script event in the timeline. It just needs one line:
Code:
PlayAudioFile( wave_num01 )
//wave_num01  can be a variable with full path to the audio file, or a string for that path.



Others here will likely come up with some simpler, more direct means to do this.

_________________
_good things come to those who wait(0)_


Top
 Profile  
 
 Post subject:
PostPosted: March 12th, 2009, 4:03 am 
Offline

Joined: March 4th, 2008, 6:49 pm
Posts: 11
No, that seems like a pretty simple and direct solution. If they give me time, I will try that method as a test either tomorrow or Friday and report back to the forum how well it works.

Thank you for your time and brain power!

--Mark

_________________
Development Platform Info:
License A-Opus Pro 6/WinXP SP2 Pentium D 3.39GHz 2GB
License B-Opus Creator 6/WinXP SP2 Core2 Duo 2.4GHz 2GB


Top
 Profile  
 
 Post subject: Qualified Success
PostPosted: March 17th, 2009, 9:54 pm 
Offline

Joined: March 4th, 2008, 6:49 pm
Posts: 11
After some fiddling I've found that you can work the problem this way. Its a good solution if you have only a couple pages or timelines.

For large publications it is probably too much trouble, especially if you have multiple developers and need to "guess" what they are going to name their objects and resources.

So consider what kind of publication you're going to be developing. It is generally better to start and stop timelines than try to mute multimedia events on them on the fly.

--Mark

_________________
Development Platform Info:
License A-Opus Pro 6/WinXP SP2 Pentium D 3.39GHz 2GB
License B-Opus Creator 6/WinXP SP2 Core2 Duo 2.4GHz 2GB


Top
 Profile  
 
 Post subject:
PostPosted: March 18th, 2009, 8:31 am 
Offline
Godlike
Godlike

Joined: November 12th, 2005, 1:56 am
Posts: 1474
Location: SFBay Area
Opus: OpusPro v9.0x, & Evol.
OS: Vista32
System: Core 2 duo 2Ghz, RAM 3GB, Nvidia Go 7700 - laptop
I probably do not understand your devlp project, but you might look into these... general techniques from the Random-Idea-Generator:

For one, you could use a Publication var as a kind of 'token' concept. Change the value for who has 'stage'. You have at least a couple options here. 'Variable changed' is a trigger mechanism in Opus. Otherwise, search the forum for 'ticker'... as that is a way also to set up a monitoring and control script.

Custom Actions and Custom Triggers may be useful. ?

Quote:
For large publications it is probably too much trouble, especially if you have multiple developers and need to "guess" what they are going to name their objects and resources.

GetParent(), GetDescendant(), GetChild()... and GetType(), GetName() are useful in combination and can be used to locate and manipulate an unknown object. Probably requires a For Loop.

Also I think, but am not sure that in a MultiFrame I can have for example multiple objects named Video_22 and as long as each instance is in its own Frame within the Frameset (a MF)... they should not cause conflict. And only one is active at a time. (again, some caution here... would need to prove that is correct and generally should avoid duplicated naming)

In OpusScript, OpenSound() command can use an 'alias' name for the soundfile if that helps.

Anyway, good cheer.

_________________
_good things come to those who wait(0)_


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 46 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group