[FFmpeg-devel] [PATCH 1/1] This change adds an encoder for Camera metadata motion. This is a type of sensor data associated with video, such as GPS, acceleration, gyro, and camera orientation. It does not encode video itself, but rather, this metadata.

wm4 nfxjfg at googlemail.com
Mon Jul 10 11:48:26 EEST 2017


On Fri, 7 Jul 2017 15:24:02 -0700
"Louis O'Bryan" <louiso-at-google.com at ffmpeg.org> wrote:

> > +static av_cold int encode_init(AVCodecContext *avctx) {  
> > > +    // Use dummy values for the height and width.
> > > +    avctx->width = DUMMY_ENCODER_SIZE;
> > > +    avctx->height = DUMMY_ENCODER_SIZE;
> > > +    avctx->max_pixels = DUMMY_ENCODER_SIZE;  
> > What? This makes no sense.  
> 
> Using avcodec_encode_video2() seems to require that the width and height be
> nonzero. What is the recommended way to avoid that?

Well, that API is for video. So I guess it's natural that it errors out
if some basic parameters that would be necessarily always required for
video are not set. There are other APIs for audio and subtitles. Also,
these API functions are deprecated.


More information about the ffmpeg-devel mailing list