> ## 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.

# IDStorageFactoryX::CreateQueue

> IDStorageFactoryX::CreateQueue

# IDStorageFactoryX::CreateQueue

创建 DirectStorage 队列对象。

## Syntax

```cpp theme={null}
HRESULT CreateQueue(  
         const DSTORAGE_QUEUE_DESC *desc,  
         REFIID riid,  
         void **ppv  
)  
```

### Parameters

*desc*\
类型：[DSTORAGE\_QUEUE\_DESC](/reference/system/dstorage/structs/dstorage_queue_desc) \*

指定队列属性的描述符。

*riid*\
类型：REFIID

指定 DirectStorage 队列接口，例如 `__uuidof(IDStorageQueueX)`。

*ppv*   \_COM\_Outptr\_\
类型：void \*\*

返回指向所创建对象的指针。

### Return value

类型：HRESULT

标准 HRESULT 错误代码。

## Remarks

DirectStorage 队列会暂存读取请求，直到游戏调用队列的 [Submit](/reference/system/dstorage/interfaces/IDStorageQueueX/methods/idstoragequeuex_submit) 方法。DirectStorage 队列中的所有条目均按其入队顺序完成。

有关详细信息，请参阅 [DirectStorage 概述](/build/console-features/storage/directstorage/directstorage-overview) 中的“IDStorageQueueX”一节。

## Requirements

**头文件：** dstorage\_xs.h

**库：** dstorage\_xs.lib

**受支持的平台：** XBOX Series 主机

## See also

[IDStorageFactoryX](/reference/system/dstorage/interfaces/IDStorageFactoryX/idstoragefactoryx)\
[DStorage](/reference/system/dstorage/dstorage_members)


## Related topics

- [IDStorageQueueX2](/zh-CN/reference/system/dstorage/interfaces/IDStorageQueueX2/idstoragequeuex2.md)
- [IDStorageQueueX](/zh-CN/reference/system/dstorage/interfaces/IDStorageQueueX/idstoragequeuex.md)
- [IDStorageQueueX1](/zh-CN/reference/system/dstorage/interfaces/IDStorageQueueX1/idstoragequeuex1.md)
- [IDStorageQueueX::Close](/zh-CN/reference/system/dstorage/interfaces/IDStorageQueueX/methods/idstoragequeuex_close.md)
- [DSTORAGE_REQUEST_SOURCE_TYPE](/zh-CN/reference/system/dstorage/enums/dstorage_request_source_type.md)
