summaryrefslogtreecommitdiff
path: root/vp9/common/vp9_entropymode.c
AgeCommit message (Collapse)Author
2013-09-09Revert "New mode_info_context storage"James Zern
This reverts commit dae17734ece414091ba1184f7becd0aa6c0004f1 Encode crashes, leaks and increases integer overflow errors. Change-Id: I595aa2649bb8d0b6552ff91652837a74c103fda2
2013-09-06New mode_info_context storageScott LaVarnway
mode_info_context was stored as a grid of MODE_INFO structs. The grid now constists of a pointer to a MODE_INFO struct and a "in the image" flag. The MODE_INFO structs are now stored as a stream, eliminating unnecessary copies and is a little more cache friendly. For the test clips used, the decoder performance improved by ~4.3% (1080p) and ~9.7% (720p). Patch Set 2: Re-encoded clips with latest. Now ~1.7% (1080p) and 5.9% (720p). Change-Id: I846f29e88610fce2523ca697a9a9ef2a182e9256
2013-08-27Merge "Renaming D27 to D207."Dmitry Kovalev
2013-08-23cosmetics: strip 'VP9_' from defines in vp9 only codeJames Zern
Change-Id: I481d9bb2fa3ec72b6a83d5f04d545ad8013f295c
2013-08-23Renaming D27 to D207.Dmitry Kovalev
I've already renamed d27_predictor to d207_predictor but forgot about the corresponding constant. Change-Id: Id312aa80fc5b5a1ab8a709a33418a029552a6857
2013-08-16Merge "Renaming d27 predictor to d207."Dmitry Kovalev
2013-08-15Renaming d27 predictor to d207.Dmitry Kovalev
27 degrees intra predictor is actually 207 degrees, so renaming it. Change-Id: Ife96a910437eb80ccdc0b7a5b7a62c77542ae5be
2013-08-15Moving segmentation struct from MACROBLOCKD to VP9_COMMON.Dmitry Kovalev
VP9_COMMON is the right place to segmentatation struct because it has global segmentation parameters, not something specific to macroblock processing. Change-Id: Ib9ada0c06c253996eb3b5f6cccf6a323fbbba708
2013-08-09Moving loopfilter struct to VP9_COMMON.Dmitry Kovalev
Loop filter configuration doesn't belong to macroblock, so moving it from MACROBLOCKD to VP9_COMMON. Also moving the declaration of loopfilter struct from vp9_blockd.h to vp9_loopfilter.h. Change-Id: I4b3e34be9623b47cda35f9b1f9951f8c5b1d5d28
2013-08-08General code cleanup.Dmitry Kovalev
Removing redundant parenthesis and curly braces. Combining declarations with initializations. Adding useful intermediate variables instead of recalculating expressions every time. Change-Id: I00106f404afd60bfc189905b0fded881684f941a
2013-08-05Changing the order switchable filter enum constants.Dmitry Kovalev
This changeset allows to remove vp9_switchable_interp and vp9_switchable_interp_map arrays and make code much clear. Actually we still have to use these mapping but only inside read_interp_filter_type and write_interp_filter_type functions. Change-Id: I4026c6f8c4acefba6c81421b7bacbaa52cc45f50
2013-08-01Cleanup: replacing xd->seg with seg, and xd->lf with lf.Dmitry Kovalev
Change-Id: I73b59d7699a8e7e7acd3bf8041cb6c98ce9ba4bf
2013-07-30Consistent update for inter_mode probabilities.Dmitry Kovalev
Using inter-mode counts instead of inter-mode-tree branch counts inside FRAME_COUNTS structure. Change-Id: I60dde13af37d06146d7d15543311c1b5044e9e04
2013-07-29Renaming TX_SIZE_MAX_SB to TX_SIZES.Dmitry Kovalev
Change-Id: I6aa4191935aa93461a07c41b59fdae1eb5f5f107
2013-07-25Merge "Removing duplicated code for merging two probabilities."Dmitry Kovalev
2013-07-25Removing vp9_adapt_mode_context function.Dmitry Kovalev
Moving code from vp9_adapt_mode_context to vp9_adapt_mode_probs. Change-Id: I60829c30b28968cd813551ef3a206dfb98d323c9
2013-07-24Removing duplicated code for merging two probabilities.Dmitry Kovalev
Adding common merge_probs and merge_probs2 functions. Changing ints to usigned ints in some places. Change-Id: Icf088ffdea7cf5b95284a128916409bdd53506b0
2013-07-24Inlining vp9_init_mode_contexts function.Dmitry Kovalev
Change-Id: I21ee76bcae101cc9f6ef1d867622e50b7ae565fc
2013-07-23Moving counts from FRAME_CONTEXT to new struct FRAME_COUNTS.Dmitry Kovalev
Counts are separate from frame context. We have several frame contexts but need only one copy of all counts. Change-Id: I5279b0321cb450bbea7049adaa9275306a7cef7d
2013-07-23Removing vp9_is_interpolating_filter array.Dmitry Kovalev
All filters are interpolating now, so we don't need this array, all values from this array are evaluated to true. Change-Id: I9af6d8219ae0eb984063cd15e4e2296374ae4961
2013-07-23Removing MODE_COUNT_TESTING from vp9_entropymode.c.Dmitry Kovalev
Change-Id: I5367bc1d9e660d86879d285a6f146d8a47e62464
2013-07-22Using update_ct and update_ct2 functions for probability update.Dmitry Kovalev
Update logic for both mode and mvref was the same, so using MODE_COUNT_SAT, MODE_MAX_UPDATE_FACTOR, update_ct, update_ct2 for both cases. Removing function update_tx_ct because it was identical to update_mode_ct2. Change-Id: Iff566be27dbd6cde4c2ec04e8d988f207046b8f0
2013-07-20Merge "Removing pre probabilities from FRAME_CONTEXT."Dmitry Kovalev
2013-07-20Merge "Moving all loop filter related variables into new struct."Dmitry Kovalev
2013-07-20Merge "Consistent names for inter mode probabilities and encodings."Dmitry Kovalev
2013-07-19Removing pre probabilities from FRAME_CONTEXT.Dmitry Kovalev
Using cm->frame_contexts[cm->frame_context_idx] as source of previous probabilities. Change-Id: Ie03778acf0e7bebdc3a1f6a51854d4a0712f24a1
2013-07-19Moving all loop filter related variables into new struct.Dmitry Kovalev
Adding loopfilter struct with fields from MACROBLOCKD and VP9Common. Eventually it will be moved to vp9_loopfilter.h for better code structure. Change-Id: Iaf5fb71c33719cdfa1b991f671caf071be9ea035
2013-07-19Fixing problem introduced in one of my previous commits.Dmitry Kovalev
Changing fc->tx_probs back to fc->pre_tx_probs. This change actually affects the bitstream but current test vectors work. Chrome branch is not affected at all. Broken since: cc662dd Adding struct tx_probs and struct tx_counts to cleanup the code. Change-Id: I36dd4b3678e902e10aba8dd49b0012eb558c209d
2013-07-19Renaming TXFM_MODE to TX_MODE (like TX_SIZE, TX_TYPE).Dmitry Kovalev
Moving TX_MODE enum to vp9_enums.h. Renaming txfm_mode variables to tx_mode. Change-Id: I459d1af6dd928ce7fccdf8ce30b6f1ca057bef92
2013-07-19Consistent names for inter mode probabilities and encodings.Dmitry Kovalev
Renaming vp9_sb_mv_ref_tree to vp9_inter_mode_tree, and vp9_sb_mv_ref_encoding_array to vp9_inter_mode_encodings. Change-Id: I0e91fbf81350d3ec5a2599064c74089b5d06133a
2013-07-17Removing kf_{y, uv}_mode_prob arrays from VP9Common.Dmitry Kovalev
These arrays have constant values (no any updates). Removing two corresponding memcpy calls. Making a little cleanup in vp9_entropymode.h as well: removing redundant 'extern' keyword and moving all function declarations at the end. Change-Id: Ia16b38b46aec2e2500f5df29c40a297ae241dede
2013-07-16Moving vp9_kf_default_bmode_probs to vp9_entropymode.c.Dmitry Kovalev
Removing vp9_modelcontext.c. Change-Id: If2316c58dead2708d9f95b52d9494ba4c1dd7427
2013-07-12Using vp9_copy and vp9_zero instead of custom code.Dmitry Kovalev
Change-Id: Id9b6ceeddca3f9b34bfada5c499b1e7a2f42c30b
2013-07-12Adding struct tx_probs and struct tx_counts to cleanup the code.Dmitry Kovalev
Also removing unused declarations from vp9_entropymode.h file. Change-Id: Ib9c5826db3584a32f6bb3297a76c522b99d83402
2013-07-11Moving segmentation related vars into separate struct.Dmitry Kovalev
Adding segmentation struct to vp9_seg_common.h. Struct members are from macroblockd and VP9Common structs. Moving segmentation related constants and enums to vp9_seg_common.h. Change-Id: I23fabc33f11a359249f5f80d161daf569d02ec03
2013-07-03Adding update_tx_ct function, removing duplicated code.Dmitry Kovalev
Change-Id: I8882fe3cd247a5a8304ab8ab2ee9abdb92830133
2013-07-01Removing vp9_modecont.{h, c}.Dmitry Kovalev
Moving vp9_default_inter_mode_probs array to vp9_entropymode.c. Change-Id: I88ebda86ccc07f2a43c6c01d4b37898214cfb6de
2013-06-27Decoder's code cleanup.Dmitry Kovalev
Using vp9_set_pred_flag function instead of custom code, adding decode_tokens function which is now called from decode_atom, decode_sb_intra, and decode_sb. Change-Id: Ie163a7106c0241099da9c5fe03069bd71f9d9ff8
2013-06-10New probs for filters/tx_size and a few othersDeb Mukherjee
* New probs for subpel filters/tx_count * Makes a change to not reset to defaults for the tx_size probs if an intermediate frame reverts to using a fixed tx_size. * A few updates to the parameters for backward adaptation for mode/mv * some cosmetic cleanups derf300: +0.06% Change-Id: I22994d659bc31ca7a4fc8820fde24001e64a2920
2013-06-10Merge "Implement intra-coded frames" into experimentalAdrian Grange
2013-06-10Cosmetic cleanups of filtersDeb Mukherjee
No bitstream change. Removes unused filters and the code for the case of 2 switchable filters; also changes the 8tap-smooth filter coefficients for integer shifts to be interpolating to be consistent with the way it is implemented currently. Change-Id: I96c542fd8c06f4e0df507a645976f58e6de92aae
2013-06-10Implement intra-coded framesAdrian Grange
Implements ability to signal and decode frames that are encoded using only intra coding modes. Only the decode side has been implemented here. Change-Id: I53ac6a8d90422cd08ba389e5236e15b45f9e93de
2013-06-09Merge "New comp_inter defaults." into experimentalRonald S. Bultje
2013-06-08Merge "New default tables" into experimentalRonald S. Bultje
2013-06-08New comp_inter defaults.Ronald S. Bultje
It seems like I inverted the meaning of the contexts by accident? Change-Id: Iafb2346d9933930949578342b84519b719dd5dd3
2013-06-08New default tablesRonald S. Bultje
Change-Id: Ice8c73a2a843113877b8f8ed78737a1442c25ced
2013-06-08TX_SIZE contexts simplification.Deb Mukherjee
Reduces TX_SIZE contexts to 2 for each kind. The code is cleaner and there is hardly any performance difference with more than two contexts. Results: almost neutral Change-Id: I17656bd6db76224ae2856adf882504560e7dbaa4
2013-06-07Coding tx-size selection by use of spatial contextDeb Mukherjee
Adds coding of transform size within a frame by use of context of transform sizes selected in left and above blocks. Also incorporates code for generating stats. TODO: generate and incorporate new default stats Change-Id: I6a7af099f6ad61d448521d9a51167aedaf638ed6
2013-06-07Cleans up mbskip encodingDeb Mukherjee
Refactors mbskip coding to be compatible with coding of the rest of the symbols. Adds forward/backward adaptation and removes a lot of the legacy code. Results: fast50: +1.6% derfraw300: +0.317% Change-Id: I395a2976d15af044d3b8ded5acfa45f6f065f980
2013-06-07Merge "Remove two un-used entries in mode_lf_delta[]" into experimentalYaowu Xu