Template Function spdl::core::convert_frames(const Frames<media> *, std::shared_ptr<CPUStorage>)

Function Documentation

template<MediaType media>
CPUBufferPtr spdl::core::convert_frames(const Frames<media> *frames, std::shared_ptr<CPUStorage> storage = nullptr)

Convert a single frame to a CPU buffer.

Converts decoded frames into a contiguous CPU buffer suitable for processing or copying to other memory systems.

Template Parameters:

media – Media type (Audio, Video, or Image).

Parameters:
  • framesFrames to convert.

  • storage – Optional pre-allocated storage. If not provided, allocates new storage.

Returns:

CPU buffer containing the converted frame data.