QRhiReadbackDescription Class

읽기백(GPU 전용 메모리에서 텍스처 콘텐츠를 다시 읽어오는) 작업에 대해 설명합니다. 더 보기...

헤더: #include <rhi/qrhi.h>
CMake: find_package(Qt6 REQUIRED COMPONENTS Gui)
target_link_libraries(mytarget PRIVATE Qt6::GuiPrivate)
qmake: QT += gui-private
이후: Qt 6.6

공용 함수

QRhiReadbackDescription()
QRhiReadbackDescription(QRhiTexture *texture)
int layer() const
int level() const
void setLayer(int layer)
void setLevel(int level)
void setTexture(QRhiTexture *tex)
QRhiTexture *texture() const

자세한 설명

읽기 작업의 소스는 QRhiTexture 또는 현재 타겟팅된 QRhiSwapChain 의 현재 백버퍼입니다. texture ()가 설정되지 않은 경우, 스왑체인이 사용됩니다. 그렇지 않으면 지정된 QRhiTexture 이 소스로 처리됩니다.

참고: 읽기백에 사용되는 텍스처는 QRhiTexture::UsedAsTransferSource 로 생성해야 합니다.

참고: 읽기백에 사용되는 스왑체인은 QRhiSwapChain::UsedAsTransferSource 로 생성해야 합니다.

layer() 및 level()는 소스가 QRhiTexture 인 경우에만 적용됩니다.

참고: 멀티샘플 텍스처는 리드백할 수 없습니다. 그러나 멀티샘플 스왑체인 버퍼에 대해서는 읽기백이 지원됩니다.

참고: 이 함수는 호환성이 제한적으로 보장되는 RHI API이며, 자세한 내용은 QRhi 을 참조하세요.

멤버 함수 문서

[constexpr noexcept] QRhiReadbackDescription::QRhiReadbackDescription()

빈 텍스처 읽기백 설명을 생성합니다.

참고: 소스 텍스처는 기본적으로 null로 설정되어 있지만 여전히 유효한 읽기백입니다. 현재 스왑체인의 백버퍼를 읽어들이도록 지정합니다. (현재란 QRhiResourceUpdateBatchtexture readback 을 커밋할 당시 프레임의 타겟 스왑체인을 의미합니다.)

QRhiReadbackDescription::QRhiReadbackDescription(QRhiTexture *texture)

texture 의 레이어 0의 레벨 0을 읽어오도록 지정하는 텍스처 읽기백 설명을 생성합니다.

참고: texture 는 null일 수도 있으며, 이 경우 이 생성자는 인수가 없는 변형과 동일합니다.

int QRhiReadbackDescription::layer() const

현재 설정된 배열 레이어(큐브맵 면, 배열 인덱스)를 반환합니다. 기본값은 0입니다.

읽기 소스가 QRhiTexture 인 경우에만 적용됩니다.

setLayer()도 참조하세요 .

int QRhiReadbackDescription::level() const

현재 설정된 밉 레벨을 반환합니다. 기본값은 0입니다.

읽기백의 소스가 QRhiTexture 인 경우에만 적용됩니다.

setLevel()도 참조하세요 .

void QRhiReadbackDescription::setLayer(int layer)

layer 배열을 다시 읽도록 설정합니다.

layer()도 참조하세요 .

void QRhiReadbackDescription::setLevel(int level)

level 밉을 다시 읽도록 설정합니다.

level()도 참조하세요 .

void QRhiReadbackDescription::setTexture(QRhiTexture *tex)

tex 텍스처를 읽기 작업의 소스로 설정합니다.

nullptr 설정도 유효하며, 이 경우 현재 스왑체인의 현재 백버퍼가 사용됩니다. (단, 스왑체인 기반이 아닌 프레임에서는 읽기백을 실행할 수 없습니다.)

참고: 멀티샘플 텍스처는 리드백할 수 없습니다. 그러나 멀티샘플 스왑체인 버퍼에는 읽기백이 지원됩니다.

참고: 읽기백에 사용되는 텍스처는 QRhiTexture::UsedAsTransferSource 로 생성해야 합니다.

참고: 읽기백에 사용되는 스왑체인은 QRhiSwapChain::UsedAsTransferSource 로 생성해야 합니다.

texture()도 참조하세요 .

QRhiTexture *QRhiReadbackDescription::texture() const

다시 읽은 QRhiTexture 을 반환합니다. 현재 스왑체인의 백버퍼가 대신 사용됨을 나타내는 nullptr 로 설정할 수 있습니다.

setTexture()도 참조하세요 .

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.