It is possible that just extending the RMMuxContext.streams
array would avoid it.
It is also possible that two audio streams will fail to mux
correctly as well, though at least it should not crash for
this reason.
I do not feel like checking either of these.
This patch fixes trac issue #1022 (at least it makes it
exit with a proper error message instead of crashing).
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Also fixes an (incorrect) "control reaches end of non-void function"
warning with some compilers.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
* qatar/master:
h264: new assembly version of get_cabac for x86_64 with PIC
h264: use one table instead of several for cabac functions
h264: (trivial) remove unneeded macro argument in x86/cabac.h
libschroedingerdec: check malloc
segment: reorder seg_write_header allocation
avio: make avio_close(NULL) a no-op
mov: Parse EC3SpecificBox (dec3 atom).
Conflicts:
libavcodec/cabac.c
libavcodec/x86/cabac.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
This adds a hand-optimized assembly version for get_cabac much like the
existing one, but it works if the table offsets are RIP-relative.
Compared to the non-RIP-relative version this adds 2 lea instructions
and it needs one extra register.
There is a surprisingly large performance improvement over the c version (more
so than the generated assembly seems to suggest) just in get_cabac, I measured
roughly 40% faster for get_cabac on a K8. However, overall the difference is
not that big, I measured roughly 5% on a test clip on a K8 and a Core2.
Hopefully it still compiles on x86 32bit...
Now that only one table is used, there's some chance even darwin as compiles
this (apparently the label arithmetic used previously doesn't work if it
involves symbols defined in a different file, thanks to Ronald S. Bultje for
helping me with this).
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
The reason is this is easier for PIC code (in particular on darwin...).
Keep the old names as pointers (static in cabac_functions.h so gcc
knows these are just immediate offsets) so the c code can nicely stay the same
(alternatively could use offsets directly in the functions needing the
tables). This should produce the same code as before with non-pic and better
code (confirmed) with pic.
The assembly uses the new table but still won't work for PIC case.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
not used outside the cabac test functions (which probably means it's
a bad test if it doesn't use the same tables as the real functions?)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
this hunk was merged in 8b97ae64 and cbf767a8 although the check was there a
few lines above since cdced09e. I removed the first check to reduce the differences
to libav.
Signed-off-by: Jean First <jeanfirst@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This adds a hand-optimized assembly version for get_cabac much like the
existing one, but it works if the table offsets are RIP-relative.
Compared to the non-RIP-relative version this adds 2 lea instructions
and it needs one extra register. get_cabac() gets about 40% faster, for
an overall speedup of about 5%.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
The reason is this is easier for PIC code (in particular on darwin...).
Keep the old names as pointers (static in cabac_functions.h so gcc
knows these are just immediate offsets) so the c code can nicely stay the same
(alternatively could use offsets directly in the functions needing the
tables). This should produce the same code as before with non-pic and better
code (confirmed) with pic.
The assembly uses the new table but still won't work for PIC case.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
* qatar/master:
mpegts: Make sure we don't return uninitialized packets
gitignore: replace library catch-all pattern by more specific patterns
Conflicts:
.gitignore
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Skip to parse fields for additional independent substreams and its
associated dependent substreams since libavcodec's E-AC-3 decoder does not
support them yet.
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
Also add internal function ff_null_start_frame_keep_ref().
Fix crash when a following filter (e.g. settb) will unref the reference
passed by start_frame(), and then the reference is accessed in
end_frame() through inlink->cur_buf.