Opening the Device

The videodisc player is a dynamic single context device and therefore is serially shareable. When you open the videodisc player, it takes about 60 seconds for the disc to load and spin up to a playing position. Specifying a notify flag on the open request allows your application window procedure to remain available to process PM messages.

open videodisc alias video1 notify shareable

If you set the shareable flag, you should not start a playback operation until the system posts the asynchronous MM_MCIPASSDEVICE message with an event of MCI_GAINING_USE to your application.

When the system posts the asynchronous MM_MCINOTIFY message with a return code of MCI_NOTIFY_SUCCESSFUL message to your application, this indicates a device context is created. Although you may not have received the MCI_GAINING_USE event in a MM_MCIPASSDEVICE message, you can still make inquiries about the device and the media. The status, capability, info, and close commands can be sent to an inactive device context.

You may want to ensure that the disc in the player is not changed by the user. Some devices allow you to disable the manual eject. Other devices allow you to check the label on the disc:

info video1 label wait

Specify the wait flag with commands that return information. A string for the label is returned in the user-supplied buffer specified with mciSendString.

Use the status command to determine the current state of the videodisc player: