The IDirectMusicPerformance::CloseDown method closes down the performance object. An application that created the performance object and called IDirectMusicPerformance::Init on it must call CloseDown before the performance is released.
HRESULT CloseDown();
None.
The method returns S_OK.
Failure to call CloseDown may cause memory leaks or crashes.
CloseDown handles the release of the IDirectMusic interface in the case where the application passed NULL, or a pointer to NULL, to IDirectMusicPerformance::Init, causing a DirectMusic object to be created by that call. In other cases, where the application explicitly created the DirectMusic object and passed the pointer to Init, the application is responsible for releasing the IDirectMusic interface.
CloseDown also releases any downloaded instruments that have not been unloaded.
Windows NT/2000: Requires Windows 2000.
Windows 95/98: Requires Windows 95 or later. Available as a redistributable for Windows 95.
Header: Declared in dmusici.h.