Microsoft DirectX 8.0 (C++) |
Frees a message.
HRESULT FreePMsg( DMUS_PMSG* pPMSG );
If the method succeeds, the return value is S_OK.
If it fails, the method can return one of the following error values:
DMUS_E_CANNOT_FREE |
E_POINTER |
Most messages are released automatically by the performance after they have been processed, and IDirectMusicPerformance8::FreePMsg must not be called on a message that has been sent by using IDirectMusicPerformance8::SendPMsg. However, IDirectMusicPerformance8::FreePMsg can be used within IDirectMusicTool8::ProcessPMsg or IDirectMusicTool8::Flush to free a message that is no longer needed. It must also be used to free notification messages.
The method returns DMUS_E_CANNOT_FREE in the following cases:
If there is a value in the pTool, pGraph, or punkUser members (see DMUS_PMSG), each referenced object is released.
Header: Declared in dmusici.h.