![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
The class QVideoFrameTexturePool stores textures in slots to ensure they are alive during rhi's rendering rounds. Depending on the rhi backend, 1, 2, or 3 rounds are needed to complete the texture presentaton. The strategy of slots filling is based on QRhi::currentFrameSlot results. More...
#include <qvideoframetexturepool_p.h>
Public Member Functions | |
bool | texturesDirty () const |
The flag indicates whether the textures need update. Whenever a new current frame is set, the flag is turning into true. | |
const QVideoFrame & | currentFrame () const |
void | setCurrentFrame (QVideoFrame frame) |
The method sets the current frame to be converted into textures. The flag texturesDirty becomes true after setting a new frame. | |
QVideoFrameTextures * | updateTextures (QRhi &rhi, QRhiResourceUpdateBatch &rub) |
The method updates textures basing on the current frame. It's recommended to invoke it during rhi's rendering, in other words, between QRhi::beginFrame and QRhi::endFrame. The method resets texturesDirty to false. | |
void | onFrameEndInvoked () |
The method should be invoked after finishing QRhi::endFrame. It propagates the call to the current texture in order to free resources that are not needed anymore. | |
void | clearTextures () |
The method clears all texture slots and sets the dirty flag if the current frame is valid. |
The class QVideoFrameTexturePool stores textures in slots to ensure they are alive during rhi's rendering rounds. Depending on the rhi backend, 1, 2, or 3 rounds are needed to complete the texture presentaton. The strategy of slots filling is based on QRhi::currentFrameSlot results.
Definition at line 36 of file qvideoframetexturepool_p.h.
void QVideoFrameTexturePool::clearTextures | ( | ) |
The method clears all texture slots and sets the dirty flag if the current frame is valid.
Definition at line 38 of file qvideoframetexturepool.cpp.
|
inline |
Definition at line 45 of file qvideoframetexturepool_p.h.
void QVideoFrameTexturePool::onFrameEndInvoked | ( | ) |
The method should be invoked after finishing QRhi::endFrame. It propagates the call to the current texture in order to free resources that are not needed anymore.
Definition at line 31 of file qvideoframetexturepool.cpp.
QT_BEGIN_NAMESPACE void QVideoFrameTexturePool::setCurrentFrame | ( | QVideoFrame | frame | ) |
The method sets the current frame to be converted into textures. The flag texturesDirty becomes true after setting a new frame.
Definition at line 11 of file qvideoframetexturepool.cpp.
|
inline |
The flag indicates whether the textures need update. Whenever a new current frame is set, the flag is turning into true.
Definition at line 43 of file qvideoframetexturepool_p.h.
QVideoFrameTextures * QVideoFrameTexturePool::updateTextures | ( | QRhi & | rhi, |
QRhiResourceUpdateBatch & | rub ) |
The method updates textures basing on the current frame. It's recommended to invoke it during rhi's rendering, in other words, between QRhi::beginFrame and QRhi::endFrame. The method resets texturesDirty to false.
Definition at line 16 of file qvideoframetexturepool.cpp.