reserve  7QDV_SC 

The reserve command allocates contiguous disk space for the device instance s workspace. Digital-video devices recognize this command.

wsprintf(lpstrCommand, "reserve %s %s %s", lpszDeviceID, lpszReserve,
    lpszFlags);

 

Parameters

lpszDeviceID

Identifier of an MCI device. This identifier or alias is assigned when the device is opened.

lpszReserve

One or more of the following flags:

in path

Specifies the drive and directory path (but not the name) of a temporary file used to hold recorded data. The name of this file is specified by the device. The temporary file is deleted when the device is closed. If this flag is omitted, the device specifies the location of the disk space.

size duration

Specifies the approximate amount of disk space to reserve in the workspace. The duration value is specified in the current time format. The device bases its estimate of the required disk space on the following parameters: the requested time, the file format, the video and audio compression algorithm, and the compression quality values in effect. If setvideo2CUPZV.  record  is  off , then space is reserved only for audio. If setaudio2CA1ZZ.  record  is  off , then space is reserved only for video. If both are  off , or if duration is zero, then no space is reserved and any existing reserved space is deallocated. If this flag is omitted, the device will use a device-defined default.

 

lpszFlags

Can be  wait ,  notify ,  test , or a combination of these. For more information about these flags, see The Wait, Notify, and Test Flags4FW.04J.

 

Return Values

Returns zero if successful or an error otherwise.

Remarks

If needed, subsequent recordO3IFU or saveUDLDV7 commands use the space reserved by this command. If the workspace contains unsaved data, the data is lost. Some devices do not require reserve and ignore it. If disk space is not reserved prior to recording, the record command performs an implied reserve with device-specific default flags. Use an explicit reserve command if you want better control of when the delay for disk allocation occurs, control of how much space is allocated, and control of where the disk space is allocated. Your application can change the amount and location of previously reserved disk space with subsequent reserve commands. Any allocated and still unused disk space is not deallocated until any recorded data is saved, or until the device instance is closed.

See Also

record, save, setaudio, setvideo