ID3DUserDefinedAnnotation::BeginEvent Method

Marks the beginning of a section of event code.

Syntax

public:
INT BeginEvent(
         LPCWSTR Name
)  

Parameters

Name
Type: LPCWSTR 

[in]

A NULL-terminated UNICODE string that contains the name of the event. The name is not relevant to the operating system. You can choose a name that is meaningful when the calling application is running under the Microsoft Direct3D profiling tool. A NULL pointer produces undefined results.

Return value

Type: INT 

Returns the number of previous calls to BeginEvent that have not yet been finalized by calls to ID3DUserDefinedAnnotation::EndEvent.

Remarks

You call the EndEvent method to mark the end of the section of event code.

A user can visualize the event in PIX. All calls to PixBeginEvent and PixEndEvent must be within a single command list; you cannot call PixBeginEvent in one command list and then call PixEndEvent in another command list.

Requirements

Header: Declared in d3d11_x.h (d3d11_1.h on other Windows platforms).

Library: Use d3d11_x.lib (d3d11.lib on other Windows platforms).

See also

ID3DUserDefinedAnnotation Members

ID3DUserDefinedAnnotation

ID3D11UserDefinedAnnotationX