Loading...
Searching...
No Matches
Gfx::SpoutNode Struct Referencefinal
Inheritance diagram for Gfx::SpoutNode:
score::gfx::OutputNode score::gfx::Node

Public Member Functions

 SpoutNode (const SharedOutputSettings &set)
 
void startRendering () override
 
bool registerDXSender (HANDLE handle)
 
void startRenderingOpenGL ()
 
void startRenderingD3D11 ()
 
void startRenderingD3D12 ()
 
void onRendererChange () override
 
bool canRender () const override
 
void render () override
 
void renderOpenGL (QRhi *rhi)
 
void renderD3D11 (QRhi *rhi)
 
void renderD3D12 (QRhi *rhi)
 
void stopRendering () override
 
void setRenderer (std::shared_ptr< score::gfx::RenderList > r) override
 
score::gfx::RenderList * renderer () const override
 
void createOutput (score::gfx::OutputConfiguration conf) override
 
void createOutputOpenGL ()
 
void createOutputD3D11 ()
 
void createOutputD3D12 ()
 
void destroyOutput () override
 
std::shared_ptr< score::gfx::RenderState > renderState () const override
 
score::gfx::OutputNodeRenderer * createRenderer (score::gfx::RenderList &r) const noexcept override
 Create a renderer in a given context for this node.
 
Configuration configuration () const noexcept override
 
- Public Member Functions inherited from score::gfx::OutputNode
virtual void setVSyncCallback (std::function< void()>)
 Set a callback to drive rendering when there is a single output.
 
virtual void updateGraphicsAPI (GraphicsApi)
 
virtual TextureRenderTarget currentRenderTarget () const noexcept
 The output's current backing render target + render-pass descriptor, as the upstream nodes should render into it NOW.
 
GpuResourceRegistry & acquireRegistry ()
 Persistent GPU resource registry for this output.
 
GpuResourceRegistry * registry () const noexcept
 Non-owning accessor. Returns null if no registry has been acquired yet (e.g. queried before the first RenderList::init).
 
void releaseRegistry ()
 Tear down the registry's QRhi resources directly. Idempotent.
 
virtual bool deviceLost () const noexcept
 True once the output's graphics device was reported lost.
 
void handleDeviceLost (const char *output) noexcept
 Mark the device as lost; logs once per device.
 
const std::shared_ptr< PointerState > & pointerState () const noexcept
 The mouse and touch points over this output, decoded from the window's events into vertexshaderart's slots (PointerState). The window device publishes them as its touch/points address; nothing reads them here.
 
- Public Member Functions inherited from score::gfx::Node
 Node (const Node &)=delete
 
 Node (Node &&)=delete
 
Node & operator= (const Node &)=delete
 
Node & operator= (Node &&)=delete
 
virtual void renderedNodesChanged ()
 Whenever render nodes are added / removed.
 
virtual void process (Message &&msg)
 Process a message from the execution engine.
 
virtual void update ()
 
void materialChange () noexcept
 Used to notify a material change from the model to the renderers.
 
bool hasMaterialChanged (int64_t &renderer) const noexcept
 
void renderTargetChange () noexcept
 Used to notify a render target (texture inlet) change from the model to the renderers.
 
bool hasRenderTargetChanged (int64_t &renderer) const noexcept
 
bool hasExplicitRenderTargetSize (int32_t port) const noexcept
 Whether a given port has a user-specified render target size.
 
bool hasExplicitRenderTargetSpecs (int32_t port) const noexcept
 Whether the user set a size or a format on a texture inlet.
 
QSize resolveRenderTargetSize (int32_t port, RenderList &renderer) const noexcept
 
RenderTargetSpecs resolveRenderTargetSpecs (int32_t port, RenderList &renderer) const noexcept
 
virtual void adjustRenderTargetSpecs (int32_t port, RenderTargetSpecs &spec) const noexcept
 
std::optional< RenderTargetSpecs > firstInputRenderTargetSpecs () const noexcept
 What the first texture input asks to be rendered into.
 
void process (int32_t port, const ossia::render_target_spec &v)
 

Additional Inherited Members

- Public Attributes inherited from score::gfx::OutputNode
bool preview {}
 
bool previewHub {}
 
- Public Attributes inherited from score::gfx::Node
std::vector< Port * > input
 Input ports of that node.
 
ossia::small_pod_vector< Port *, 1 > output
 Output ports of that node.
 
ossia::flat_map< RenderList *, score::gfx::NodeRenderer * > renderedNodes
 Map associating each RenderList to a Renderer for this model.
 
std::vector< std::shared_ptr< PreviewTap > > previewTaps
 Previews of the outputs of this node, read back by a render list of the patch that renders it. See PreviewTap.
 
ossia::flat_map< int32_t, ossia::render_target_spec > renderTargetSpecs
 Render target info.
 
std::atomic_int64_t materialChanged {0}
 
std::atomic_int64_t renderTargetSpecChanged {-1}
 
int32_t nodeId = score::gfx::invalid_node_index
 
bool requiresDepth {}
 
- Protected Member Functions inherited from score::gfx::OutputNode
bool checkDeviceLost (const OffscreenFrame &frame, QRhi &rhi, const char *output) noexcept
 Calls handleDeviceLost when the frame or the QRhi report a lost device. Returns deviceLost().
 
bool checkDeviceLost (int frameOpResult, QRhi &rhi, const char *output) noexcept
 
void resetDeviceLost () noexcept
 
void releaseOwnedRenderList ()
 Invoke OutputConfiguration::onReleaseRenderList, if any.
 
- Protected Attributes inherited from score::gfx::OutputNode
std::function< void()> m_onReleaseRenderList
 
std::unique_ptr< GpuResourceRegistry > m_registry
 
std::shared_ptr< PointerState > m_pointerState {std::make_shared<PointerState>()}
 
bool m_deviceLost {}
 

Member Function Documentation

◆ canRender()

bool Gfx::SpoutNode::canRender ( ) const
inlineoverridevirtual

◆ configuration()

Configuration Gfx::SpoutNode::configuration ( ) const
inlineoverridevirtualnoexcept

◆ createOutput()

void Gfx::SpoutNode::createOutput ( score::gfx::OutputConfiguration  conf)
inlineoverridevirtual

◆ createRenderer()

score::gfx::OutputNodeRenderer * Gfx::SpoutNode::createRenderer ( score::gfx::RenderList &  r) const
inlineoverridevirtualnoexcept

Create a renderer in a given context for this node.

Implements score::gfx::OutputNode.

◆ destroyOutput()

void Gfx::SpoutNode::destroyOutput ( )
inlineoverridevirtual

◆ onRendererChange()

void Gfx::SpoutNode::onRendererChange ( )
inlineoverridevirtual

◆ render()

void Gfx::SpoutNode::render ( )
inlineoverridevirtual

◆ renderer()

score::gfx::RenderList * Gfx::SpoutNode::renderer ( ) const
inlineoverridevirtual

◆ renderState()

std::shared_ptr< score::gfx::RenderState > Gfx::SpoutNode::renderState ( ) const
inlineoverridevirtual

◆ setRenderer()

void Gfx::SpoutNode::setRenderer ( std::shared_ptr< score::gfx::RenderList >  r)
inlineoverridevirtual

◆ startRendering()

void Gfx::SpoutNode::startRendering ( )
inlineoverridevirtual

◆ stopRendering()

void Gfx::SpoutNode::stopRendering ( )
inlineoverridevirtual

The documentation for this struct was generated from the following file:
  • SpoutOutput.cpp