mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-28 20:05:38 +00:00
Update API to whatever ffmpeg changed the past few days
Original commit message from CVS: Update API to whatever ffmpeg changed the past few days
This commit is contained in:
parent
306e1bffad
commit
0d32d395f1
4 changed files with 9 additions and 9 deletions
2
common
2
common
|
@ -1 +1 @@
|
|||
Subproject commit 92ff5101d55c0f853620bf13f8dd528992824137
|
||||
Subproject commit 79e6940e7ff1a6cbf959a1f7a0a3d1ed3f90d3ee
|
|
@ -41,7 +41,7 @@ struct _GstFFMpegDec {
|
|||
GstPad *sinkpad;
|
||||
|
||||
AVCodecContext *context;
|
||||
AVPicture *picture;
|
||||
AVFrame *picture;
|
||||
};
|
||||
|
||||
typedef struct _GstFFMpegDecClass GstFFMpegDecClass;
|
||||
|
@ -208,7 +208,7 @@ gst_ffmpegdec_init(GstFFMpegDec *ffmpegdec)
|
|||
gst_element_add_pad (GST_ELEMENT (ffmpegdec), ffmpegdec->sinkpad);
|
||||
gst_element_add_pad (GST_ELEMENT (ffmpegdec), ffmpegdec->srcpad);
|
||||
|
||||
ffmpegdec->picture = g_malloc0 (sizeof (AVPicture));
|
||||
ffmpegdec->picture = g_malloc0 (sizeof (AVFrame));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -383,7 +383,7 @@ gst_ffmpegenc_chain_video (GstPad *pad, GstBuffer *inbuf)
|
|||
GstFFMpegEnc *ffmpegenc = (GstFFMpegEnc *)(gst_pad_get_parent (pad));
|
||||
gpointer data;
|
||||
gint size, frame_size;
|
||||
AVPicture picture, rpicture, *toencode;
|
||||
AVFrame picture, rpicture, *toencode;
|
||||
gboolean free_data = FALSE, free_res = FALSE;
|
||||
|
||||
data = GST_BUFFER_DATA (inbuf);
|
||||
|
@ -411,7 +411,7 @@ gst_ffmpegenc_chain_video (GstPad *pad, GstBuffer *inbuf)
|
|||
}
|
||||
*/
|
||||
|
||||
avpicture_fill (&picture, data, PIX_FMT_YUV420P, ffmpegenc->in_width, ffmpegenc->in_height);
|
||||
avpicture_fill ((AVPicture*)&picture, data, PIX_FMT_YUV420P, ffmpegenc->in_width, ffmpegenc->in_height);
|
||||
toencode = &picture;
|
||||
|
||||
if (ffmpegenc->need_resample) {
|
||||
|
@ -419,12 +419,12 @@ gst_ffmpegenc_chain_video (GstPad *pad, GstBuffer *inbuf)
|
|||
guint8 *rdata;
|
||||
|
||||
rdata = g_malloc ((rframe_size * 3)/2);
|
||||
avpicture_fill (&rpicture, rdata, PIX_FMT_YUV420P, ffmpegenc->context->width, ffmpegenc->context->height);
|
||||
avpicture_fill ((AVPicture*)&rpicture, rdata, PIX_FMT_YUV420P, ffmpegenc->context->width, ffmpegenc->context->height);
|
||||
|
||||
free_res = TRUE;
|
||||
toencode = &rpicture;
|
||||
|
||||
img_resample (ffmpegenc->resample, &rpicture, &picture);
|
||||
img_resample (ffmpegenc->resample, (AVPicture*)&rpicture, (AVPicture*)&picture);
|
||||
}
|
||||
|
||||
outbuf = gst_buffer_new ();
|
||||
|
|
|
@ -37,7 +37,7 @@ struct _GstFFMpegMux {
|
|||
GstPad *sinkpad;
|
||||
|
||||
AVCodecContext *context;
|
||||
AVPicture *picture;
|
||||
AVFrame *picture;
|
||||
};
|
||||
|
||||
typedef struct _GstFFMpegMuxClass GstFFMpegMuxClass;
|
||||
|
@ -213,7 +213,7 @@ gst_ffmpegmux_init(GstFFMpegMux *ffmpegmux)
|
|||
gst_element_add_pad (GST_ELEMENT (ffmpegmux), ffmpegmux->sinkpad);
|
||||
gst_element_add_pad (GST_ELEMENT (ffmpegmux), ffmpegmux->srcpad);
|
||||
|
||||
ffmpegmux->picture = g_malloc0 (sizeof (AVPicture));
|
||||
ffmpegmux->picture = g_malloc0 (sizeof (AVFrame));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue