Commit Graph

702 Commits

Author SHA1 Message Date
Vitor Sessak 96573c0d76 lavf/utils.c: Order packets with identical PTS by stream index.
This allows for more reproducible results when using multi-threading.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-04-12 19:06:26 -04:00
Anton Khirnov ff1ec0c3f8 avio: undeprecate av_url_read_fseek/fpause under nicer names
It seems their replacements won't be ready anytime soon.
2011-04-12 19:17:05 +02:00
Anton Khirnov a9bf9d8e53 lavf: make av_guess_image2_codec internal
It doesn't look very useful as a public function.
2011-04-08 16:44:29 +02:00
Anton Khirnov c5704b2b9a lavf: mark av_pkt_dump(_log) for remove on $next+1 bump. 2011-04-08 15:44:09 +02:00
Anton Khirnov 5cec897105 avio: move extern url_interrupt_cb declaration from avio.h to url.h 2011-04-07 18:11:24 +02:00
Anton Khirnov f87b1b373a avio: AVIO_ prefixes for URL_ open flags. 2011-04-07 18:07:16 +02:00
Anton Khirnov 56a1000917 lavf: if id3v2 tag is present and all else fails, guess by file extension 2011-04-06 14:10:08 +02:00
Anton Khirnov 8978fedaee avio: introduce an AVIOContext.seekable field
Use it instead of url_is_streamed and AVIOContext.is_streamed.
2011-04-03 22:46:40 +02:00
Anton Khirnov ab11317c1f lavf: make compute_chapters_end less picky.
In particular, now it assumes that
a) chapters are chronologically ordered
b) chapters have the same timebases
c) duration of the stream is known
and asserts if any of these is not met.

Make it properly deal with harsher conditions.

fixes issue2320
2011-04-01 19:53:55 +02:00
Justin Ruggles c70a6a41dd Use audio_service_type to set stream disposition. 2011-03-25 16:58:50 -04:00
Anton Khirnov 933e90a69a avio: make av_url_read_fseek/fpause internal.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-21 14:54:52 -04:00
Mans Rullgard 2912e87a6c Replace FFmpeg with Libav in licence headers
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-03-19 13:33:20 +00:00
Martin Storsjö f1f60f5252 lavf: Make make_absolute_url a lavf internal function
This is shared by both applehttp demuxer and protocol.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2011-03-17 12:28:37 +01:00
Stefano Sabatini 68d875addc lavf: make av_interleave_packet() return meaningful error codes
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit c5dcb3d493)

Signed-off-by: Reinhard Tartler <siretart@tauware.de>
2011-03-17 07:30:09 +01:00
Stefano Sabatini 70abc32314 lavf: enable av_dlog message in av_interleaved_write_frame()
Help debugging timestamp issues.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit d541c8b468)

Signed-off-by: Reinhard Tartler <siretart@tauware.de>
2011-03-17 07:29:57 +01:00
Stefano Sabatini 79f43a8cb6 lavf: enable av_dlog() in compute_pkt_fields2()
Turns a comment into an av_dlog() instruction, also add a commented
issues.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 77f21ce464)

Signed-off-by: Reinhard Tartler <siretart@tauware.de>
2011-03-17 07:29:47 +01:00
Anton Khirnov 59f65d9579 avio: make url_setbufsize internal.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-16 22:59:38 -04:00
Janne Grunau a03be6e1ba use LIBAV_LICENSE and LIBAV_VERSION instead of FFMPEG_* 2011-03-16 21:54:39 +01:00
Janne Grunau 29ba091136 replace FFMPEG with LIBAV in FFMPEG_CONFIGURATION
also update the multiple inclusion guards in config.h|mak
2011-03-16 21:54:39 +01:00
Nicolas George c76374c6db Use AVERROR_EXIT with url_interrupt_cb.
Functions interrupted by url_interrupt_cb should not be restarted.
Therefore using AVERROR(EINTR) was wrong, as it did not allow to distinguish
when the underlying system call was interrupted and actually needed to be
restarted.

This fixes roundup issues 2657 and 2659 (ffplay not exiting for streamed
content).

Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-15 08:09:19 -04:00
Anton Khirnov 75b9ed04b9 lavf/utils: dont't explicitly check AVIOContext.error
The error should be caught in write_packet()/write_trailer()

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-15 08:04:10 -04:00
Anton Khirnov f1ef2cd9ed avio: move ff_rewind_with_probe_data from avio.h to avio_internal.h
also change its prefix to ffio

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-07 12:25:36 -05:00
Anton Khirnov 76aa876e69 avio: avio_ prefix for url_fsize
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-07 11:03:39 -05:00
Anton Khirnov a2704c9712 avio: add avio_tell macro as a replacement for url_ftell
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-04 11:26:57 -05:00
Martin Storsjö 863c471638 libavformat: Add av_pkt_dump{, _log}2, taking an AVStream parameter
This removes a fixme issue, by allowing the av_pkt_dump functions
to use the correct time base.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2011-03-02 11:29:38 +01:00
Anton Khirnov 6b4aa5dac8 avio: avio_ prefix for url_fseek
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-03-01 12:12:33 -05:00
Anton Khirnov 22a3212e32 avio: rename url_fopen/fclose -> avio_open/close.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-23 10:18:55 -05:00
Anton Khirnov b7effd4e83 avio: avio_ prefixes for get_* functions
In the name of consistency:
get_byte           -> avio_r8
get_<type>         -> avio_r<type>
get_buffer         -> avio_read

