Use new ffmpeg revision

Original commit message from CVS:
Use new ffmpeg revision
This commit is contained in:
Ronald S. Bultje 2003-05-29 19:34:00 +00:00
parent 51124a1514
commit 56ab463205
5 changed files with 12 additions and 37 deletions

2
common

@ -1 +1 @@
Subproject commit ed429334bba35b10172ba97d9b3795b75a65b388 Subproject commit 9a3a505fcc52865de0bedbb3ee1ce0a6dcc9a025

View file

@ -159,12 +159,7 @@ gst_ffmpeg_codecid_to_caps (enum CodecID codec_id,
break; break;
case PIX_FMT_RGBA32: case PIX_FMT_RGBA32:
bpp = depth = 32; bpp = depth = 32;
endianness = G_BIG_ENDIAN; endianness = G_BYTE_ORDER;
r_mask = 0x00ff0000; g_mask = 0x0000ff00; b_mask = 0x000000ff;
break;
case PIX_FMT_BGRA32:
bpp = depth = 32;
endianness = G_BIG_ENDIAN;
r_mask = 0x00ff0000; g_mask = 0x0000ff00; b_mask = 0x000000ff; r_mask = 0x00ff0000; g_mask = 0x0000ff00; b_mask = 0x000000ff;
break; break;
case PIX_FMT_YUV410P: case PIX_FMT_YUV410P:
@ -175,22 +170,12 @@ gst_ffmpeg_codecid_to_caps (enum CodecID codec_id,
break; break;
case PIX_FMT_RGB565: case PIX_FMT_RGB565:
bpp = depth = 16; bpp = depth = 16;
endianness = G_BIG_ENDIAN; endianness = G_BYTE_ORDER;
r_mask = 0xf800; g_mask = 0x07e0; b_mask = 0x001f; r_mask = 0xf800; g_mask = 0x07e0; b_mask = 0x001f;
break; break;
case PIX_FMT_RGB555: case PIX_FMT_RGB555:
bpp = 16; depth = 15; bpp = 16; depth = 15;
endianness = G_BIG_ENDIAN; endianness = G_BYTE_ORDER;
r_mask = 0x7c00; g_mask = 0x03e0; b_mask = 0x001f;
break;
case PIX_FMT_BGR565:
bpp = depth = 16;
endianness = G_LITTLE_ENDIAN;
r_mask = 0xf800; g_mask = 0x07e0; b_mask = 0x001f;
break;
case PIX_FMT_BGR555:
bpp = 16; depth = 16;
endianness = G_LITTLE_ENDIAN;
r_mask = 0x7c00; g_mask = 0x03e0; b_mask = 0x001f; r_mask = 0x7c00; g_mask = 0x03e0; b_mask = 0x001f;
break; break;
default: default:
@ -562,18 +547,10 @@ gst_ffmpeg_caps_to_codecid (GstCaps *caps,
gst_caps_get_int(caps, "depth", &depth); gst_caps_get_int(caps, "depth", &depth);
switch (depth) { switch (depth) {
case 15: case 15:
if (endianness == G_BIG_ENDIAN) { context->pix_fmt = PIX_FMT_RGB555;
context->pix_fmt = PIX_FMT_RGB555;
} else {
context->pix_fmt = PIX_FMT_BGR555;
}
break; break;
case 16: case 16:
if (endianness == G_BIG_ENDIAN) { context->pix_fmt = PIX_FMT_RGB565;
context->pix_fmt = PIX_FMT_RGB565;
} else {
context->pix_fmt = PIX_FMT_BGR565;
}
break; break;
case 24: case 24:
if (endianness == G_BIG_ENDIAN) { if (endianness == G_BIG_ENDIAN) {
@ -583,11 +560,7 @@ gst_ffmpeg_caps_to_codecid (GstCaps *caps,
} }
break; break;
case 32: case 32:
if (endianness == G_BIG_ENDIAN) { context->pix_fmt = PIX_FMT_RGBA32;
context->pix_fmt = PIX_FMT_RGBA32;
} else {
context->pix_fmt = PIX_FMT_BGRA32;
}
break; break;
} }
break; break;

View file

@ -87,7 +87,7 @@ gst_ffmpegcodec_codec_context_to_caps (AVCodecContext *context, int codec_id)
return GST_CAPS_NEW ("ffmpeg_mpeg4", return GST_CAPS_NEW ("ffmpeg_mpeg4",
"video/avi", "video/avi",
"format", GST_PROPS_STRING ("strf_vids"), "format", GST_PROPS_STRING ("strf_vids"),
"compression", GST_PROPS_FOURCC (context->fourcc), "compression", GST_PROPS_FOURCC (context->codec_tag),
"width", GST_PROPS_INT (context->width), "width", GST_PROPS_INT (context->width),
"height", GST_PROPS_INT (context->height) "height", GST_PROPS_INT (context->height)
); );

View file

@ -297,7 +297,8 @@ gst_ffmpegenc_init(GstFFMpegEnc *ffmpegenc)
ffmpegenc->context->qmax = 15; ffmpegenc->context->qmax = 15;
ffmpegenc->context->max_qdiff = 3; ffmpegenc->context->max_qdiff = 3;
ffmpegenc->context->gop_size = 15; ffmpegenc->context->gop_size = 15;
ffmpegenc->context->frame_rate = 25 * FRAME_RATE_BASE; ffmpegenc->context->frame_rate = 25 * DEFAULT_FRAME_RATE_BASE;
ffmpegenc->context->frame_rate_base = DEFAULT_FRAME_RATE_BASE;
ffmpegenc->out_width = -1; ffmpegenc->out_width = -1;
ffmpegenc->out_height = -1; ffmpegenc->out_height = -1;
} }

View file

@ -172,7 +172,8 @@ gst_ffmpegmux_sinkconnect (GstPad *pad, GstCaps *caps)
gst_caps_get_int (caps, "height", &ffmpegmux->context->height); gst_caps_get_int (caps, "height", &ffmpegmux->context->height);
ffmpegmux->context->pix_fmt = PIX_FMT_YUV420P; ffmpegmux->context->pix_fmt = PIX_FMT_YUV420P;
ffmpegmux->context->frame_rate = 23 * FRAME_RATE_BASE; ffmpegmux->context->frame_rate = 23 * DEFAULT_FRAME_RATE_BASE;
ffmpegmux->context->frame_rate_base = DEFAULT_FRAME_RATE_BASE;
ffmpegmux->context->bit_rate = 0; ffmpegmux->context->bit_rate = 0;
/* FIXME bug in ffmpeg */ /* FIXME bug in ffmpeg */