Extracting number of frames in .mov with Showtime

Hi everyone,

I'm having some difficulty extracting some information from stimuli
generated using the ShowTime.mex function.

I'm currently using Showtime to generate a series of quicktime movies.
When I want to display them, I am reading the movies into memory, and
want to use the Psychtoolbox's WaitBlanking ability to control the
timing (as illustrated in the ShowTime documentation.

ie.

for frame = 1:1:nFrames
ShowTime('MovieFrameDisplay',movie,frame);
framesSinceLastWait = SCREEN(window,'WaitBlanking');
end


My issue arises because movie files have a differing number of frames
depending on certain conditions, condition levels etc., so I wish to
extract nFrames after each movie is loaded into the workspace.

I've tried:

nFrames = ShowtimeMovieFrameCount(movie); % as listed in the ShowTime
documentation

However, I get an error that this function is undefined.

I have a hacked up calculation which calculates the nFrames per movie
using the same routine that generated the stimuli files, but I would
love to be able to extract the number of frames upon load time so the
display routine is a bit more generalized.

Thanks for any assistance.

Cheers,

Kevin MacKenzie

------------------------------------------------------------------------
Kevin MacKenzie
mailto: kjmacken@...

Centre for Vision Research
York University, Toronto
------------------------------------------------------------------------
dear kevin

the most likely explanation is that there's a bug in our code, in the
showtime mex file. it is quite possible that the frame counting feature
was never tested. there isn't anyone here who can work on it right now,
but the sources of showtime.mex are available on our download page and
you may be able to debug it. don't assume that this feature ever worked
correctly as i don't recall ever testing it. if you do find the bug,
we'll be happy to fold the fixed version into our standard
distribution.

i realize that "fix it yourself?" is probably not the answer you were
looking for, but i'm trying to be helpful and realistic.

best

denis

On Nov 25, 2004, at 4:37 PM, Kevin MacKenzie wrote:

>
> Hi everyone,
>
> I'm having some difficulty extracting some information from stimuli
> generated using the ShowTime.mex function.
>
> I'm currently using Showtime to generate a series of quicktime movies.
> When I want to display them, I am reading the movies into memory, and
> want to use the Psychtoolbox's WaitBlanking ability to control the
> timing (as illustrated in the ShowTime documentation.
>
> ie.
>
> for frame = 1:1:nFrames
> ShowTime('MovieFrameDisplay',movie,frame);
> framesSinceLastWait = SCREEN(window,'WaitBlanking');
> end
>
>
> My issue arises because movie files have a differing number of frames
> depending on certain conditions, condition levels etc., so I wish to
> extract nFrames after each movie is loaded into the workspace.
>
> I've tried:
>
> nFrames = ShowtimeMovieFrameCount(movie); % as listed in the ShowTime
> documentation
>
> However, I get an error that this function is undefined.
>
> I have a hacked up calculation which calculates the nFrames per movie
> using the same routine that generated the stimuli files, but I would
> love to be able to extract the number of frames upon load time so the
> display routine is a bit more generalized.
>
> Thanks for any assistance.
>
> Cheers,
>
> Kevin MacKenzie
>
> -----------------------------------------------------------------------
> -
> Kevin MacKenzie
> mailto: kjmacken@...
>
> Centre for Vision Research
> York University, Toronto
> -----------------------------------------------------------------------
> -
>
>
>
>
>
> Post your message to: psychtoolbox@yahoogroups.com
> Please indicate OS9, OSX, or WIN version, and include your full name.
> Denis Pelli, David Brainard, and Allen Ingling.
> http://psychtoolbox.org
>
> Yahoo! Groups Links
>
>
>
>
>
>
>