summaryrefslogtreecommitdiff
path: root/vp8/common/postproc.c
AgeCommit message (Collapse)Author
2013-07-16use consistent framerate namingJames Zern
s/frame_rate/framerate/g Change-Id: I6fc3e088e419c5f46e3a9390dd8a2cad2677a2fc
2013-03-14Removed shadow warnings : postproc.c decodframe.c threading.cScott LaVarnway
and denoising.c Adding -Wshadow to CFLAGS generated a bunch of warnings. This patch removes these warnings. Change-Id: I434a9f4bfac9ad4ab7d2a67a35ef21e6636280da
2013-01-25Bug fix: error-concealment enabled changed postproc outputScott LaVarnway
When error concealment is enabled, it swaps the mi and prev_mi ptrs after each frame is decoded. The postproc uses the mi ptr for the mode info context. Now the postproc will use the correct mode info context. Change-Id: I537ae5450f319c624999b44525bb52bb30047b7b
2012-12-05Use 'vpx_scale' consistentlyJohann
Change-Id: I178352813d2b8702d081caf405de9dbad9af2cc3
2012-11-15support building vp8 and vp9 into a single libJohn Koleszar
Change-Id: Ib8f8a66c9fd31e508cdc9caa662192f38433aa3d
2012-10-25Use vp8_clear_system_state helper functionJohann
Change-Id: I4dd192c3297e31b8eadd108ca8d0934e58f502f7
2012-10-10post-proc: fix 0 or negative threshold handlingYunqing Wang
If the threshold(limits) <= 0, skipped filtering and copied the frame directly. Also, fixed memory allocation checking. Change-Id: If3d79d5b2bcb71b9777e6eb5cba1384585131e22
2012-10-08post-proc: deblock filter optimizationYunqing Wang
1. Algorithm modification: Instead of having same filter threshold for a whole frame, now we allow the thresholds to be adjusted for each macroblock. In current implementation, to avoid excessive blur on background as reported in issue480(http://code.google.com/p/webm/issues/detail?id=480), we reduce the thresholds for skipped macroblocks. 2. SSE2 optimization: As started in issue479(http://code.google.com/p/webm/issues/detail?id=479), the filter calculation was adjusted for better performance. The c code was also modified accordingly. This made the deblock filter 2x faster, and the decoder was 1.2x faster overall. Next, the demacroblock filter will be modified similarly. Change-Id: I05e54c3f580ccd427487d085096b3174f2ab7e86
2012-09-04Adjusting thresholds in mfqe post-processingDeb Mukherjee
Adjusts some of the qualification thresholds in mfqe to eliminate artifacts due to wrong decisions. Besides, a new qualification criteria is used to disable mfqe if the quality of the previous frame is itself not too good. Change-Id: I4097c20b7fd4fcc60cc3003c1e33e8faae2ff066
2012-06-19Corrected usage of image stridesAdrian Grange
The function vp8_post_proc_down_and_across_c takes the stride of both the src and dst images as parameters, but assumes that they are the same. I modified the code to use the correct strides, as the assembler versions of these functions do. Change-Id: I222715b774cd071b21c15a4b0d2f4aef64a520de
2012-06-11Fix pedantic compiler warningsJohn Koleszar
Allows building the library with the gcc -pedantic option, for improved portabilty. In particular, this commit removes usage of C99/C++ style single-line comments and dynamic struct initializers. This is a continuation of the work done in commit 97b766a46, which removed most of these warnings for decode only builds. Change-Id: Id453d9c1d9f44cc0381b10c3869fabb0184d5966
2012-06-04Remove redundant assignmentJohann
clang complains about self-assignment Change-Id: Iead70eed0a960e84a4b167f67f05b05e2965b3b6
2012-04-19Ports vpx_xcaler to new RTCD methodAttila Nagy
We can get rid of all remaining global initializers now: vp8_scale_machine_specific_config() vp8_initialize() vp8dx_initialize() Change-Id: I2825cea5d1c01ad9f6c45df49a0f86d803bfeb69
2012-03-22Initialize postproc buffer to resolve valgrind warningsDeb Mukherjee
Change-Id: I9a7d40b0eac7200796dbe62e75776b2eb77dfdf6
2012-03-22Miscellaneous changes in mfqe and postproc modulesDeb Mukherjee
Adds logic to disable mfqe for the first frame after a configuration change such as change in resolution. Also adds some missing if CONFIG_POSTPROC macro checks. Change-Id: If29053dad50b676bd29189ab7f9fe250eb5d30b3
2012-03-16Merge "RFC: Reorganize MFQE loops"Johann
2012-03-13Merge "Adds a motion compensated temporal denoiser to the encoder."Jim Bankoski
2012-03-13Adds a motion compensated temporal denoiser to the encoder.Stefan Holmer
Some refactoring in rdopt.c and pickinter.c. Change-Id: I4f50020eb3313c37f4d441d708fedcaf219d3038
2012-03-06RFC: Reorganize MFQE loopsJohann
Break MFQE code into it's own file. It is currently only valid for 16x16 and 8x8 Y blocks. It also filters 4x4 U/V blocks. Refactor filtering and add associated assembly. Limited test cases show --mfqe introduces a penalty of ~20% with HD content. The assembly reduces the penalty to ~15% Change-Id: I4b8de6b5cdff5413037de5b6c42f437033ee55bf
2012-03-05Move SAD and variance functions to commonJohann
The MFQE function of the postprocessor depends on these Change-Id: I256a37c6de079fe92ce744b1f11e16526d06b50a
2012-02-09max_sad check is not always implementedJohann
As an optimization some architectures use the max_sad argument to break out early from the SAD. Pass in INT_MAX instead of 0 to prevent this. Change-Id: I653c476834b97771578d63f231233d445388629d
2012-02-07Align internal mfqe framebuffer dimensionsJohn Koleszar
MFQE postproc crashed with stream dimensions not a multiple of 16. The buffer was memset unconditionally, so if the buffer allocation fails we end up trying to write to NULL. This patch traps an allocation failure with vpx_internal_error(), and aligns the buffer dimensions to what vp8_yv12_alloc_frame_buffer() expects. Change-Id: I3915d597cd66886a24f4ef39752751ebe6425066
2012-01-30RTCD: add variance functionsJohn Koleszar
This commit continues the process of converting to the new RTCD system. Change-Id: Ie5c1aa480637e98dc3918fb562ff45c37a66c538
2012-01-30RTCD: add postproc functionsJohn Koleszar
This commit continues the process of converting to the new RTCD system. Change-Id: If54eb5cb5d1b0cac6c4c0633a9e99c93ca860ba2
2012-01-30RTCD: add recon functionsJohn Koleszar
This commit continues the process of converting to the new RTCD system. Change-Id: I9bfcf9bef65c3d4ba0fb9a3e1532bad1463a10d6
2012-01-27Hook up VP8D_GET_LAST_REF_USEDJohn Koleszar
Commit 892e23a5b introduced support for the VP8D_GET_LAST_REF_USED, but missed the mapping of the control id to the underlying function, so it was unavailable to applications. In addition, the underlying function vp8_references_buffer() is moved from common/postproc.c to decoder/onyxd_if.c as postproc.c is not built in all configurations. Change-Id: I426dd254e7e6c4c061b70d729b69a6c384ebbe44
2012-01-20Merge "Overhauling the thresholds and mixing proportions for mfqe ↵Deb Mukherjee
postprocessor."
2012-01-20Overhauling the thresholds and mixing proportions for mfqe postprocessor.Deb Mukherjee
Makes the thresholds for the multiframe quality enhancement module depend on the difference between the base quantizers. Also modifies the mixing function to weigh the current low quality frame less if the difference in quantizer is large. With the above modifications mfqe works well for both scalable patterns as well as low quality key frames. Change-Id: If24e94f63f3c292f939eea94f627e7ebfb27cb75
2012-01-18Merge "vp8d - valgrind warnings in mb post processor"Jim Bankoski
2012-01-17vp8d - valgrind warnings in mb post processorJim Bankoski
Solved by extending the border in the postproc buffer as necessary Change-Id: Ic3f61397fe5bc8e4db6fc78050b0b160bd0aee86
2012-01-17Modifying the base q propagation in the mfqe post processingDeb Mukherjee
filter in a way such that when there is a single bad frame, the post-processing is applied not only to just that frame but a few subsequent frames as well. Change-Id: Iba5d9896eed77244eb76b4a74692a93f8ecff634
2012-01-10Allowing the mfqe post-processing filter to be used in conjunctionDeb Mukherjee
with deblock or demacroblock filters. When --mfqe is used together with --demacroblock or --deblock, mfqe is applied first and then demacroblock/deblock is applied to the mfqe result. Change-Id: Id83ee01f1b4a33a116f071dcf26d59c7f3497c32
2012-01-10Merge "fix: roundoff initializer is not a constant"John Koleszar
2012-01-10fix: roundoff initializer is not a constantJames Berry
precision used in initialization of roundoff is not a constant updated to use #define MFQE_PRECISION 4 Change-Id: If2fc3d3d633d58a7f4ab34d258c232ec1e5f0a79
2012-01-10vp8d - function to check if a reference frame is used.Jim Bankoski
Change-Id: Id683b4d7f46ffa99145fc4b824c7232ab4182f21
2012-01-05Multiframe quality enhancement postprocessingDeb Mukherjee
Adds a multiframe postprocessing module to enhance the quality of certain frames that are coded at lower quality than preceding frames. The module can be invoked from the commandline by use of the --mfqe option, and will be most beneficial for enhancing the quality of frames decoded using scalable patterns. Uses the vp8_variance_var16x16 and vp8_variance_sad16x16 function pointers to compute SAD and Variance of blocks. Change-Id: Id73d2a6e3572d07f9f8e36bbce00a4fc5ffd8961
2011-09-22Replace vpx_ports/config.h with vpx_config.hAttila Nagy
Just a clean-up. Change-Id: Iea5b6dc925dcfa7db548bc1ab1a13d26ed5a2c9a
2011-06-27Fix after removal of B_MODE_INFOFritz Koenig
Change Ieb746989: Removed B_MODE_INFO missed this. Change-Id: I32202555581cc2a5d45e729c6650ada4d2df55d3
2011-05-02Fix compile error with --enable-postproc-visualizerJohn Koleszar
Typo. Change-Id: I9cc6a4587c3d93c9f0da5e101d376741fc9622a4
2011-04-21Removed dc_diff from MB_MODE_INFOScott LaVarnway
The dc_diff flag is used to skip loopfiltering. Instead of setting this flag in the decoder/encoder, we now check for this condition in the loopfilter. Change-Id: Ie2b9cdf9e0f4e8b932bbd36e0878c05bffd28931
2011-03-17Increase static linkage, remove unused functionsJohn Koleszar
A large number of functions were defined with external linkage, even though they were only used from within one file. This patch changes their linkage to static and removes the vp8_ prefix from their names, which should make it more obvious to the reader that the function is contained within the current translation unit. Functions that were not referenced were removed. These symbols were identified by: $ nm -A libvpx.a | sort -k3 | uniq -c -f2 | grep ' [A-Z] ' \ | sort | grep '^ *1 ' Change-Id: I59609f58ab65312012c047036ae1e0634f795779
2011-01-11Remove unused local variablesHenrik Lundin
Removing unused local variables causing compiler warnings in Visual Studio. Change-Id: I0e2096303be1fdbc01428a6e57cca9796bb32c8a
2010-11-10postproc : Re-work posproc calling to allow more flags.Fritz Koenig
Debugging in postproc needs more flags to allow for specific block types to be turned on or off in the visualizations. Must be enabled with --enable-postproc-visualizer during configuration time. Change-Id: Ia74f357ddc3ad4fb8082afd3a64f62384e4fcb2d
2010-11-04postproc : Update visualizations.Fritz Koenig
Change color reference frame to blend the macro block edge. This helps with layering of visualizations. Add block coloring for intra prediction modes. Change-Id: Icefe0e189e26719cd6937cebd6727efac0b4d278
2010-11-02postproc : Fix display of motion vectors.Fritz Koenig
Split motion vectors were all being treated as 4x4 blocks. Now correctly handle 16x8, 8x16, 8x8, 4x4 blocks. Change-Id: Icf345c5e69b5e374e12456877ed7c41213ad88cc
2010-11-01postproc : Added SPLITMV visualization, fix line constrain.Fritz Koenig
Now draw 16 vectors for SPLITMV mode. Fixed constrain line to block divide by zero issues. Blend block was not centering the shaded area correctly. Change-Id: I1edabd8b4e553aac8d980f7b45c80159e9202434
2010-10-27Eliminate more warnings.Timothy B. Terriberry
This eliminates a large set of warnings exposed by the Mozilla build system (Use of C++ comments in ISO C90 source, commas at the end of enum lists, a couple incomplete initializers, and signed/unsigned comparisons). It also eliminates many (but not all) of the warnings expose by newer GCC versions and _FORTIFY_SOURCE (e.g., calling fread and fwrite without checking the return values). There are a few spurious warnings left on my system: ../vp8/encoder/encodemb.c:274:9: warning: 'sz' may be used uninitialized in this function gcc seems to be unable to figure out that the value shortcut doesn't change between the two if blocks that test it here. ../vp8/encoder/onyx_if.c:5314:5: warning: comparison of unsigned expression >= 0 is always true ../vp8/encoder/onyx_if.c:5319:5: warning: comparison of unsigned expression >= 0 is always true This is true, so far as it goes, but it's comparing against an enum, and the C standard does not mandate that enums be unsigned, so the checks can't be removed. Change-Id: Iaf689ae3e3d0ddc5ade00faa474debe73b8d3395
2010-10-27postproc: Tweaks to line drawing and blending.Fritz Koenig
Turned down the blending level to make colored blocks obscure the video less. Not blending the entire block to give distinction to macro block edges. Added configuration so that macro block blending function can be optimized. Change to constrain line as to when dx and dy are computed. Now draw two lines to form an arrow. Change-Id: Id3ef0fdeeab2949a6664b2c63e2a3e1a89503f6c
2010-10-27vpxdec : Change --pp-debug-info to be a bit field.Fritz Koenig
This allows multiple post processor debug levels to be overlayed. i.e. can show colored reference blocks and visual motion vectors. Change-Id: Ic4a1df438445b9f5780fe73adb3126e803472e53
2010-10-26postproc: Add mode and refrence frame visualizers.Fritz Koenig
Post process option to color the block for either the mode of the macro block, or the frame that the macro block references. Change-Id: Ie498175497f2d20e3319924d352dc4ddc16f4134