Commit Graph

13851 Commits

Author SHA1 Message Date
Michael Niedermayer
0e5758d101 H264: print nal_ref_idc too for debug
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-05-01 02:38:29 +02:00
Mike Scheutzow
e12926393b Fix decoding of mpegts streams with h264 video that does *NOT* have b frames
One of the causes of this bug is that the h264 parser defaults low_delay
to 1, but the h264 codec defaults low_delay to 0. Really Ugly.

After many hours of looking at this, I'm still not sure how has_b_frames
is *intended* to behave, but to me the implementation appears way more
complicated than it ought to be.

My patch relies on the encoder to set an optional field in the SPS. This
works for libx264 streams, but I'm not sure that all h264 encoders will
set it.
2011-05-01 01:47:35 +02:00
ami_stuff
8556406d38 lavc: lowercase the FRWU codec name
This is more consistent with all the other codec names.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-05-01 00:42:21 +02:00
Michael Niedermayer
ffb5a0d533 Merge commit '85770f2a2651497861ed938efcd0df3696ff5e45'
* commit '85770f2a2651497861ed938efcd0df3696ff5e45':
  AVOptions: make default_val a union, as proposed in AVOption2.
  Move ff_dynarray_add to lavu and make it public.
  lavf: remove duplicate assignment in avformat_alloc_context.
  lavf: use designated initializers for AVClasses.
  options: simplify av_find_opt by using av_next_option.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-05-01 00:26:05 +02:00
Philip Langdale
8de45adb37 CrystalHD: Add auto-detection of packed b-frame bug.
I still don't fully understand the cause but the difference between
the samples that trigger the bug and the samples that don't is
that the former uses delay frames and the later uses drop frames
as placeholders for the packed frame. So, if we see the one type
of frame, we can assume the bug will or won't be present.

Right now, I'm detecting the frame types by size, which may not be
safe in general, but given the specific codec and file type, I
expect any scenario where we encounter these frames where they
aren't being used for b-frame packing won't care one way or
another whether the work around is in effect or not.

Signed-off-by: Philip Langdale <philipl@overt.org>
2011-04-30 09:47:28 -07:00
Stefano Sabatini
d5551265f3 lavc: remove disabled avcodec_decode_video() code
Fix warning:
libavcodec/utils.c: At top level:
libavcodec/utils.c:714:5: warning: "FF_API_VIDEO_OLD" is not defined

Also fix trac issue #139.
2011-04-30 11:57:13 +02:00
Anton Khirnov
85770f2a26 AVOptions: make default_val a union, as proposed in AVOption2.
This breaks API and ABI.
2011-04-30 08:34:16 +02:00
Baptiste Coudurier
97dc86b793 In libx264 wrapper, change wpredp to a codec specific option. 2011-04-29 18:44:59 -07:00
Michael Niedermayer
be315a3232 Merge remote branch 'qatar/master'
* qatar/master:
Duplicate  AMV: disable DR1 and don't override EMU_EDGE
Duplicate  lavf: inspect more frames for fps when container time base is coarse
Wrong and we have correct fix: Fix races in default av_log handler
  vorbis: Replace sized int_fast integer types with plain int/unsigned.
  Remove disabled non-optimized code variants.
NO  bswap.h: Remove disabled code.
  Remove some disabled printf debug cruft.
  Replace more disabled printf() calls by av_dlog().
NO  tests: Remove disabled code.
NO  Replace some commented-out debug printf() / av_log() messages with av_dlog().
  vorbisdec: Replace some sizeof(type) by sizeof(*variable).
NO  vf_fieldorder: Replace FFmpeg by Libav in license boilerplate.

Conflicts:
	libavcodec/h264.c
	libavcodec/vorbisdec.c
	libavutil/log.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-30 01:58:26 +02:00
Michael Niedermayer
7089265756 AMV: disable DR1 and don't override EMU_EDGE
This works around a possibly exploitable crash.
Appearently, vlc can be exploited with a malicous file. This should get
reverted as soon as a proper fix is found.

