1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02:00
Commit Graph

243 Commits

Author SHA1 Message Date
Clément Bœsch
d079d1d368 ffprobe: do not escape '"' between single quotes. 2013-01-01 13:32:51 +01:00
Stefano Sabatini
1a490df12f ffprobe: show pkt_size in frame
Fix trac ticket #2027.
2012-12-15 11:46:47 +01:00
Stefano Sabatini
9a7256e8e0 ffprobe: free dictionary in opt_show_entries()
Fix memleak.
2012-11-23 18:49:26 +01:00
Stefano Sabatini
c8a5365dcf ffprobe: implement -sections option 2012-11-22 14:19:29 +01:00
Stefano Sabatini
196765a7cc ffprobe: implement subsection field selection through the -show_entries option 2012-11-22 14:19:25 +01:00
Stefano Sabatini
64dc383de5 ffprobe: fix typo in a comment 2012-11-21 20:17:57 +01:00
Stefano Sabatini
6ca9c74cc6 ffprobe: add "," at the end of enum list 2012-11-21 20:17:57 +01:00
Stefano Sabatini
29d46d7bce ffprobe: fix potential NULL pointer dereference
Found by Coverity, should fix CID 733741.
2012-11-06 22:59:24 +01:00
Stefano Sabatini
a945607a78 ffprobe: add an array of section print buffers to the WriterContext
Allow to factorize buffers initialization/release, for all the writers
which use it. Simplify.
2012-10-24 23:40:21 +02:00
Michael Niedermayer
4334ba043e ffprobe: fix use of uninitialized pointer in av_strtok()
Fixes CID733837
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-11 03:37:43 +02:00
Stefano Sabatini
531872d763 ffprobe: reindent after previous commit 2012-10-05 23:58:23 +02:00
Stefano Sabatini
3d189d41c1 ffprobe: add -select_streams option 2012-10-05 23:58:18 +02:00
Michael Niedermayer
8f0168a3b9 fix exit_program() prototypes
This fixes 2 warnings

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-02 21:55:31 +02:00
Michael Niedermayer
032ba74ed2 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  ARM: fix Thumb PIC on Apple
  nut: add do {} while (0) to GET_V
  tiffenc: Check av_malloc() results.
  tiffenc: Simplify pixel format setup using AVPixFmtDescriptor.
  Use atexit() instead of defining a custom exit_program() interface.
  msvc: Fix detection of VFW & Avisynth required libs

Conflicts:
	ffmpeg.c
	ffmpeg_opt.c
	ffplay.c
	ffprobe.c
	ffserver.c
	libavcodec/tiffenc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-02 19:48:54 +02:00
Stefano Sabatini
301f6da039 ffprobe: extend disposition printing support
This generalizes the previous work on disposition printing.

Disposition flags are shown in a dedicated section, which should improve
output intellegibility, extensibility and filtering operations.

This breaks output syntax with the recently introduced disposition
printing.
2012-09-30 12:22:19 +02:00
Stefano Sabatini
50efde6bcb ffprobe: generalize nesting model for the XML writer
Do not make use of ad-hoc "tags" code, introduce a new section flag
SECTION_FLAG_HAS_VARIABLE_FIELDS to deal with the tags in a
content-agnostic way.

This is required by the pending disposition change.
2012-09-30 12:07:47 +02:00
Stefano Sabatini
74bd0cf49c ffprobe: rework/fix ini writer
Do not build from scratch the section header for each section, but build
it using the previous level buffer, thus improving efficiency.

Also fix some few corner cases related to numbering which are exposed by
the pending disposition patch.
2012-09-29 10:25:11 +02:00
Stefano Sabatini
01e4537f66 ffprobe: rework/fix flat writer
Do not build from scratch the section header for each section, but build
using the previous level buffer, thus improving efficiency and fix some
few corner cases which are exposed by the pending disposition patch.
2012-09-29 10:25:04 +02:00
Stefano Sabatini
06fd4c2dfa ffprobe: generalize nesting model for the compact writer
Regular section fields nested in a regular section are now prefixed by
the nested section name.

This is required by the pending change related to disposition.
2012-09-29 10:24:53 +02:00
Stefano Sabatini
44c1cc3f8e ffprobe: generalize nesting model for the default writer
Regular section fields nested in a regular section are now prefixed by
the nested section name.

