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

◆ write_to_container() [1/2]

void MayaFlux::Kriya::detail::write_to_container ( const std::shared_ptr< Kakshya::DynamicSoundStream > &  container,
const Kakshya::DataVariant &  data,
uint32_t  channel 
)

Definition at line 49 of file PipelineBufferData.cpp.

50{
51 try {
52 const auto& audio_data = std::get<std::vector<double>>(data);
53 std::span<const double> data_span(audio_data.data(), audio_data.size());
54
55 container->append_frames(data_span, channel);
56
57 } catch (const std::bad_variant_access& e) {
58 error_rethrow(Journal::Component::Kriya,
59 Journal::Context::CoroutineScheduling,
60 std::source_location::current(),
61 "Data type mismatch when writing to container: {}",
62 e.what());
63 } catch (const std::exception& e) {
64 error_rethrow(Journal::Component::Kriya,
65 Journal::Context::CoroutineScheduling,
66 std::source_location::current(),
67 "Error writing to container: {}",
68 e.what());
69 }
70}

References MayaFlux::Journal::CoroutineScheduling, and MayaFlux::Journal::Kriya.

Referenced by MayaFlux::Kriya::BufferPipeline::process_fuse(), and MayaFlux::Kriya::BufferPipeline::process_route().

+ Here is the caller graph for this function: