Paul B Mahol
021c0c5f52
avcodec/motion_est: remove unneeded #include, there are no assert() only av_assert*
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Michael Niedermayer
b80106169a
avcodec/motion_est: Set subcmp consistently for H261
...
Fixes Ticket3150
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
b50e003e1c
avcodec/motion_est: use 2x8x8 for interlaced qpel
...
Fixes out of array read
Fixes Ticket4121
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Vittorio Giovara
240b22afe1
motion_est: remove dead code
...
mb_type is initialized to 0 and never updated before the check.
Bug-Id: CID 1238782
10 years ago
Gabriel Dume
f929ab0569
cosmetics: Write NULL pointer equality checks more compactly
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
10 years ago
Diego Biurrun
4fbb62a21b
mpegvideo: Move ME_MAP_* defines to the only place they are used
10 years ago
Diego Biurrun
2d60444331
dsputil: Split motion estimation compare bits off into their own context
10 years ago
Diego Biurrun
c166148409
dsputil: Move pix_sum, pix_norm1, shrink function pointers to mpegvideoenc
11 years ago
Michael Niedermayer
ef8725122d
avcodec/motion_est: Only clip MVs which are used
...
Fixes valgrind mpeg4 failures
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Diego Biurrun
368f50359e
dsputil: Split off quarterpel bits into their own context
11 years ago
Anton Khirnov
a2941c8cb2
lavc: move CODEC_FLAG_MV0 to mpegvideo
11 years ago
wm4
f6774f905f
mpegvideo: operate with pointers to AVFrames instead of whole structs
...
The most interesting parts are initialization in ff_MPV_common_init() and
uninitialization in ff_MPV_common_end().
ff_mpeg_unref_picture and ff_thread_release_buffer have additional NULL
checks for Picture.f, because these functions can be called on
uninitialized or partially initialized Pictures.
NULL pointer checks are added to ff_thread_release_buffer() stub function.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
11 years ago
Diego Biurrun
82bb304801
dsputil: Use correct type in me_cmp_func function pointer
11 years ago
Vittorio Giovara
e0c16e4e32
mpegvideo: move mpegvideo formats-related defines to mpegutils.h
11 years ago
Lukasz Marek
776cda748d
lavc/motion_est: remove unused variable
...
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Diego Biurrun
088f38a4f9
avcodec: Drop unnecessary ff_ name prefixes from static functions
12 years ago
Ronald S. Bultje
f4fed5a2f9
mpegvideo: Use hpeldsp instead of dsputil for half-pel functions
...
This also converts vc1, since that is mpegvideo-based.
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Ronald S. Bultje
4ba5dbc0e4
mpegvideo: use hpeldsp instead of dsputil for half-pel functions.
...
This also converts vc1, since that is mpegvideo-based.
12 years ago
Anton Khirnov
759001c534
lavc decoders: work with refcounted frames.
12 years ago
Anton Khirnov
6e7b50b427
mpegvideo_enc: drop support for reusing the input motion vectors.
...
This misfeature is most likely completely useless and conflicts with
removing the mpegvideo-specific fields from AVFrame. In the improbable
case it is actually useful, it should be reimplemented in a better way.
12 years ago
Diego Biurrun
c242bbd8b6
Remove unnecessary dsputil.h #includes
12 years ago
Diego Biurrun
b5b7b75e91
dsputil: Move get_penalty_factor() to the only place it is used.
12 years ago
Diego Biurrun
25841dfe80
Use ptrdiff_t instead of int for {avg, put}_pixels line_size parameter.
...
This avoids SIMD-optimized functions having to sign-extend their
line size argument manually to be able to do pointer arithmetic.
12 years ago
Anton Khirnov
47318953dd
mpegvideo: remove some unused variables from Picture.
12 years ago
Michael Niedermayer
bbe56bcd6b
motion_est: Limit motion vector search range to MAX_MV
...
Fixes out of array reads with videos exceeding MAX_MV
Found-by: Thierry Foucu
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Diego Biurrun
a0c5917f86
Drop Snow codec
...
Snow is a toy codec with no real-world use and horrible code.
12 years ago
Michael Niedermayer
8328df74f3
motion_est: use av_assert* instead of assert
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
3a48e38ad0
motion_est: more complete SAB diamond size check
...
This makes no difference with the current #defines
Fixes CID732255
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Diego Biurrun
9734b8ba56
Move avutil tables only used in libavcodec to libavcodec.
12 years ago
Michael Niedermayer
d07940b76d
motion_est: switch asserts to av_asserts
...
note, the asserts where enabled by default before this
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Diego Biurrun
1218777ffd
avcodec: Convert some commented-out printf/av_log instances to av_dlog
12 years ago
Diego Biurrun
9c6cf7f2c9
avcodec: Drop silly and/or broken printf debug output
12 years ago
Mans Rullgard
a34a609fc1
motion_est: fix use of inline on extern functions
...
Inline functions declared without extern do not provide an external
definition in standard C99. This code only works because most
compilers do not implement the inline semantics correctly. With a
stricter compiler, linking fails with unresolved references to these
functions.
Declaring the functions extern inline works correctly with some
compilers while some others still fail to create external definitions.
For maximum portability, create a static inline version with an
externally visible wrapper for ff_get_mb_score. ff_epzs_motion_search
is so large that no sane compiler inlines it anyway, so there the
inline keyword can simply be dropped with no effect.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Michael Niedermayer
717a1876d8
motion_est: switch some asserts to av_assert
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Mans Rullgard
0db9eba48c
motion_est: drop inline from sad_hpel_motion_search()
...
This function is only ever called through a function pointer,
so marking it inline makes no sense.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Mans Rullgard
5bf7bc625b
motion_est: remove unused macros
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Mans Rullgard
74f82f92a4
motion_est: remove useless no_motion_search() function
...
At both places this function is called, mb_[xy] == s->mb_[xy]
making the call together with following code equivalent to
simply assigning zeros.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
12 years ago
Diego Biurrun
a92be9b856
Replace memset(0) by zero initializations.
...
Also remove one pointless zero initialization in rangecoder.c.
13 years ago
Diego Biurrun
33ad8c3cab
cosmetics: Remove some unnecessary block braces.
13 years ago
Michael Niedermayer
56bf2c2a19
motion_est: avoid generating motion vectors that point between widthxheight and mb_widthxmb_height.
...
No difference in PSNR or bitrate in the printed precission with the matrix lobby scene at 322x242
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Mans Rullgard
cb668476ab
motion_est: make MotionExtContext.map_generation unsigned
...
The way this value is used, it should be an unsigned type.
While the numerical value has no meaning, unsigned wraparound
is relied upon.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Mans Rullgard
e708afd3c0
motion_est: fix some signed overflows
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Diego Biurrun
473e547e80
motion_est: remove disabled code
14 years ago
Diego Biurrun
657ccb5ac7
Eliminate FF_COMMON_FRAME macro.
...
FF_COMMON_FRAME holds the contents of the AVFrame structure and is also copied
to struct Picture. Replace by an embedded AVFrame structure in struct Picture.
14 years ago
Diego Biurrun
adbfc605f6
doxygen: Consistently use '@' instead of '\' for Doxygen markup.
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
14 years ago
Diego Biurrun
ac4a854811
Remove some non-compiling debug messages.
14 years ago
Maksym Veremeyenko
002e1f1eb3
motion_est: fix ffmpeg compilation with DEBUG defined
...
Remove the problematic av_dlog() call
14 years ago
Stefano Sabatini
ce5e49b0c2
replace deprecated FF_*_TYPE symbols with AV_PICTURE_TYPE_*
14 years ago
Stefano Sabatini
975a1447f7
Replace deprecated FF_*_TYPE symbols with AV_PICTURE_TYPE_*.
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
14 years ago