ID3D11InfoQueue::AddMessage Method

Add a debug message to the message queue and send that message to debug output.

Syntax

public:
HRESULT AddMessage(
         D3D11_MESSAGE_CATEGORY Category,
         D3D11_MESSAGE_SEVERITY Severity,
         D3D11_MESSAGE_ID ID,
         LPCSTR pDescription
)  

Parameters

Category
Type: D3D11_MESSAGE_CATEGORY 

[in] Category of a message (see D3D11_MESSAGE_CATEGORY).

Severity
Type: D3D11_MESSAGE_SEVERITY 

[in] Severity of a message (see D3D11_MESSAGE_SEVERITY).

ID
Type: D3D11_MESSAGE_ID 

[in] Unique identifier of a message (see D3D11_MESSAGE_ID).

pDescription
Type: LPCSTR 

[in] User-defined message.

Return value

Type: HRESULT 

This method returns one of the following Direct3D 11 return codes.

Remarks

This method is used by the runtime’s internal mechanisms to add debug messages to the message queue and send them to debug output. For applications to add their own custom messages to the message queue and send them to debug output, call ID3D11InfoQueue::AddApplicationMessage.

Requirements

Header: Declared in d3d11sdklayers.h.

Library: Use d3d11.lib.

See also

ID3D11InfoQueue

ID3D11InfoQueue Members