Reported-at: Thu, 21 Apr 2011 14:38:25 +0000
Reported-by: Dominic Chell <Dominic.Chell@ngssecure.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 89f903b3d5)
(cherry picked from commit 9b919571e5)
2011-04-29 22:46:13 +02:00
Diego Biurrun
cf3ac54339 vorbis: Replace sized int_fast integer types with plain int/unsigned.
int/unsigned is the natural memory access type for CPUs, using sized types
for temporary variables, counters and similar just increases code size and
can possibly cause a slowdown.
2011-04-29 20:28:40 +02:00
Diego Biurrun
a734fa575f Remove disabled non-optimized code variants. 2011-04-29 20:01:13 +02:00
Diego Biurrun
2e15305b70 Remove some disabled printf debug cruft. 2011-04-29 20:00:53 +02:00
Diego Biurrun
09cbf60f8e Replace more disabled printf() calls by av_dlog(). 2011-04-29 20:00:41 +02:00
Michael Niedermayer
4517ba092e flashsv2enc:fix segfault
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 18:31:17 +02:00
Diego Biurrun
045dd4b928 Replace some commented-out debug printf() / av_log() messages with av_dlog(). 2011-04-29 17:27:01 +02:00
Diego Biurrun
d1be646e90 vorbisdec: Replace some sizeof(type) by sizeof(*variable). 2011-04-29 15:37:06 +02:00
Carl Eugen Hoyos
d804784db5 Set channel layout for True Audio files.
This is not documented (and possibly not originally intended),
but it's what the current reference decoder does.
2011-04-29 10:46:45 +02:00
Carl Eugen Hoyos
d2ee3c913d Fix channel layout for some stereo flac files. 2011-04-29 10:42:43 +02:00
Michael Niedermayer
f0f3425311 flashsv2enc: mark encoder experimental
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 03:06:06 +02:00
Michael Niedermayer
c83a528193 flashsv2enc: remove useless casts
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 02:43:12 +02:00
Michael Niedermayer
ba9c4db59a flashsv2enc: use av_freep()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 02:41:13 +02:00
Michael Niedermayer
f6a5edb64c flashsv2enc: remove useless if()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 02:40:22 +02:00
Joshua Warner
3f6dc4a130 encoder for adobe's flash ScreenVideo2 codec 2011-04-29 02:35:59 +02:00
Michael Niedermayer
85ff339489 Revert "avparser: don't av_malloc(0)."
This hack is no longer needed.

This reverts commit 191e08d113.
2011-04-29 02:17:38 +02:00
ami_stuff
0fea3b7b80 Remove lowres support from cdgraphics decoder
The lowres support doesn't work correctly (crops the video), so let's remove it.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 01:29:19 +02:00
ami_stuff
f27c72b368 Reduce max lowres from 5 to 3 in sp5x decoder
lowres higher than 3 crashes ffmpeg/ffplay here

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 01:29:19 +02:00
ami_stuff
e4f42f1f89 Remove lowres support from pnm decoder
The lowres support doesn't work correctly (crops the video), so let's remove it.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 01:29:19 +02:00
ami_stuff
658296e344 Remove lowres support from png decoder
The lowres support doesn't work correctly (crops the video), so let's remove it.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-29 01:29:19 +02:00
Niobos
f3ce748d34 MJPEG encoder to write aspect ratio information 2011-04-28 20:39:49 +02:00
Michael Niedermayer
a0db7424e4 Fix buffering in qpeg in a way that allows direct rendering.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-28 14:28:27 +02:00
Michael Niedermayer
90bcbc791f Revert "qpeg: use reget_buffer() in decode_frame()"
This reverts commit f4e043ff63.
2011-04-28 13:20:03 +02:00
Carl Eugen Hoyos
b35a846923 Change silly variable name "class" to "partition_class". 2011-04-28 11:23:22 +02:00
Stefano Sabatini
62d33dbc17 mpeg12: terminate mpeg2_video_profiles arrays
Make av_get_profile_name() return NULL if no profile is detected.

