Skip to main content

AppCaptureMetadataStartStringState

Add a metadata state with a string value to your app capture.

Syntax

Parameters

name   _In_z_
Type: char*
Name of the state being added to the app capture timeline. value   _In_z_
Type: char*
Value of the state being added to the timeline. Must be a string. priority   _In_
Type: XAppCaptureMetadataPriority
Priority of the metadata. Used to determine what is saved in the case that storage limiters are exceeded. A member of the XAppCaptureMetaDataPriority enumeration.

Return value

Type: HRESULT Function result.

Remarks

This function isn’t safe to call on a time-sensitive thread. For more information, see Time-sensitive threads.
The system associates a metadata state with the window of time between when the state is started and when it’s value is changed or the state is stopped with a call to XAppCaptureMetaDataStopAllStates. This metadata is used to identify events during live streams, and captured playback to categorize and search content. To store a string value that applies to an instantaneous moment in time, use XAppCaptureMetadataAddStringEvent.
Metadata may be uploaded to XBOX Live and/or saved to .mp4 files, screenshots or used during broadcast, as such, private user info should never be logged with meta data.

Requirements

Header: XAppCapture.h Library: xgameruntime.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consoles

Conceptual documentation

See also

GameDVR Overview
XAppCapture Members
Last modified on August 20, 2026