How to stop sounds


Author
Message
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 105K
vonrishi - Thursday, August 24, 2017
This thread helped me in getting started, but I have a slightly different task I want to perform.

The experiment will begin when the participants clicks on the picture. It will be a 6 minute audio file. The participant should have the option to pause the sound and resume by clicking on the same picture/button. I read on another thread that Inquisit doesn't support pausing/resuming video files. Does it apply to audio files too? If not, what is the syntax to pause/resume an audio with a button press?

I would greatly appreciate your input. Thank you.

Yes., the limitation applies to audio files as well. There is no way to pause / resume an audio file, I'm afraid. _Perhaps_ one method you could explore is to embed the audio in a HTML file along with a small player that allows for pausing. You could then have your Inquisit script display that HTML file as a stimulus per the <html> element.

vonrishi
vonrishi
Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)Partner Member (538 reputation)
Group: Forum Members
Posts: 4, Visits: 8
This thread helped me in getting started, but I have a slightly different task I want to perform.

The experiment will begin when the participants clicks on the picture. It will be a 6 minute audio file. The participant should have the option to pause the sound and resume by clicking on the same picture/button. I read on another thread that Inquisit doesn't support pausing/resuming video files. Does it apply to audio files too? If not, what is the syntax to pause/resume an audio with a button press?

I would greatly appreciate your input. Thank you.
Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
Thanks! You are my hero!

I used an mp3 file as video and the program does exactly what it should do!

Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 105K
You don't need to convert to a video format to use the <video> element. The <video> element handles all kinds of compressed / "streaming" formats, including audio-only formats (e.g. MP3).

Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
i cant find a way to edit my posts thus i made a this one:

i am thinking about converting my Wav files to a video and play it with 1x1 pixels in one corner... maybe that would work.

Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
Hi,

1: i am using Windows 10 Home 64 bit
2: i just downloaded the latest Version (Inquisit for Lab 4.0.9.0)
3: i couldnt believe my eyes, videos actually stop. When i use video and sound as bgstim only the video stops but the sound keeps playing.

also tried different sound files, maybe it is a codec problem. i used Audacity to create "WAV (Microsoft) signed 16-bit pcm"



Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 105K
That code looks okay. FWIW, sounds stop / change with a new block for me as they should.

#1: What's your OS (type and version)?
#2: Is your Inquisit installation up to date? If not, please install the latest release?
#3: What happens when you use a <video> element instead of <sound>?

Thanks.

Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
Btw i corrected my mistake in resetintervall but it didnt change anything.
When a new block starts with bgstim both songs are played at the same time... no idea why this happens

Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
This doenst seem to work at all...
I also tried to seperate the three songs but the effect is the same. After the block ended the music keeps playing and doenst stop as it should.
Is there any mistake i am too blind to see?

<block Spielrunde_neutral>
/ bgstim = (Musik)
/ trials = [1 = sequence(instructions_contributions, verhaltenA_no_fear, verhaltenB_no_fear, verhaltenC_no_fear)]
/ onblockend = [values.totalwin_p=(values.firstround_win+values.secondround_win+values.thirdround_win);
    values.totalwin=((values.firstround_win+values.secondround_win+values.thirdround_win)*40);
    values.totalwin_plus=(((values.firstround_win+values.secondround_win+values.thirdround_win)*40)+2400);
]
</block>

<sound Musik>
/ items = ("test1.wav", "test2.wav", "test3.wav")
/ select = noreplace
/ playthrough = false
/ selectionrate = block
/ resetininterval = 0
</sound>

Herby1209
Herby1209
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 11, Visits: 39
Thanks for your answer, i will modify my program and see if this works!

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search