Copyright © 2006-2018 MultiMedia Soft

ResetEngine method

Previous pageReturn to chapter overviewNext page

Remarks

 

Resets the multimedia engine: this method can be used in order to enumerate again available sound devices which could have been plugged or unplugged into a USB port; the container application can be notified when a USB device is plugged or unplugged through the DeviceChange event (On Windows XP) or through the events CoreAudioDeviceAdded, CoreAudioDeviceRemoved and CoreAudioDeviceDefaultChange (on Windows Vista and higher versions).

 

Immediately after calling this method it's mandatory to make a call to the ResetControl method, on each of the instanced controls, in order to re-initialize the control(s).

 

By design the CoreAudioDeviceDefaultChange event is only sent to the first instance of the component: due to the fact that all instances of the component share the same instance of the multimedia engine, it's very important that ResetEngine is called only once from this specific instance of the component, as it will affect all of the other instances, and that you call ResetControl from all of the instances or you would experience the ERR_INVALID_PLAYER or ERR_INVALID_RECORDER error on next calls to methods of the control.

 

In case the component should be used in conjunction with the DJ Studio and/or sound editor components, you should call the ResetControl method of these components as well.

 

 

 

Syntax

 

[Visual Basic]

Public Sub ResetEngine (

)


 

[C#]

public void ResetEngine (

);


 

[C++]

public: void ResetEngine (

);