5.3.4.149. Function video_writer_alloc_init

5.3.4.149.1. Function Documentation

video_writer_t *video_writer_alloc_init(const char *path, const size_t start, const size_t n_ffmpeg_threads, const size_t img_height, const size_t img_width, const enum pixfmt_e pixfmt, const enum video_codec_e codec_type, const int win_play, const uint8_t ffmpeg_debug, const char *ffmpeg_out_codec, const char *ffmpeg_out_extra_opts)

Allocation and initialization of inner data required for a video writer.

Parameters
  • path – Path to the video or images.

  • start – Start frame number (first frame is frame 0).

  • n_ffmpeg_threads – Number of threads used in FFMPEG to encode the video sequence (0 means FFMPEG will decide).

  • img_height – Images height.

  • img_width – Images width.

  • pixfmt – Pixels format (grayscale or RGB).

  • codec_type – Select the API to use for video codec (VCDC_FFMPEG_IO or VCDC_VCODECS_IO).

  • win_play – Boolean, if 0 write into a file, if 1 play in a SDL window.

  • ffmpeg_debug – Print the ffmpeg command line.

  • ffmpeg_out_codec – Specify the codec to use in ffmpeg (can be NULL).

  • ffmpeg_out_extra_opts – Pass extra arguments to ffmpeg (can be NULL).

Returns

The allocated data.