summaryrefslogtreecommitdiff
path: root/vp9/encoder/vp9_tokenize.c
AgeCommit message (Collapse)Author
2013-12-04Merge "Cleaning up vp9_entropy.h file."Dmitry Kovalev
2013-12-03Moving eob array to the encoder.Dmitry Kovalev
In the decoder we don't need to save eobs, we can pass eob as an argument. That's why removing eob arrays from VP9Decompressor and TileWorkerData, and moving eob pointer from macroblockd_plane to macroblock_plane. Change-Id: I8eb919acc837acfb3abdd8319af63d1bbca8217a
2013-12-03Cleaning up vp9_entropy.h file.Dmitry Kovalev
Renaming constants for consistency: DCT_VAL_CATEGORY1 => CATEGORY1_TOKEN DCT_VAL_CATEGORY2 => CATEGORY2_TOKEN DCT_VAL_CATEGORY3 => CATEGORY3_TOKEN DCT_VAL_CATEGORY4 => CATEGORY4_TOKEN DCT_VAL_CATEGORY5 => CATEGORY5_TOKEN DCT_VAL_CATEGORY6 => CATEGORY6_TOKEN DCT_EOB_TOKEN => EOB_TOKEN DCT_EOB_MODEL_TOKEN => EOB_MODEL_TOKEN MAX_ENTROPY_TOKENS => ENTROPY_TOKENS Moving constants: INTER_MODE_CONTEXTS from vp9_entropy.h to vp9_blockd.h. EOSB_TOKEN from vp9_entropy.h to vp9_tokenize.h Change-Id: I5fcbf081318e1d365792b6d290a930c6cb0f3fc2
2013-11-27Moving token-encoding related stuff from common to encoder.Dmitry Kovalev
Change-Id: I0e59d320407b3bed0ba3622a7b29975f6fad7ebf
2013-11-26Removing qcoeff buffers from the decoder.Dmitry Kovalev
We only need qcoeff buffers in the encoder. Reducing TileWorkerData struct and VP9Decompressor struct sizes by 24K. Change-Id: Id148868461f7ffa3d3dd634b371503ae9c57e207
2013-11-22Organizing all scan tables into lookup table.Dmitry Kovalev
Change-Id: Ie829ee58a55157e6972c63cebe69a5d0a3221349
2013-11-13Simplifies band-getting with a static arrayDeb Mukherjee
Simplifies the code by implementing band mapping with static arrays. A lot of the code complexity introduced in a previous patch disappears. Change-Id: Ia3fac36e594fb5ad2d55ae141c58bba4c55c2d28
2013-11-12Adding const to tree pointer inside vp9_extra_bit struct.Dmitry Kovalev
Change-Id: I60e02fa3de930ff1f969687ab5af93dee40d86ad
2013-11-12Removes conditional statements from band gettingDeb Mukherjee
Implements scan order to band map with arrays in both the encoder and decoder to remove conditional statements. Encoding seems to be about 1% faster at speed 0, tested on football. Decoding seems to be about 0.5-1% faster on a set of 25 videos. Change-Id: Idb233ca0b9e0efd790e30880642e8717e1c5c8dd
2013-11-06Merge "Removes stack allocation of token_cache"Deb Mukherjee
2013-11-06Removes stack allocation of token_cacheDeb Mukherjee
Removes stack-allocation of token_cache in the tokenize function in the encoder. Change-Id: Ifdbab76dc2b23384da0080d2e9390533e489db8c
2013-11-04Removing old code.Dmitry Kovalev
Change-Id: Ie05cc5e2d8ce12eacdf482a8b75e5a6ce6f59f57
2013-10-16Merge changes I6226456d,I97925178,I766c4b74Guillaume Martres
* changes: Use a separate MODE_INFO stream for each tile column Get rid of "this_mi", use "mi_8x8[0]" everywhere instead Make the static_segmentation feature work again
2013-10-16Get rid of "this_mi", use "mi_8x8[0]" everywhere insteadGuillaume Martres
The only case where they were intentionally pointing to different structures was in mbgraph, and this didn't have the expected behavior because both of these pointers are used interchangeably through the code Change-Id: I979251782f90885fe962305bcc845bc05907f80c
2013-10-16Adding get_band_translate() function.Dmitry Kovalev
Moving code that gets band_translate array from get_scan_and_band() function to get_band_translate() function. Renaming get_scan_and_band() to get_scan(). Change-Id: I43047c205a1ca2a6e24be44db39dc04b7a385008
2013-10-07Removing redundant vp9_pt_energy_class declarations.Dmitry Kovalev
Declaring vp9_pt_energy_class in vp9_entropy.h instead of many external places. Change-Id: I66e8a3fc119a43f88d130d0dae4133c825a047a3
2013-10-04cpplint issues vp9_tokenize.c resolvedJim Bankoski
Change-Id: Id4ec0084641d2ad4def95fb05239455fbc25f9b9
2013-09-27Removing vp9_get_coef_neighbors_handle function.Dmitry Kovalev
Change-Id: I6be72c8b048d1ccc7ef43764cf84c32360098970
2013-09-19Adding get_scan_and_band function.Dmitry Kovalev
Extracting get_scan_and_band function from get_entropy_context to remove duplicated code. Change-Id: I5da1f5a60263017e887da68bc834317b5f084cb2
2013-09-11New mode_info_context storage -- undo revertScott LaVarnway
mode_info_context was stored as a grid of MODE_INFO structs. The grid now constists of pointers to MODE_INFO structs. The MODE_INFO structs are now stored as a stream (decoder only), eliminating unnecessary copies and is a little more cache friendly. Change-Id: I031d376284c6eb98a38ad5595b797f048a6cfc0d
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-27Renaming txfm_size to tx_size.Dmitry Kovalev
Change-Id: I752e374867d459960995b24d197301d65ad535e3
2013-08-27Adding get_entropy_context function.Dmitry Kovalev
Moving common code from encoder and decoder to this function. Change-Id: I60fa643fb1ddf7ebbff5e83b6c4710137b0195ef
2013-08-27Renaming BLOCK_SIZE_TYPE to BLOCK_SIZE in the encoder.Dmitry Kovalev
Change-Id: I62bb07c377f947cb72fac68add7a6b199e42c6b9
2013-08-21Removing a lot of duplicated code.Dmitry Kovalev
Adding set_contexts contexts function and call it instead of set_contexts_on_border. Calling txfrm_block_to_raster_xy to get aoff and loff. Change-Id: I41897e344afd2cae1f923f4fdbe63daccf6fe80e
2013-08-19Passing plane_bsize to foreach_transformed_block_visitor.Dmitry Kovalev
Updating all foreach_transformed_block_visitor functions to work with plane block size instead of general block. Removing a lot of duplicated code. Change-Id: I6a9069e27528c611f5a648e1da0c5a5fd17f1bb4
2013-08-16Merge "Moving from ss_txfrm_size to tx_size."Dmitry Kovalev
2013-08-15Moving from ss_txfrm_size to tx_size.Dmitry Kovalev
Updating foreach_transformed_block_visitor and corresponding functions to accept tx_size instead of ss_txfrm_size. List of functions per file: vp9_decodframe.c decode_block decode_block_intra vp9_detokenize.c decode_block vp9_encodemb.c optimize_block vp9_xform_quant vp9_encode_block_intra vp9_rdopt.c dist_block rate_block block_yrd_txfm vp9_tokenize.c set_entropy_context_b tokenize_b is_skippable Change-Id: I351bf563eb36cf34db71c3f06b9bbc9a61b55b73
2013-08-15Merge "Refactor rd loop for chroma components"Jingning Han
2013-08-15Merge "Moving segmentation struct from MACROBLOCKD to VP9_COMMON."Dmitry Kovalev
2013-08-15Refactor rd loop for chroma componentsJingning Han
This commit makes the rate-distortion optimization search of chroma components consistent across all block sizes. It removes redundant codes. Change-Id: I7e76f54d045e8efdd41d84a164c71f55b484471b
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-15Unify luma and chroma rd-cost estimationJingning Han
This commit unifies the rate-distortion cost calculation process of luma and chroma components. It allows early termination to be enabled later in the rd search loop of chroma components, in consistent with luma pixels. Change-Id: I2e52a7c6496176bf2a5e3ef338d34ceb8aad9b3d
2013-08-15Merge "Renaming in MB_MODE_INFO"Paul Wilkins
2013-08-14foreach_transformed_block_in_plane cleanup, explicit tx_size var.Dmitry Kovalev
Making foreach_transformed_block_in_plane more clear (it's not finished yet). Using explicit tx_size variable consistently instead of (ss_txfrm_size / 2) or (ss_txfrm_size >> 1) expression. Change-Id: I1b9bba2c0a9f817fca72c88324bbe6004766fb7d
2013-08-14Renaming in MB_MODE_INFOPaul Wilkins
The macro block mode info context originally contained an entry for each 16x16 macroblock. In VP9 each entry refers to an 8x8 region not a macro block, so the naming is misleading. This first stage clean up changes the names of 3 entries in the structure to remove the mb_ prefix. TODO clean up the nomenclature more widely in respect of mbmi and bmi. Change-Id: Ia7305c6d0cb805dfe8cdc98dad21338f502e49c6
2013-08-12Entropy context related cleanups.Dmitry Kovalev
Adding set_skip_context() function used from both encoder and decoder. Change-Id: Ia22cfad3211a00a63eb294f64f857b78f4aa9b85
2013-08-09Inlining 16 as a stride for BLOCK_OFFSET macro.Dmitry Kovalev
Change-Id: I7f23d174eb089e5500f268a10db09648634c1b82
2013-08-02Adding is_inter_block function.Dmitry Kovalev
Using it instead of long unclear verbose check "mbmi->ref_frame[0] != INTRA_FRAME". Change-Id: I9c7b4b3797942fa962bf3ba7460fff3084beabe9
2013-08-02Cleaning up set_contexts_on_border function.Dmitry Kovalev
Change-Id: I8f21c18b29f54b277fb1c167f278f109d9f3b996
2013-07-31Adding missing const to vp9_extra_bits array.Dmitry Kovalev
Change-Id: Icd128ab58719e0b9066bdfa66a5d0d427a84d6df
2013-07-29Remove a redundant branching in tokenize_bJingning Han
The tokenize_b function is only called when output flag is on. Hence removing the conditional branch on it therein. Change-Id: Ib709f47f23f39ca05a695faf86fa3377f11f2dd0
2013-07-29Tune tokenization/detokenization flow for speed-upJingning Han
This commit optimizes the tokenization and detokenization operational flow for speed-up. It makes the coding process about 0.3% faster at speed 0. Change-Id: I28008df7482874e4b5f237f2d418ff82a249dd56
2013-07-29Skip redundant tokenization in rd loopJingning Han
This commit makes the encoder skip the redundant tokenization process in the rate-distortion optimization search loop, while updating the entropy contexts accordingly. It makes the speed 0 encoding process about 0.5% faster at no performance change. Change-Id: I34a4155a0b5332afeb45c93a51c7f35a294d685c
2013-07-29Renaming txfm to tx for consistency in some places.Dmitry Kovalev
Change-Id: I2a6a646570e2af66315e7c658d00d99f80c4b127
2013-07-29Renaming TX_SIZE_MAX_SB to TX_SIZES.Dmitry Kovalev
Change-Id: I6aa4191935aa93461a07c41b59fdae1eb5f5f107
2013-07-24Removing CONFIG_BALANCED_COEFTREE experiment.Dmitry Kovalev
Change-Id: I61a8b0101eac3ee2e0621d56151b90c269fd4db4
2013-07-24Adding condition inside get_tx_type_{4x4, 8x8, 16x16}.Dmitry Kovalev
Adding plane type check condition because it was always used outside of get_tx_type_{4x4, 8x8, 16x16}. Change-Id: I02f0bbfee8063474865bd903eb25b54d26e07230
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