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

◆ is_readback_available()

MAYAFLUX_API bool MayaFlux::Kakshya::is_readback_available ( const std::shared_ptr< Core::Window > &  window)

Check whether a completed frame is currently available for readback.

Returns false if the window has no registered swapchain or if the last in-flight fence has not yet signalled.

Parameters
windowTarget window.
Returns
true if readback_region() can safely be called now.

Definition at line 205 of file SurfaceUtils.cpp.

206{
207 auto* svc = get_display_service();
208 if (!svc)
209 return false;
210
211 uint32_t w = 0, h = 0;
212 svc->get_swapchain_extent(std::static_pointer_cast<void>(window), w, h);
213 return w > 0 && h > 0;
214}

Referenced by MayaFlux::Kakshya::WindowAccessProcessor::process().

+ Here is the caller graph for this function: