FrameGraphNode used to wait for a fence in the graphics command stream to become signaled. 更多 …
New in version 5.13.
def
handle
()
def
handleType
()
def
setHandle
(handle)
def
setHandleType
(type)
def
setTimeout
(timeout)
def
setWaitOnCPU
(waitOnCPU)
def
timeout
()
def
waitOnCPU
()
def
handleChanged
(handle)
def
handleTypeChanged
(handleType)
def
timeoutChanged
(timeoutChanged)
def
waitOnCPUChanged
(waitOnCPU)
Fence allow to synchronosize GPU and CPU workloads. GPU commands usually are non-blocking. When issued, commands are inserted in command buffers which will be read at a later time by the GPU. In some cases, you want to continue processing or issue specific command only when you are sure a command has been executed by the hardware. Fences are a way to do so. This is especially important when using 3rd party engines with Qt3D, Qt3D should only access shared resources when we know the other engine command are done modifying the resource.
QWaitFenceis a FrameGraph node that will force to wait for it to become signaled before subsequent commands are inserted into the command stream. It can then be used in conjunction withQSetFenceand contains properties to configure how long it should wait and whether it should block on the CPU side.注意
Qt 3D uploads GPU resources (Texture, Shaders, Buffers) before issuing draw calls.
PySide2.Qt3DRender.Qt3DRender.
QWaitFence
(
[
parent=None
]
)
¶
parent
–
QNode
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
HandleType
¶
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
handle
(
)
¶
object
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
handleChanged
(
handle
)
¶
handle – object
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
handleType
(
)
¶
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
handleTypeChanged
(
handleType
)
¶
handleType
–
HandleType
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
setHandleType
(
type
)
¶
type
–
HandleType
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
setTimeout
(
timeout
)
¶
timeout
–
quint64
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
setWaitOnCPU
(
waitOnCPU
)
¶
waitOnCPU
–
bool
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
timeout
(
)
¶
quint64
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
timeoutChanged
(
timeoutChanged
)
¶
timeoutChanged
–
quint64
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
waitOnCPU
(
)
¶
bool
另请参阅
PySide2.Qt3DRender.Qt3DRender.QWaitFence.
waitOnCPUChanged
(
waitOnCPU
)
¶
waitOnCPU
–
bool