5.3.4.145. Function video_reader_alloc_init
Defined in File video_io.h
5.3.4.145.1. Function Documentation
-
video_reader_t *video_reader_alloc_init(const char *path, const size_t start, const size_t end, const size_t skip, const int bufferize, const size_t n_ffmpeg_threads, const enum video_codec_e codec_type, const enum video_codec_hwaccel_e hwaccel, const enum pixfmt_e pixfmt, const uint8_t ffmpeg_debug, const char *ffmpeg_in_extra_opts, int *i0, int *i1, int *j0, int *j1)
Allocation and initialization of inner data required for a video reader.
- Parameters
path – Path to the video or images.
start – Start frame number (first frame is frame 0).
end – Last frame number (if 0 then the video sequence is entirely read).
skip – Number of frames to skip between two frames (0 means no frame is skipped).
bufferize – Boolean to store the entire video sequence in memory first (this is useful for benchmarks but usually the video sequences are too big to be stored in memory).
n_ffmpeg_threads – Number of threads used in FFMPEG to decode the video sequence (0 means FFMPEG will decide).
codec_type – Select the API to use for video codec (
VCDC_FFMPEG_IOorVCDC_VCODECS_IO).hwaccel – Select Hardware accelerator (
VCDC_HWACCEL_NONE,VCDC_HWACCEL_NVDEC,VCDC_HWACCEL_VIDEOTOOLBOX). A NULL value will default toVCDC_HWACCEL_NONE.pixfmt – Pixels format (grayscale or RGB).
ffmpeg_debug – Print the ffmpeg command line.
ffmpeg_in_extra_opts – Pass extra arguments to ffmpeg (can be NULL).
i0 – Return the first \(y\) index in the labels (included).
i1 – Return the last \(y\) index in the labels (included).
j0 – Return the first \(x\) index in the labels (included).
j1 – Return the last \(x\) index in the labels (included).
- Returns
The allocated data.