> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XAppCaptureCloseScreenshotStream

> XAppCaptureCloseScreenshotStream

# XAppCaptureCloseScreenshotStream

Closes a screenshot stream.

## Syntax

```cpp theme={null}
HRESULT XAppCaptureCloseScreenshotStream(  
         XAppCaptureScreenshotStreamHandle handle  
)  
```

### Parameters

*handle*   \_In\_\
Type: XAppCaptureScreenshotStreamHandle

Handle of the screenshot stream to close.

### Return value

Type: HRESULT

Function result.

## Remarks

<Note>This function isn't safe to call on a time-sensitive thread. For more information, see [Time-sensitive threads](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/console-dev/overviews/threads/time-sensitive-threads).</Note>

Use this function to close the screenshot stream opened by [XAppCaptureOpenScreenShotStream](/reference/system/xappcapture/functions/xappcaptureopenscreenshotstream). Failure to close an opened screenshot stream will result in a memory leak. The handle required to close the stream is returned from the [XAppCaptureOpenScreenShotStream](/reference/system/xappcapture/functions/xappcaptureopenscreenshotstream) that originally opened the stream.

## Requirements

**Header:** XAppCapture.h

**Library:** xgameruntime.lib

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## Conceptual documentation

* [Time-sensitive threads](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/console-dev/overviews/threads/time-sensitive-threads)

## See also

[GameDVR Overview](/build/console-features/game-dvr/gamedvr-broadcast)\
[XAppCapture Members](/reference/system/xappcapture/xappcapture_members)\
[XAppCaptureOpenScreenShotStream](/reference/system/xappcapture/functions/xappcaptureopenscreenshotstream)\
[XAppCaptureReadScreenShotStream](/reference/system/xappcapture/functions/xappcapturereadscreenshotstream)\
[XAppCaptureTakeScreenshot](/reference/system/xappcapture/functions/xappcapturetakescreenshot)


## Related topics

- [XAppCaptureOpenScreenshotStream](/reference/system/xappcapture/functions/xappcaptureopenscreenshotstream.md)
- [XAppCaptureReadScreenshotStream](/reference/system/xappcapture/functions/xappcapturereadscreenshotstream.md)
- [XAppCaptureScreenshotStream](/reference/system/xappcapture/structs/xappcapturescreenshotstream.md)
- [XAppCaptureTakeScreenshot](/reference/system/xappcapture/functions/xappcapturetakescreenshot.md)
- [XAppCapture](/reference/system/xappcapture/xappcapture_members.md)
