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

◆ from_stream()

static StreamSlice MayaFlux::Kakshya::StreamSlice::from_stream ( std::shared_ptr< DynamicSoundStream stream,
uint8_t  index = 0 
)
inlinestatic

Construct a slice spanning the full stream across all channels.

Parameters
streamSource stream.
indexSlot identity.

Definition at line 44 of file StreamSlice.hpp.

47 {
48 const uint64_t end_frame = stream->get_num_frames() > 0
49 ? stream->get_num_frames() - 1
50 : 0;
51 const uint64_t end_channel = stream->get_num_channels() > 0
52 ? stream->get_num_channels() - 1
53 : 0;
54 return StreamSlice {
55 .stream = std::move(stream),
57 .index = index,
58 };
59 }
static Region audio_span(uint64_t start_frame, uint64_t end_frame, uint32_t start_channel, uint32_t end_channel, const std::string &label="")
Create a Region representing a span in audio (frames and channels).
Definition Region.hpp:176
std::shared_ptr< DynamicSoundStream > stream

References MayaFlux::Kakshya::Region::audio_span(), end_channel(), end_frame(), index, and stream.

+ Here is the call graph for this function: