Commit graph

783 commits

Author SHA1 Message Date
Edward Hervey
a90df26e15 ffmpegenc: Disable non-audio/video encoders
Fixes #629648
2011-01-03 11:45:04 +01:00
Wim Taymans
22d44c87b1 ffmpgdec: work around parser timestamp bug
Sometimes the parser loses track of timestamps and starts to reuse old
timestamp. Feed it some dummy data and clear some context variables to work
around the problem.
2010-12-21 12:14:22 +01:00
Sebastian Dröge
dde194dc1a ffvideoscale: Change classification to Filter/Converter/Video/Scaler 2010-12-16 10:12:02 +01:00
Sebastian Dröge
a5910b4ec4 ffdeinterlace: Change classification to Filter/Effect/Video/Deinterlace 2010-12-16 10:05:03 +01:00
Wim Taymans
ec48b24291 dec: scale the estimated duration by number of frames
When estimating the frame duration, the diff between two incomming timestamps
should be scaled by the amount of frames in the interval. Improves duration
estimation and DTS interpolation.
2010-12-12 12:38:55 +01:00
Wim Taymans
957c728b3d dec: use input timestamp diff for duration estimation
Use the diff between input timestamps to estimate the duration when no duration
is set on input buffers. Only do this when there are no reordered input
timestamps. Improves interpolation in DTS mode when no input duration is set.
2010-12-12 11:20:22 +01:00
Mark Nauwelaerts
e837ec505d ffmpegenc: ensure proper clean state prior to (re-)negotiation
Fixes #632691.
2010-10-25 12:16:44 +02:00
Wim Taymans
d82633c4e3 ffdec: don't destroy the parser state
When we flush the parser cache, we only need to clear the bytes of the cache,
not the complete state of the cache. In the case of H264 this doesn't require
the parser to receive a new SPS/PPS after a DISCONT buffer.
2010-10-22 13:05:16 +02:00
Wim Taymans
cc2a6e493b ffdec: be more careful with DTS timestamp interpolation
Don't use -1 and 0 duration buffers to calculate next output timestamp as they
are very likely wrong.

Fixes #632877
2010-10-22 13:05:16 +02:00
Stefan Kost
07ce1d1906 various: add missing G_PARAM_STATIC_STRINGS flags 2010-10-19 17:26:08 +03:00
Sebastian Dröge
51fe1a04e6 ffmpeg: Add mapping for YUVA420P <-> A420
This is used by VP6a, which is used by Flash.

See bug #613901.
2010-10-15 11:23:26 +02:00
Edward Hervey
51a0e1270f ffmpegdec: Fix debug statements 2010-10-12 16:17:51 +02:00
Wim Taymans
3f213c1b73 ffdec: use a better algorithm to detect DTS timestamps
Add function to reset the timestamp tracking.
Check for reordered timestamps on the input buffers and assume PTS input
timestamps when we see reordered timestamps.
Recover from an occasionally wrong input timestamp by also tracking the output
timestamps. When we detect a reordered output timestamp, assume DTS input
timestamps again.

Fixes #611500
2010-10-07 17:46:22 +02:00
Wim Taymans
a0bc6f6e9d ffdec: add debug line 2010-10-06 18:51:24 +02:00
Wim Taymans
48e612afda ffdec: add fixmes 2010-10-06 18:23:57 +02:00
Wim Taymans
b41aab3690 ffdec: add some comments 2010-10-06 18:15:03 +02:00
Wim Taymans
76d9685202 ffdec: Add timestamp tracking
Use ffmpeg reordered_opaque to track an id that combines all timing info we have
for a frame. The ids are kept in a 255 item cache.

Fixes #631075
2010-10-06 17:42:30 +02:00
Wim Taymans
edb79396f2 ffdec: remove broken TSHandler
Remove the TShandler code, it is broken when QoS is enabled and ffmpeg provides
much easier methods for tracking timestamps.
Simplify pcache joining.
2010-10-06 17:42:30 +02:00
Wim Taymans
4aa9b97d3f ffcodecmap: avoid setting large framerates
When the framerate is bigger than 1000/1, set it to 0/1 instead. This avoids
letting the videosink do QoS on these very small frame durations.
2010-10-06 16:58:52 +02:00
Wim Taymans
c330cdcc5d ffdec: rename time variable
Rename the time variable to avoid confusion with the time function.
Add some debug to the QoS update function.
2010-10-06 16:58:40 +02:00
Wim Taymans
7d531c06bb ffenc: pass the input size to the encoder
Pass the input buffer size to the encoder instead of the expected output size.
This is needed to make fixed input/output encoder work.
2010-10-06 16:58:34 +02:00
Sebastian Dröge
37357063bf ffmpegdemux: Don't use GST_FLOW_IS_FATAL() and GST_FLOW_IS_SUCCESS() 2010-08-27 18:29:15 +02:00
Tim-Philipp Müller
e0984904c3 ffdeinterlace: some minor clean-ups
Don't use studlyCaps; gboolean != GstFlowReturn; use gst_caps_set_simple()
instead of creating a GValue just to set a boolean field on a caps structure.

See #622736.
2010-07-18 20:15:32 +01:00
Edward Hervey
f9c8fac537 ffmpegmux: Use "Formatter/Metadata" klass when needed
https://bugzilla.gnome.org/show_bug.cgi?id=623671
2010-07-06 14:02:09 +02:00
Edward Hervey
25db74ec41 ffmpegmux: Add more replacements
https://bugzilla.gnome.org/show_bug.cgi?id=623671
2010-07-06 14:02:09 +02:00
Edward Hervey
6191dbb7dd codecmap: Fix the caps of various mov/amr formats
https://bugzilla.gnome.org/show_bug.cgi?id=623671
2010-07-06 14:02:09 +02:00
Edward Hervey
38c2b3788e gstffmpegmux: Set rank of blacklisted muxers to GST_RANK_NONE
https://bugzilla.gnome.org/show_bug.cgi?id=623671
2010-07-06 14:02:09 +02:00
Edward Hervey
00e177458c ext: Fix CFLAGS order
We'd pick up system-wide ffmpeg headers otherwise
2010-07-05 15:48:41 +02:00
Mark Nauwelaerts
1d0b29414a ffmpegenc: fix timestamp resyncing some more
Convert bytes to samples in remaining occurrence.

See #623388.
2010-07-05 11:10:09 +02:00
Thiago Santos
b8f556a566 ffmpegenc: Fix timestamp resyncing
Properly convert bytes into time using sample size, sample rate
and channels number, instead of sample rate only.

This can cause huge timestamp discontinuities (even though the
durations remain correct) and might cause problems to muxers.

Fixes #623388
2010-07-03 11:57:09 -03:00
Edward Hervey
2f6086e495 ffmpegmux: Add rtp to the blacklisted muxers 2010-07-02 17:21:27 +02:00
Edward Hervey
edeb185374 codecmap: Specify the quicktime variant for mov and mp4 formats 2010-07-02 12:40:03 +02:00
David Schleef
00d87bcd83 ffmpegmux: Add alternate element in description
For muxers where there is a better GStreamer alternative, add
"(not recommended, use alternate_element_name instead)" to
the description.

https://bugzilla.gnome.org/show_bug.cgi?id=622773
2010-06-27 10:38:25 +02:00
David Schleef
52e8d62513 ffmpegmux: Disable raw muxers
They are effectively identity elements.  Many are already
disabled via blacklist.

https://bugzilla.gnome.org/show_bug.cgi?id=622773
2010-06-27 10:38:24 +02:00
Andoni Morales Alastruey
7f12d83a39 ffdeinterlace: Set "interlaced=false" in the source pad's caps
https://bugzilla.gnome.org/show_bug.cgi?id=622736
2010-06-25 17:26:56 +02:00
Thijs Vermeir
330d78f4ff Fix build if ORC is not installed 2010-06-15 09:40:18 +02:00
Sebastian Dröge
3d91d93f32 ffmpeg: Call orc_init() before trying to get target flags 2010-06-14 15:31:34 +02:00
Sebastian Dröge
899d2f0cec Use orc instead of liboil for CPU feature detection 2010-06-14 14:38:44 +02:00
Albert Lee
f310322e90 gstffmpegcodecmap: Fix ATRAC1/3 caps 2010-06-11 08:23:34 +02:00
Zaheer Abbas Merali
22a343207c ffmpegdec: fix typo in comment 2010-06-04 18:30:59 +01:00
Edward Hervey
c28097b6c4 codecmap: First round of type mapping wrapping : image formats 2010-05-31 18:53:12 +02:00
Edward Hervey
2fccd4640f ffmpegdec/enc: Blacklist more raw formats 2010-05-31 18:44:02 +02:00
Tim-Philipp Müller
dc2efe2d24 ffmpegdec: sipro decoder should have higher rank than realaudiodec 2010-05-25 12:55:14 +01:00
Edward Hervey
f9c2467241 ffmpegdec: Don't leak the GstDataPassThrough items 2010-05-17 19:43:24 +02:00
Olivier Crête
83820511a8 gstffmpegenc: Make getcaps proxy the downstream height/width/framerate requirements
See #577784.
2010-05-10 15:41:57 +02:00
Olivier Crête
2b891aff61 codecmap: Respect the various h263 options
See #577784.
2010-05-10 15:41:45 +02:00
Olivier Crête
21e855d167 gstffmpegcfg: Expose loop-filter flag
See #577784.
2010-05-10 15:41:07 +02:00
Edward Hervey
0fb014fdbe ffmpegcodecmap: Add mapping for SIPR 2010-05-08 13:47:56 +02:00
Sebastian Dröge
c023b6a47a postproc: Mark postproc filters table as const 2010-03-24 16:37:37 +01:00
Sebastian Dröge
af3de9ac9f ffmpeg: Fix some remaining compiler warnings 2010-03-24 12:36:27 +01:00
Sebastian Dröge
a450bd027f build: Add all kinds of compiler warning flags and fix the resulting warnings 2010-03-24 12:07:28 +01:00
Sebastian Dröge
2e079b742a ffmpeg: Use gst_element_set_details_simple() 2010-03-24 11:51:53 +01:00
Edward Hervey
3230d4da09 gstffmpegcodecmap: Give a proper mapping for NSV format 2010-03-23 18:53:24 +01:00
Raimo Järvi
9637ff5ab1 ffdec: Update caps if the aspect ratio changes
Fixes bug #613231.
2010-03-18 14:08:51 +01:00
Thiago Santos
b234d0b308 ffdec: Make metadata writable before setting caps
In case we haven't created the output buffer, we should make
metadata writable before setting caps on it.
Fixes check unit tests.
2010-03-11 10:13:46 -03:00
Thiago Santos
c300a0a9f2 ffdec_aac: Do not parse raw format
If the stream is 'raw' format, do not use parsers.
Re-enables the aac decoder by putting it back to default
ffdec rank.

Fixes #566250
2010-03-11 09:55:49 -03:00
Edward Hervey
7162290afe ffmpegdemux: Use av_free_packet.
Fixes #611782
2010-03-04 08:59:19 +01:00
Edward Hervey
d4e63b2727 gstffmpegdec: Disable direct-rendering for svq1/vp56 decoders.
They use a non-standard stride which we can't support.

Fixes #610613
2010-03-03 19:03:19 +01:00
Edward Hervey
38b71e40e6 gstffmpegcodecmap: Remove 'format' specified for wmv3 decoder.
Allows WMVA (Advanced Profile) videos to be properly auto-linked.
Doesn't introduce a regression for VC1 files.

Fixes #611722
2010-03-03 18:35:40 +01:00
Edward Hervey
bb2acca229 gstffmpegdec: Handle durations in reordered frames
The buffer durations were not being reordered along with the timestamp
and offset of the buffers, resulting in buffers using the duration of the
latest incoming frame instead of their original frame.

Fixes #611398
2010-03-01 12:52:19 +01:00
Mark Nauwelaerts
6cf7cadf9b ffmpegdec: do not store timestamp for buffer that will be skipped
Fixes #610481.
2010-02-19 20:33:06 +01:00
Edward Hervey
cc4d502d30 gstffmpegdec: Don't enable xvmc decoders, we can't support the output 2010-02-18 13:29:35 +01:00
Edward Hervey
5678ff1ac0 gstffmpegcodecmap: Add mapping for Indeo 5 2010-02-18 13:29:35 +01:00
Edward Hervey
9c497b6010 gstffmpegcodecmap: Add mapping for Windows Media Speech 2010-02-18 13:29:35 +01:00
Wim Taymans
430b8eb74d ffdec: fixup QCELP to always be mono
Make QCELP always mono, even if the caps tell us a different layout.
2010-02-04 17:08:41 +01:00
Wim Taymans
14e8ce8816 ffmpegdec: only clip to a smaller region
When we have an input width/height that should be used for clipping, only
perform the clipping if the rectangle is smaller than the actual picture size.

Fixes #330681
2010-02-04 13:28:11 +01:00
Wim Taymans
8312a8f89d ffdec: free audio buffer when not decoded
When we don't decode an audio frame (for audio codecs that need a previous audio
frame) free the buffer we allocated.

See #608564
2010-02-01 15:26:43 +01:00
Wim Taymans
d3f9ee4309 ffmpegcodecmap: don't escape codec_data
Don't escape the codec_data, it breaks some streams (but likely also fixes
others). It's better to leave it as is, like most other players do.

See #608332
2010-01-29 14:00:28 +01:00
Edward Hervey
4f9de70744 ffmpegmux/demux: Blacklist ASS/SSA 'demuxers'.
They're not a container format, but a subtitle format, and we already
have plugins to handle those subtitle formats.
2010-01-25 16:40:58 +01:00
Edward Hervey
25073856e4 ffmpegcodecmap: Add proper mapping for Zip Block Motion Video 2010-01-23 15:34:28 +01:00
Edward Hervey
0c938fa10d ffmpegcodecmap: Add proper mapping for LOCO Lossless codec 2010-01-23 14:41:49 +01:00
Edward Hervey
399bb4667b gstffmpegcodecmap: Make a proper mapping for Autodesk Animator Codec 2010-01-23 13:51:24 +01:00
Alessandro Decina
c5f16de56f Revert a change I accidentally introduced in 7c91fb.
I removed the plugin name from an error message for no good reason.
2010-01-22 13:48:24 +01:00
Alessandro Decina
7c91fb4cf4 Fix compiler warnings under OS X. 2010-01-22 11:43:59 +01:00
Julien Moutte
0b40ac6331 ffvideoscale: Fix build warning.
FFMpeg swscale function wants some const pointers.
2010-01-15 22:21:42 +01:00
Edward Hervey
56172c60af gstffmpegcodecmap: Add mappings for new codecs
WMAPro
Dolby TrueHD
Atrac1
TwinVQ
2010-01-13 19:50:10 +01:00
Mark Nauwelaerts
8236e74ca4 ffmpegenc: more consideration for upstream (audio) timestamps 2010-01-12 18:17:40 +01:00
Tim-Philipp Müller
a657f789d3 ffmpegdec: ignore all vdpau decoders
Make check for vdpau decoders more generic. There might be vdpau
decoders we don't expect when using an external ffmpeg version,
and we want those blacklisted as well (e.g. ffdec_mpeg4_vdpau).
2009-12-09 15:27:14 +00:00
Jan Schmidt
faa417cf34 caps: Use default audio channel layouts for some codecs
For a few white-listed codecs, use default fallback channel
layouts when ffmpeg doesn't inform us.
2009-11-22 12:28:12 +01:00
Olivier Crête
b69fcc471e ffenc: Make keyframe forcing thread-safe
Make the keyframe forcing thread-safe, also emit a downstream event
to allow muxers or payloaders to react appropriately.

https://bugzilla.gnome.org/show_bug.cgi?id=602556
2009-11-20 22:14:51 -05:00
Edward Hervey
a00fb254aa Move encoders and muxers to GST_RANK_SECONDARY. 2009-11-18 17:36:48 +01:00
Wim Taymans
59bc425174 ffdec: remove clipping hack
Remove a hack that seems to produce wrong clipping values.
2009-11-16 13:55:01 +01:00
Jan Schmidt
62d54db07d ffmpeg: VC-1/WMV3 fixes.
Use format field in the pad caps to differentiate VC-1 from WMV3.
Fix a typo in the caps creation and parsing - the field is called
'format' - not 'fourcc'