This is required by the pending change related to disposition.
2012-09-29 10:24:45 +02:00
Stefano Sabatini
b6ea9c8765 ffprobe: drop SECTION_ENTRY macro
The use of the macro makes to add new optional fields somewhat harder.
2012-09-29 10:24:36 +02:00
Stefano Sabatini
23564a4a4a ffprobe: add support to library ident printing 2012-09-29 10:24:28 +02:00
Stefano Sabatini
ed2b69a4c3 ffprobe: remove unused "args" argument in writer init callback
The parameter is no longer used, since the arguments are parsed at the
framework level.
2012-09-28 16:37:27 +02:00
Stefano Sabatini
163f7afbe6 ffprobe: fix indentation of the first line of packets_and_frames sections in the json output 2012-09-27 01:10:46 +02:00
Stefano Sabatini
4552e9b56c ffprobe: generalize writer subsection nesting model
Discard unflexible structure based on the root/chapter/section layout in
favor of a generalized concept of section.

This should allow to represent sections at a generic level of nesting,
and allow subsection fields selection.

Also, simplify the code.
2012-09-26 11:07:09 +02:00
Stefano Sabatini
2089f93300 ffprobe: drop pointless opaque parameter in writer init callback
The parameter was never used.
2012-09-25 11:02:52 +02:00
Stefano Sabatini
58e9025993 ffprobe: reindent after previous commit 2012-09-25 09:22:00 +02:00
Stefano Sabatini
4b370d6126 ffprobe: rework checking logic in writer_print_time() and writer_print_rational()
Make writer_print_time() and writer_print_rational() always call
writer_print_int() or writer_print_string(). This way the checks for
determining if the value should be printed or not are consistently
performed in the low level functions.

writer_print_rational() is moved downward in order to avoid a forward
reference.

Simplify/amend the overall logic.
2012-09-25 09:20:57 +02:00
Alexander Strasser
dde8068856 ffprobe: Consider the chosen separator when doing CSV escaping
Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-09-25 01:32:34 +02:00
Alexander Strasser
dd83028374 ffprobe: Rename variable in csv_escape_str()
Sync to 3245be9 .

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-09-25 01:32:19 +02:00
Alexander Strasser
f70122dd57 ffprobe: Simplify CSV field quoting code
Sync with bac1b31 .

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-09-25 01:32:13 +02:00
Stefano Sabatini
42047c3e86 ffprobe: reindent after the previous commit 2012-09-22 09:34:56 +02:00
Stefano Sabatini
4cd1addcc4 ffprobe: add -bitexact boolean option
The option is mostly useful to make ffprobe output independent from the
build, and in particular to fix FATE --enable-small failures.
2012-09-22 09:34:56 +02:00
Stefano Sabatini
9543cd593e ffprobe: print format long_name only if non-NULL
Fix possible crash when long_name is not defined (for example if
--enable-small).
2012-09-21 13:59:18 +02:00
Stefano Sabatini
0f40105aaa ffprobe: print codec_long_name only when available
Avoid possible segmentation fault if codec_long_name is defined as
NULL (for example if --enable-small).
2012-09-21 09:27:06 +02:00
Stefano Sabatini
f398617b19 ffprobe: fix CSV writer output
Fix regression introduced in 749ddc14fc.
2012-09-19 11:50:05 +02:00
Derek Buitenhuis
8e2a950b29 ffprobe: Add a few common disposition cases
This info is crucial in knowing which stream to pick in an
automated setup.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2012-09-18 16:38:47 -04:00
Stefano Sabatini
8d0e871f25 ffprobe: kill initializers with nested union field definition
The c99-to-c89 converter (for MSVC support) doesn't currently handle
designated initializers or compound literals with nested unions or
structs.

This is apparently the only place where this construct is used in the
FFmpeg codebase.
2012-09-14 10:47:08 +02:00
Stefano Sabatini
5e99a23b2d ffprobe: avoid potentially lossy long long int -> double cast in value_string()
Previously the cast long long int -> double was always performed (and
then the double was converted back to long long int) even when it was
avoidable.
2012-09-14 10:42:54 +02:00
Stefano Sabatini
f9dd2e5e1a ffprobe: print start_pts and duration_ts stream information 2012-09-12 10:22:29 +02:00
Stefano Sabatini
749ddc14fc ffprobe: add priv_class field to Writer, and factorize writer options initialization 2012-09-11 22:30:23 +02:00
Stefano Sabatini
0c71d5a077 ffprobe: add print_section option to the compact writer
Allow to skip section name at the begin of each line. Possibly simplify
output.
2012-09-11 01:14:57 +02:00
Stefano Sabatini
f740c1a9c2 ffprobe: add and use DEFINE_WRITER_CLASS macro
Factorize writer class definition.
2012-09-11 01:02:20 +02:00
Stefano Sabatini
e4fe4d01fc ffprobe: simplify default printer
Remove pointless default_print_footer() and
default_print_chapter_header() callbacks, also avoid to print an
empty line when noprint_wrappers is selected.
2012-09-10 10:22:36 +02:00
Michael Niedermayer
7992814920 ffprobe: avoid unsafe usage of the snprintf() return code
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-09 14:26:42 +02:00
Michael Niedermayer
b027156b19 ffprobe: use exp2 instead of pow(2, ...) 2012-09-09 13:02:08 +02:00
Michael Niedermayer
d46c1c72e4 Merge commit 'e6153f173a49e5bfa70b0c04d2f82930533597b9'
* commit 'e6153f173a49e5bfa70b0c04d2f82930533597b9':
  avopt: Store defaults for AV_OPT_TYPE_INT in the i64 union member

