Home > Software engineering >  MMControl1 interval play AVI
MMControl1 interval play AVI

Time:10-01

Is there anyone interval play AVI reference code? Thank you first!

CodePudding user response:

The seek
The seek command moves to The specified position and stops, CD audio, digital video, MIDI sequencer, VCR, videodisc, and waveform - audio devices recognize this command.

Wsprintf (lpstrCommand, seek % s % s "% s", lpszDeviceID, lpszSeekFlags,
LpszFlags);

The Parameters
LpszDeviceID
Identifier of the an MCI device. This Identifier or alias is assigned when the device is the opened.
LpszSeekFlags
Flag for moving to a specified position. The following table lists The device types that recognize The seek The command and The flags, informs by each type: cdaudio to end
To the position to start
Digitalvideo to end
To the position to start
Sequencer to end
To the position to start
At the time a VCR
Mark mark_num
Reverse the to end
To the position
To start
Videodisc reverse
To end the to position
To start
Waveaudio to end
To the position to start


The following table lists The flags that can be specified in The lpszSeekFlags parameter and their meanings: at The time are The when The device should begin performing this command, or, if The device has had been cued, The when The cued command begins. For more information, see The cue command.
Mark mark_num Seeks to the relative mark indicated by mark_num, which must be a positive integer value. The Marks are signals written to the VCR tape using the mark command and motorcycle, informs the for high - speed searching.
Reverse are that the seek direction on VCRs and CAV videodiscs is backward. This flag is invalid if the "to" flag is specified, the For VCRs, This flag must be 2 have the "mark" flag.
Seeks to end the to the end of the content.
To the position Specifies the position to stop the seek. For cdaudio devices, MCI returns an out - of - the range error if the specified position is greater than the length of the disc.
To start Seeks to the start of the content.



LpszFlags
Can be "wait" and "notify", or both, For digital video and VCR devices, "test" Can also be specified. For more information about these flags, see The wait, notify, and test flags.
The Return Values
Returns zero if successful, or an error otherwise.

Few
Before issuing any commands that use the position values, you should set the desired time format by using the set command.

Digital - video devices support two seek modes, which you can change by using the set command. The "seek exactly on" mode causes the seek the command to move to the specified frame. The "seek exactly off" mode causes the seek the command to move to the closest key frame the prior to the specified frame.

If a CD audio device is playing the when the seek command is issued, the playback is stopped. When the seek command is issued with a videodisc device, the device searches using fast forward or fast reverse with video and audio off.

When the seek command is issued with a waveform - audio device, the behaviors depends on the sample size. If the sample size is 16 bits or greater, the seek moves to the beginning of the on the sample the When a specified position does not coincide with the start of a sample.

The following command seeks to The start of The media file associated with The "mysound" device:

The seek mysound to start

QuickInfo
Windows NT: Requires version 3.1 or later.
Windows: Requires Windows 95 or later.
Windows CE: Unsupported.

See Also
MCI Overview, MCI Command Strings, cue, mark, set


  • Related