get_partial_buffer will be made private later

get_strz is left out becase I want to change it later to return
something useful.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-21 11:23:22 -05:00
Anton Khirnov ae628ec1fd avio: rename ByteIOContext to AVIOContext.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-20 08:37:15 -05:00
Anton Khirnov ab0287fcbd Move find_info_tag to lavu and add av_ prefix to it
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net>
2011-02-17 15:35:18 +01:00
Stefano Sabatini f6c7375a17 Deprecate parse_date() in favor of av_parse_time().
The new av_parse_time() is created in libavutil/parseutils.h, all the
internal functions used by parse_date are moved to
libavutil/parseutils.c and made static.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-02-16 23:39:56 +00:00
Anton Khirnov 610219a598 lavf: add av_ prefix to dump_format()
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-02-16 23:39:56 +00:00
Balint Marton 22ec6b738f Fix av_find_best_stream when using a program
The current implementation has a bug, it is returning the stream index
in the found program, and not the stream index in the list of all
streams. The attached patch fixes this issue.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-02-16 11:47:42 +00:00
Reinhard Tartler 737eb5976f Merge libavcore into libavutil
It is pretty hopeless that other considerable projects will adopt
libavutil alone in other projects. Projects that need small footprint
are better off with more specialized libraries such as gnulib or rather
just copy the necessary parts that they need. With this in mind, nobody
is helped by having libavutil and libavcore split. In order to ease
maintenance inside and around FFmpeg and to reduce confusion where to
put common code, avcore's functionality is merged (back) to avutil.

Signed-off-by: Reinhard Tartler <siretart@tauware.de>
2011-02-15 16:18:21 +01:00
Anssi Hannula 24a83bd10a lavf: add AV_DISPOSITION_CLEAN_EFFECTS flag
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-02-14 23:16:32 +00:00
Anssi Hannula 3c33c0e263 lavf: print stream disposition in dump_stream_format
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net>
2011-02-13 15:21:11 +01:00
Peter Ross 5209149157 make av_find_best_stream() ignore streams marked with AV_DISPOSITION_*_IMPAIRED
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net>
2011-02-10 22:55:17 +01:00
Alexander Strange 37b00b47cb Frame-based multithreading framework using pthreads
See doc/multithreading.txt for details on use in codecs.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-09 09:17:28 -05:00
Anssi Hannula 3940caad02 lavf: rename ff_probe_input_buffer to make it public
It is useful for applications that hand input data directly to lavf via
a ByteIOContext.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-08 18:25:12 -05:00
Anssi Hannula aad216fd7e lavf: simplify pb parameter of ff_probe_input_buffer
There is no need to pass the ByteIOContext via a pointer to a pointer
anymore.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-08 18:25:11 -05:00
Reimar Döffinger b3190529df Make av_set_pts_info keep previous time base if new one is invalid.
Fixes issue 2475.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-06 16:12:15 -05:00
Martin Storsjö f124b087ee libavformat: Add a function for freeing an AVFormatContext
This function is useful for freeing data structures allocated by
muxers, which currently have to be freed manually by the caller.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-04 11:29:41 -05:00
Peter Ross e6fb5a4f78 add ff_index_search_timestamp and ff_add_index_entry
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-02-03 21:50:54 -05:00
Diego Elio Pettenò 101e1f6ff9 Make ff_interleave_compare_dts static to utils.c.
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net>
2011-01-25 21:48:03 +01:00
Stefano Sabatini 440d761e40 Clarify timestamps related error messages in compute_pkt_fields2().
Originally committed as revision 26308 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-11 12:17:27 +00:00
Daniel Kang 6cbce63650 Fix assertion fail on audio files with invalid sample rates,
fixes issue 2475.

Patch by Daniel Kang, daniel.d.kang at gmail

Originally committed as revision 26240 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-06 03:30:19 +00:00
Stefano Sabatini 6bbdba08c2 Revert previous commit, as it was not meant to be pushed.
Originally committed as revision 26239 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-06 01:11:57 +00:00
Stefano Sabatini 7820147e6f Issue more explicit error messages in compute_pkt_fields2().
Originally committed as revision 26238 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-06 01:01:21 +00:00
Stefano Sabatini 81bd411965 In av_close_input_stream(), flush the packet queue before to actually
close the stream.

This way the flushed packets can still reference the still unclosed
format context.

In particular this fixes a spurious error issued when closing the
video4linux2 buffer in mmap_release_buffer(), which tries to access
the file descriptor of an already closed file.

Originally committed as revision 26237 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-06 01:01:14 +00:00
Anssi Hannula cf99e4aa00 Add AVOption support for muxers.
Patch by Anssi Hannula, anssi d hannula a iki d fi

Originally committed as revision 26195 to svn://svn.ffmpeg.org/ffmpeg/trunk
2011-01-02 10:52:34 +00:00