Add a dodgy hack to populate the extradata size field
(first byte) when it is 0 - as it seems to be for some (Matroska)
test files.
2009-11-11 18:53:36 +00:00
Sjoerd Simons
19e81024a3 Always give the most video restricted caps possible
When the video caps aren't fixed yet, make sure we return the most
precise set of caps. It seems a regression was introduced in cc082f,
causing restricted caps to never be used if the context == NULL

None of the restricted caps generation uses the context, so no need to
check whether the context.

Fixes bug #578160.
2009-11-10 12:30:50 +01:00
Edward Hervey
a1384f990b ffmpegdec: Only restore default in AVCodecContext when needed.
Resetting default values is currently very complex in libavcodec, so
we only call it when needed (i.e. when a context was previously used).

Shaves off 10% of the setup of a decoder.
2009-11-09 19:21:35 +01:00
Tim-Philipp Müller
72cd8f1843 ffmpegdec: printf format fixes 2009-11-05 23:54:47 +00:00
Edward Hervey
019a6020e4 ffdec: Don't use an allocated 1-entry structure for private data.
If there's only one entry, just use that entry.
2009-11-02 09:06:46 +01:00
Edward Hervey
bd1b315c43 ffmux: avoid generating caps when registering
Don't generate caps when we register the class but delay that till when
we actually create an instance of the class.
2009-11-02 09:06:40 +01:00
Edward Hervey
e8c689fe94 ffdemux: avoid generating caps when registering
Don't generate caps when we register the class but delay that till when
we actually create an instance of the class.
2009-11-02 09:06:05 +01:00
Edward Hervey
a7dd30d8eb ffenc: avoid generating caps when registering
Don't generate caps when we register the class but delay that till when
we actually create an instance of the class.
2009-11-02 09:06:05 +01:00
Wim Taymans
343c82b18c ffdec: avoid generating caps when registering
Don't generate caps when we register the class but delay that till when
we actually create an instance of the class.
2009-10-22 16:27:28 -04:00
Sebastian Dröge
2ed8b6728d ffmpegenc: Add a note to the buffer-size property description
Setting it has no effect anymore and is deprecated.
2009-10-08 13:54:45 +02:00
Sebastian Dröge
087582d7cd Revert "ffenc: Make the buffer-size property read-only"
This reverts commit 98439aacc7.

Instead of printing a warning when trying to set the property
it should do nothing as before and the property description
should contain a note that setting it has no effect.
2009-10-08 13:52:22 +02:00
Sebastian Dröge
98439aacc7 ffenc: Make the buffer-size property read-only
...instead of just doing nothing when setting it. This makes sure
that people notice that they shouldn't set the property because
it creates a warning now.
2009-10-08 12:29:30 +02:00
Sebastian Dröge
c914f08b40 ffenc: Make sure to always provide large enough buffers
For audio always add the minimum ffmpeg buffer size, for video
use the same weird buffer size as they use in ffmpeg.c:
width*height*6 + 200

Also make setting of the buffer-size property a no-op.

Fixes bug #593651.
2009-10-07 09:15:40 +02:00
Sebastian Dröge
3a96bed6e6 ffmpegenc: Use dash instead of underscore in property names
GLib internally converts them to dashs anyway.
2009-10-07 09:13:56 +02:00
Sebastian Dröge
ee31435d49 Revert "ffmpegenc: Use dash instead of underscore in property names"
This reverts commit b814d25cc9.
2009-10-01 17:03:49 +02:00
Sebastian Dröge
25003e4307 Revert "ffenc: Make sure to always provide large enough buffers"
This reverts commit d9f6febe70.
2009-10-01 17:03:42 +02:00
Sebastian Dröge
799b19c2f2 Revert "ffmpegenc: Also add FF_MIN_BUFFER_SIZE to video buffers too"
This reverts commit 577525af3d.
2009-10-01 17:03:33 +02:00
Sebastian Dröge
577525af3d ffmpegenc: Also add FF_MIN_BUFFER_SIZE to video buffers too
Just to make sure we never get below it in case of very small videos.
2009-10-01 16:46:34 +02:00