mvStartEndFrame(3dm) mvStartEndFrame(3dm)
mvSetStartFrame, mvGetStartFrame, mvSetEndFrame, mvGetEndFrame,
mvSetStartTime, mvGetStartTime, mvSetEndTime, mvGetEndTime, - Set/get the
frame or time at which movie playback should start/end
#include <dmedia/moviefile.h>
#include <dmedia/movieplay.h>
void mvSetStartFrame(MVid movieId, MVframe startFrame);
MVframe mvGetStartFrame(MVid movieId);
void mvSetEndFrame(MVid movieId, MVframe endFrame);
MVframe mvGetEndFrame(MVid movieId);
DMstatus mvSetStartTime(MVid movieId, MVtime startTime, MVtimescale timeScale);
MVtime mvGetStartTime(MVid movieId, MVtimescale timeScale);
DMstatus mvSetEndTime(MVid movieId, MVframe endTime, MVtimescale timeScale);
MVframe mvGetEndTime(MVid movieId, MVtimescale timeScale);
mvSetStartFrame(3dm) sets the image frame at which you would like the
Movie Playback Library to start playback for the specified movie. The
default value for this option is zero (i.e., the first image frame of the
movie).
mvSetEndFrame(3dm) chooses the image frame at which you would like the
Movie Playback Library to stop playback for the specified movie. The
default value for this option is the last image frame in the movie. The
last image frame is one less than the duration of the movie divided by
the movie's time scale multiplied by the image rate of the first image
track. Symbolically,
endFrame = movieDuration/movieTimeScale*imageRate - 1
where movieDuration is a value returned from mvGetMovieDuration(3dm)
and imageRate is a value returned from mvGetImageRate(3dm) for
the first image track in the movie. If the movie has no image track,
imageRate defaults to 15 frames per second.
For MV_FORMAT_MPEG1 movies, the default end frame is
MV_FRAME_MAX until the entire duration of the movie has been scanned.
Once the MPEG1 movie has been scanned, the default value for the
Page 1
mvStartEndFrame(3dm) mvStartEndFrame(3dm)
end frame is the last frame in the MPEG1 movie.
mvGetStartFrame(3dm) returns the current frame at
which the Movie Playback Library will start playback for the
specified movie.
mvGetStartFrame(3dm) returns the current frame at
which the Movie Playback Library will stop playback for the
specified movie.
To play only a portion of a movie, use
mvSetStartFrame(3dm) to choose the starting point of
the clip you wish to show, and mvSetEndFrame(3dm) to
choose the end point of the clip.
mvSetStartFramemvSetPlayLoopMode(3dm)).
To loop or swing playback for a portion of a movie, use
mvSetStartFrame(3dm) to choose the starting point of
the clip you wish to show, and mvSetEndFrame(3dm) to
choose the end point of the clip. Then use the loop mode
calls to choose the looping behavior you want.
The start frame value must always be at less than or equal
to the end frame value (see mvSetEndFrame(3dm)).
If the current frame is outside the range you specify with
mvSetStartFrameV_LOOP_CONTINUOUSLY), reset the current
frame to a point within the range and change direction
(MV_LOOP_SWINGING), or stop playback
(MV_LOOP_NONE).
The time-based versions of these routines provide the same
feature set with two small caveats. mvSetStartTime(3dm)
returns DM_FAILURE if the requested start time is less than
zero or greater than or equal to the movie duration.
mvSetEndTime(3dm) returns DM_FAILURE if the requested
end time is less than zero or greater than the duration
of the movie.
mvBindOpenGLWindow(3dm), mvIntro(3dm), mvPlay(3dm),
mvSetCurrentTime(3dm), mvSetPlayLoopMode(3dm), mvStop(3dm).
PPPPaaaaggggeeee 2222 [ Back ]
|