ID3D11UserDefinedAnnotationX::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 the ID3D11UserDefinedAnnotationX::EndEvent method.

The return value is –1 if the calling application is not running under a Microsoft Direct3D profiling tool.

Remarks

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

A user can visualize the event when the calling application is running under an enabled Microsoft Direct3D profiling tool.

BeginEvent has no effect if the calling application is not running under an enabled Microsoft Direct3D profiling tool.

Requirements

Header: Declared in d3d11_x.h.

Library: Use d3d11_x.lib.

See also

Reference

ID3D11UserDefinedAnnotationX

ID3DUserDefinedAnnotation

ID3D11UserDefinedAnnotationX Interface

ID3D11UserDefinedAnnotationX Members