Conflicts:
	libavcodec/libopenjpegdec.c
	libavcodec/libopenjpegenc.c
	libavcodec/libx264.c
	libavcodec/mpeg12enc.c
	libavcodec/options_table.h
	libavcodec/snowenc.c
	libavcodec/tiffenc.c
	libavdevice/v4l2.c
	libavdevice/x11grab.c
	libavfilter/af_amix.c
	libavfilter/af_asyncts.c
	libavfilter/af_join.c
	libavfilter/buffersrc.c
	libavfilter/src_movie.c
	libavfilter/vf_delogo.c
	libavfilter/vf_drawtext.c
	libavformat/http.c
	libavformat/img2dec.c
	libavformat/img2enc.c
	libavformat/movenc.c
	libavformat/mpegenc.c
	libavformat/mpegtsenc.c
	libavformat/options_table.h
	libavformat/segment.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-05 14:33:32 +02:00
Michael Niedermayer
98298eb103 Merge commit 'ec36aa69448f20a78d8c4588265022e0b2272ab5'
* commit 'ec36aa69448f20a78d8c4588265022e0b2272ab5':
  x86: Fix linking with some or all of yasm, mmx, optimizations disabled
  configure: Add more fine-grained SSE CPU capabilities flags
  avfilter: x86: Use more precise compile template names
  x86: cosmetics: Comment some #endifs for better readability
  g723_1: add comfort noise generation
  utvideoenc: Switch to dsputils' median prediction
  utvideoenc: Avoid writing into the input picture
  avtools: remove the distinction between func_arg and func2_arg.
  avconv: make the -passlogfile option per-stream.
  avconv: make the -pass option per-stream.
  cmdutils: make -codecs print lossy/lossless flags.
  lavc: add lossy/lossless codec properties.

Conflicts:
	Changelog
	cmdutils.c
	configure
	doc/APIchanges
	ffmpeg.h
	ffmpeg_opt.c
	ffprobe.c
	libavcodec/codec_desc.c
	libavcodec/g723_1.c
	libavcodec/utvideoenc.c
	libavcodec/version.h
	libavcodec/x86/mpegaudiodec.c
	libavcodec/x86/rv40dsp_init.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-31 13:01:30 +02:00
Michael Niedermayer
416d2f7a12 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  vc1: export some functions
  configure: use HOSTCC_C/O in check_host_cc
  configure: use AS_O setting in check_as
  configure: use LD_O setting in check_ld()
  Revert "dsputil: make {add/put/put_signed}_pixels_clamped() non-static."
  build: Restore dependency of acelp_filters.o on celp_math.o
  celp_math: Replace duplicate ff_dot_productf() by ff_scalarproduct_c()
  celp_math: Move ff_cos() to the only place it is used
  build: Use portable abstraction for linker/hostcc output file syntax
  configure: Fix shared library creation for OpenBSD
  vp56: Don't use DECLARE_ALIGN on a typedef name
  mss1: move code that will be reused by MSS2 decoder into separate file
  mss1: merge decode_intra() and decode_inter()
  avprobe: Get rid of ugly casts in the options table
  vf_hqdn3d: Remove a duplicate inline declaration

Conflicts:
	Makefile
	configure
	ffprobe.c
	libavcodec/Makefile
	libavcodec/amrnbdec.c
	libavcodec/amrwbdec.c
	libavcodec/celp_math.c
	libavcodec/celp_math.h
	libavcodec/dsputil.c
	libavcodec/lsp.c
	libavcodec/mss1.c
	libavcodec/ra288.c
	libavcodec/vc1dec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-28 16:28:48 +02:00
Michael Niedermayer
bb3ed3bae6 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  fate: Add FATE tests for the Ut Video encoder
  lavc: add Ut Video encoder
  mpegvideo_enc: remove stray duplicate line from 7f9aaa4
  swscale: x86: fix #endif comments in rgb2rgb template file
  avconv: mark more options as expert.
  avconv: split printing "main options" into global and per-file.
  avconv: refactor help printing.

Conflicts:
	Changelog
	ffmpeg_opt.c
	ffserver.c
	libavcodec/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-20 17:31:55 +02:00