[Ffmpeg-devel] Re: codec for real-time capturing

Zinetz Victor mail
Fri Dec 9 15:15:47 CET 2005


> Hi, try huffyuv or ffv1. They should be quite fast and good for
> intermediate storage.

thnks for advise

i try CODEC_ID_HUFFYUV but get run-time error 'Unable to open video codec':
[code]
  av_register_all;

  video_codec_context := avcodec_alloc_context ();

  video_codec_context^.codec_type := CODEC_TYPE_VIDEO;
  video_codec_context^.codec_id := CODEC_ID_HUFFYUV;
  video_codec_context^.bit_rate := Params.video_bitrate;
  video_codec_context^.width := Params.video_width;
  video_codec_context^.height := Params.video_height;
  video_codec_context^.time_base.den := 12;
  video_codec_context^.time_base.num := 1;
  video_codec_context^.gop_size := 12;
  video_codec_context^.pix_fmt := PIX_FMT_YUV420P;

  video_codec := avcodec_find_encoder (video_codec_context^.codec_id);
  if video_codec = nil then
    raise exception.Create ('Codec not found');

  ret_code := avcodec_open (video_codec_context, video_codec);
  if ret_code = -1 then
    raise Exception.Create ('Unable to open video codec');
[/code]

Probably, there are special options that I'm not aware of? What options 
should I use for using huffyuv? 







More information about the ffmpeg-devel mailing list