Fix trac issue #130, fix crash reading file tek3.m2v.
(cherry picked from commit e5d80c7b2d)

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2011-04-28 11:07:31 +02:00
Peter Ross
87e45ae13d rawvideo codec: support PIX_FMT_BGR48LE and PIX_FMT_BGR48BE
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2011-04-28 07:25:28 +02:00
Michael Niedermayer
0665199e43 Merge remote branch 'qatar/master'
* qatar/master:
  vorbisdec: Rename silly "class_" variable to plain "class".
  simple_idct_alpha: Drop some useless casts.
  Simplify av_log_missing_feature().
  ac3enc: remove check for mismatching channels and channel_layout
  If AVCodecContext.channels is 0 and AVCodecContext.channel_layout is non-zero, set channels based on channel_layout.
  If AVCodecContext.channel_layout and AVCodecContext.channels are both non-zero, check to make sure they do not contradict eachother.
  cosmetics: indentation
  Check AVCodec.supported_samplerates and AVCodec.channel_layouts in avcodec_open().
  aacdec: remove sf_scale and sf_offset.
  aacdec: use a scale of 2 in the LTP MDCT rather than doubling the coefficient table values from the spec.
  Define POW_SF2_ZERO in aac.h and use for ff_aac_pow2sf_tabp[] offsets instead of hardcoding 200 everywhere.
  Large intensity stereo and PNS indices are legal. Clip them instead of erroring out. A magnitude of 100 corresponds to 2^25 so the will most likely result in clipped output anyway.
  qpeg: use reget_buffer() in decode_frame()
  ultimotion: use reget_buffer() in ulti_decode_frame()
  smacker: remove unnecessary call to avctx->release_buffer in decode_frame()
  avparser: don't av_malloc(0).

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-28 04:26:01 +02:00
Stefano Sabatini
e5d80c7b2d mpeg12: terminate mpeg2_video_profiles arrays
Make av_get_profile_name() return NULL if no profile is detected.

Fix trac issue #130, fix crash reading file tek3.m2v.
2011-04-28 01:45:19 +02:00
Carl Eugen Hoyos
5a810f4e27 Return if memory allocation fails. 2011-04-28 00:09:46 +02:00
Baptiste Coudurier
045cc36fe7 100l, change #ifdef to #if 2011-04-27 14:24:36 -07:00
Baptiste Coudurier
46394d39e3 In png decoder, only call png_init_mmx if HAVE_MMX is defined. 2011-04-27 13:59:30 -07:00
Baptiste Coudurier
dbfdb288c1 Set alpha of palettes to 0xff.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-27 21:49:45 +02:00
Baptiste Coudurier
e91946ed23 Rename y400a to gray8a.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-27 21:36:30 +02:00
Michael Niedermayer
52a81cd0e4 Fix add_paeth_prediction_mmx for rgb48
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-27 20:08:37 +02:00
Michael Niedermayer
afd2371d5c merge read and and in add_paeth_prediction
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-27 20:08:37 +02:00
Baptiste Coudurier
6d4c49a2af Move png mmx functions into x86/png_mmx.c, remove them from DSPContext.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-04-27 20:08:09 +02:00
Diego Biurrun
b239526873 vorbisdec: Rename silly "class_" variable to plain "class". 2011-04-27 19:54:55 +02:00
Diego Biurrun
81afa5a274 simple_idct_alpha: Drop some useless casts. 2011-04-27 19:52:48 +02:00
Diego Biurrun
3fd3632ffe Simplify av_log_missing_feature().
Do not print the results of the conditional call to av_log_ask_for_sample()
into the same line as the main output, separate the already long text.
2011-04-27 19:48:58 +02:00
Alexandre Colucci
d6f910ea47 Fix decoding of DXSA subtitles.
These have a DXSA tag and contain alpha in addition to
color values for palette.
2011-04-27 19:45:57 +02:00
Justin Ruggles
8745e9c458 ac3enc: remove check for mismatching channels and channel_layout 2011-04-27 12:57:43 -04:00