MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ set_texture()

void MayaFlux::Buffers::FormaProcessor::set_texture ( std::shared_ptr< Core::VKImage >  image,
std::string  binding 
)

Supply a texture to bind on the next graphics tick.

Stores the image and binding name behind an atomic dirty flag. On the next processing_function call the image is bound to the RenderProcessor via bind_texture(). Calling again replaces the pending binding before it has been consumed.

Parameters
imageGPU image. nullptr clears the binding.
bindingDescriptor name matching the fragment shader.

Definition at line 134 of file FormaProcessor.cpp.

135{
136 m_pending_texture = PendingTexture { .image = std::move(image), .binding = std::move(binding) };
137 m_texture_dirty.test_and_set(std::memory_order_release);
138}
IO::ImageData image
Definition Decoder.cpp:47
std::optional< PendingTexture > m_pending_texture

References MayaFlux::Buffers::FormaProcessor::PendingTexture::image, image, m_pending_texture, and m_texture_dirty.