Present image AFTER sound file ends


Author
Message
rkrosen
rkrosen
Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)
Group: Forum Members
Posts: 2, Visits: 2
Hello. I am presenting trials in which a sound file will automatically play, and then two subsequent images (target and mask) will be presented sequentially. However, I do not want the images to appear until after the sound file ends. The problem is that there are multiple possible sound files that will be randomly chosen, and they are of varying lengths. Is it possible to present the images only after the sound file ends without specifying an exact time? Here is my code for the stimulus time with question marks where I would otherwise indicate a time. I'd like the target to be presented once sound file (PrimeA) ends and then the mask to be presented 200ms after that.

<trial primeA>
/ validresponse = ("E", "I")
/ correctresponse = ("I")
/ stimulustimes = [0=primeA; ??=target; ??=mask]
/ontrialend = [values.primestim = sound.primea.currentitemnumber; values.targetstim = picture.target.currentitemnumber]
</trial>

P.S. If this is not possible, I will just specify the timing of presentation based on the longest sound clip duration, but I wanted to see if I could avoid that.
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: 104K
The easiest way to do this is to have your sound displayed by a separate trial. Once that trial is over, run the trial presenting your target and mask, i.e. something along the lines of

<sound PrimeA>
/ items = ("Long.wav", "Short.wav")
/ playthrough = true
</sound>

<trial primeAsoundtrial>
/ stimulusframes = [1=PrimeA]
/ validresponse = (0)
/ trialduration = 20
/ branch = [trial.primeA]

/ recorddata = false
</trial>

<trial primeA>
/ validresponse = ("E", "I")
/ correctresponse = ("I")
/ stimulustimes = [0=target; 100=mask]
/ontrialend = [values.primestim = sound.primea.currentitemnumber; values.targetstim = picture.target.currentitemnumber]
</trial>


rkrosen
rkrosen
Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)Associate Member (247 reputation)
Group: Forum Members
Posts: 2, Visits: 2
Thanks!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search