Commit Graph

2730 Commits

Author SHA1 Message Date
Thilo Borgmann 4dcb2f7478 lavu: fix grammar in doxy for av_frame_ref.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-11 00:40:48 +02:00
Derek Buitenhuis d9c1fb8376 bprint: Include va_copy compat
Fixes build with MSVC and ICL.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-08-10 15:53:32 -04:00
Michael Niedermayer 5fc5170c55 avutil/opt: make const tables static const
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 18:44:40 +02:00
Michael Niedermayer 18b1381c5f avutil/opt: fix av_log type
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 18:44:40 +02:00
Michael Niedermayer 148310ca16 avutil/log: Use bprint for part
This should fix the issue with strings longer than 1024

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 18:17:30 +02:00
Michael Niedermayer 112c970ca6 avutil/bprint: add av_vbprintf()
Reviewed-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 17:01:42 +02:00
Michael Niedermayer b37ff488b8 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  libavutil: Make avpriv_open a library-internal function on msvcrt

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 10:51:03 +02:00
Michael Niedermayer ef13a005c4 Merge commit 'a76d0cdf21c3d9e464623cc0ad1c005abf952afa'
* commit 'a76d0cdf21c3d9e464623cc0ad1c005abf952afa':
  libavutil: Move avpriv_open to a new file, file_open.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 10:37:20 +02:00
Michael Niedermayer 09f1afc784 Merge commit '33237123c83bf4f8345e6ac889ad2e7dbd303d0e'
* commit '33237123c83bf4f8345e6ac889ad2e7dbd303d0e':
  libavutil: Enable the MSVC DLL symbol loading workaround in shared builds as well

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-10 10:24:33 +02:00
Reimar Döffinger d4db7c334b Integrate accessors.h header into internal.h
I have no idea why I added a separate header,
I think there is no good reason for it.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2013-08-10 07:56:42 +02:00
Martin Storsjö e743e7ae6e libavutil: Make avpriv_open a library-internal function on msvcrt
Add one copy of the function into each of the libraries, similarly
to what we do for log2_tab. When using static libs, only one
copy of the file_open.o object file gets included, while when
using shared libraries, each of them get a copy of its own.

This fixes DLL builds with a statically linked C runtime, where
each DLL effectively has got its own instance of the C runtime,
where file descriptors can't be shared across runtimes.

On systems not using msvcrt, the function is not duplicated.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-10 00:53:33 +03:00
Martin Storsjö a76d0cdf21 libavutil: Move avpriv_open to a new file, file_open.c
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-10 00:53:33 +03:00
Martin Storsjö 33237123c8 libavutil: Enable the MSVC DLL symbol loading workaround in shared builds as well
This used to only be necessary in static builds (when using the
dynamically linked C runtime), since the _imp prefixed symbols do
exist when linking to the actual DLL. When building testprogs,
however, the current library (e.g. libavutil for some of the testprogs)
is linked statically.

This fixes make fate on DLL builds when using the dynamically
linked C runtime.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-10 00:53:25 +03:00
Michael Niedermayer c94f9e8542 avutil/mem: Fix flipped condition
Fixes return code and later null pointer dereference

Found-by: Laurent Butti <laurentb@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-09 13:47:10 +02:00
Michael Niedermayer 0dc17da308 Merge commit 'dfc6b5c81491abf7effb97b23af17ccf7adcd132'
* commit 'dfc6b5c81491abf7effb97b23af17ccf7adcd132':
  file: Move win32 utf8->wchar open wrapper to libavutil

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-09 07:16:38 +02:00
Reimar Döffinger a48979d715 Reduce MAKE_ACCESSORS code duplication via a new header.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2013-08-08 20:32:40 +02:00
Martin Storsjö dfc6b5c814 file: Move win32 utf8->wchar open wrapper to libavutil
When libavformat was changed to use the new avpriv_open function
in 51eb213d00, this silently bypassed the existing wrapper for
win32. Move the win32 wrapper into libavutil/file.c to make sure
it gets called everywhere (not just in the libavformat case).

This makes sure that non-ascii file names gets opened properly
(where file names internally are stored as utf8, but they get
converted to wchar_t and opened with _wsopen).

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-08 16:41:33 +03:00
Michael Niedermayer 579a137897 Merge commit '880391ed2d2faf796ca3a16f63cec69767546a21'
* commit '880391ed2d2faf796ca3a16f63cec69767546a21':
  libavutil: use avpriv_open()

Conflicts:
	libavutil/random_seed.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-08 11:18:17 +02:00
Derek Buitenhuis 87e8cbf709 libavutil: Don't use fcntl if the function does not exist
Not all platforms have the function.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-08 11:10:33 +02:00
Michael Niedermayer 5f38317e59 Merge commit '869b04e89154cd92d2bcfdabcecbe3217864c099'
* commit '869b04e89154cd92d2bcfdabcecbe3217864c099':
  libavutil: add avpriv_open() to open files with close-on-exec flag

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-08 11:07:51 +02:00
Derek Buitenhuis 0f1fb6c019 libavutil: Don't use fcntl if the function does not exist
Not all platforms have the function.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-08 11:07:51 +03:00
Michael Niedermayer 0b5d1b88e0 avutil/opt: fix types passed to the format string "%s"
Fixes gcc warnings
Fixes CID1061056
Fixes CID1061057

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-08 02:48:44 +02:00
Rémi Denis-Courmont 880391ed2d libavutil: use avpriv_open()
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-08-07 21:12:28 +02:00
Rémi Denis-Courmont 869b04e891 libavutil: add avpriv_open() to open files with close-on-exec flag
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-08-07 21:12:20 +02:00
Michael Niedermayer b11b7ceb89 Merge remote-tracking branch 'cigaes/master'
* cigaes/master:
  ffmpeg: remove obsolete workaround in trim insertion.
  lavu/log: do not skip overwritten lines.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-07 19:16:12 +02:00
Michael Niedermayer 60ae776d04 av_frame_copy_props: fix unintended self assignment
Fixes CID1061052

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-07 17:27:07 +02:00
Nicolas George 39bb26f91b lavu/log: do not skip overwritten lines.
If the line ends with \r, it will not flood the tty, and
the "Last message repeated" line would overwrite it.
Fix bug introduced by c25d1ba.
2013-08-07 16:01:45 +02:00
Michael Niedermayer a68b6ec7f5 avutil/hmac: make const tables static const
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-06 20:30:55 +02:00
Michael Niedermayer 4ee0984341 Merge commit 'a0ad5d011318f951ecd4c9ffe1829518c9533909'
* commit 'a0ad5d011318f951ecd4c9ffe1829518c9533909':
  vdpau: deprecate old codec-specific pixel formats

Conflicts:
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-06 13:45:21 +02:00
Rémi Denis-Courmont a0ad5d0113 vdpau: deprecate old codec-specific pixel formats
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-08-05 11:16:54 +02:00
Michael Niedermayer 20be5e0a0e Merge commit '7950e519bb094897f957b9a9531cc60ba46cbc91'
* commit '7950e519bb094897f957b9a9531cc60ba46cbc91':
  Disable deprecation warnings for cases where a replacement is available

Conflicts:
	libavcodec/avpacket.c
	libavcodec/pthread.c
	libavcodec/utils.c
	libavdevice/v4l2.c
	libavfilter/avfiltergraph.c
	libavfilter/buffersrc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 10:08:30 +02:00
Michael Niedermayer 85fc1a18ca Merge commit '3a7050ffed5ce061b114a11e4de4b77aba8efa0b'
* commit '3a7050ffed5ce061b114a11e4de4b77aba8efa0b':
  build: Add _Pragma macro to disable deprecated declaration warnings

Conflicts:
	configure

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 09:27:37 +02:00
Michael Niedermayer a8e963835a Merge commit 'b5a138652ff8a5b987d3e1191e67fd9f6575527e'
* commit 'b5a138652ff8a5b987d3e1191e67fd9f6575527e':
  Give less generic names to global library option arrays

Conflicts:
	libavcodec/options_table.h
	libavfilter/avfilter.c
	libavformat/options_table.h
	libswscale/options.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-03 09:16:36 +02:00
Diego Biurrun 7950e519bb Disable deprecation warnings for cases where a replacement is available 2013-08-02 19:19:02 +02:00
Diego Biurrun 3a7050ffed build: Add _Pragma macro to disable deprecated declaration warnings 2013-08-02 19:19:02 +02:00
Diego Biurrun b5a138652f Give less generic names to global library option arrays 2013-08-02 19:19:02 +02:00
Michael Niedermayer 9408d990c4 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  avframe: have av_frame_get_side_data take const AVFrame*

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-01 13:59:50 +02:00
Michael Niedermayer cca229e75a Merge commit 'c7e921a54ffe7feb9f695c82f0a0764ab8d0f62b'
* commit 'c7e921a54ffe7feb9f695c82f0a0764ab8d0f62b':
  avopt: Check whether the object actually has got an AVClass

Conflicts:
	libavutil/opt.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-01 12:30:30 +02:00
Michael Niedermayer b326438139 avutil/tree: fix memleaks
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-01 11:29:12 +02:00
Michael Niedermayer 161054f37b Merge commit 'c2e936de07d054bf476e60445b453bf6b4836820'
* commit 'c2e936de07d054bf476e60445b453bf6b4836820':
  tree-test: Refactor and plug memory leaks

Conflicts:
	libavutil/tree.c

Most of this commit is not merged due to bugs in it

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-01 11:29:03 +02:00
Michael Niedermayer bc47d126bf Merge commit 'a9b04b2c43f95cc17c2291f83c27a3119471d986'
* commit 'a9b04b2c43f95cc17c2291f83c27a3119471d986':
  tree.h: K&R formatting and typo cosmetics

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-01 10:41:06 +02:00
Vittorio Giovara 3c8bff0740 avframe: have av_frame_get_side_data take const AVFrame*
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-08-01 09:41:45 +02:00
Martin Storsjö c7e921a54f avopt: Check whether the object actually has got an AVClass
AVIOContext has got an av_class member that only gets set if
opening the context using avio_open2, but not if allocating a
custom IO context. A caller that wants to read AVOptions from
an AVIOContext (recursively using AV_OPT_SEARCH_CHILDREN) may
not know if the AVIOContext actually has got a class set or not.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-07-31 21:31:14 +03:00
Diego Biurrun c2e936de07 tree-test: Refactor and plug memory leaks
With the most annoying memory leak found by Derek Buitenhuis.
2013-07-31 18:14:08 +02:00
Diego Biurrun a9b04b2c43 tree.h: K&R formatting and typo cosmetics 2013-07-31 18:14:08 +02:00
Michael Niedermayer 231e33f050 avutil/pixfmt: dont refer to deprecated PIX_FMT in the documentation
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-30 12:32:05 +02:00
Michael Niedermayer 1f5755d869 Merge commit 'd99a2b6d0a4d0b2f5ba6a1f1637d6cb88c5c9184'
* commit 'd99a2b6d0a4d0b2f5ba6a1f1637d6cb88c5c9184':
  avutil/tree: Drop debug messages that clutter the output

Conflicts:
	libavutil/tree.c

Merge for metadata only, a better solution has been commited that allows the
debug output to be turned on and off

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-30 11:06:03 +02:00
Michael Niedermayer db75537e25 avutil/tree: allow adjusting the log level
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-30 11:04:48 +02:00
Michael Niedermayer 647836608c avutil/tree: change debug output to AV_LOG_DEBUG level
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-30 11:04:39 +02:00
Michael Niedermayer 93b3a5edff Merge commit '10db1a9bca46b0f760a1263d47142b2f57e195d7'
* commit '10db1a9bca46b0f760a1263d47142b2f57e195d7':
  avutil/tree: K&R formatting cosmetics

Conflicts:
	libavutil/tree.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-07-30 10:42:40 +02:00