summaryrefslogtreecommitdiff
path: root/vp9/encoder/vp9_encoder.c
AgeCommit message (Collapse)Author
2014-11-06Modify the frame context memory deallocationYunqing Wang
This patch was to fix the vpxdec fuzzing3 test failure. When an error occurs, setjmp() is invoked, which calls the decoder removing routine. In multiple thread situation, other threads could try to access the frame context memory that is already deallocated, thus causing a segfault. An invalid unit test was added for this issue. Change-Id: Ida7442154f3d89759483f0f4fe0324041fffb952
2014-11-05Merge "Totally remove prev_mi in VP9 decoder."hkuang
2014-11-05Totally remove prev_mi in VP9 decoder.hkuang
This will save the memory and improve the decode speed due to removing unnecessary memset of big prev_mi array for all the key frames. Decoding a all key frames 1080p video shows speed improve around 2%. Change-Id: I6284a445c1291056e3c15135c3c20d502f791c10
2014-11-04Merge "[spatial svc] Make spatial svc working for one pass rate control"Minghai Shang
2014-11-04[spatial svc] Make spatial svc working for one pass rate controlMinghai Shang
Change-Id: Ibd9114485c3d747f9d148f64f706bf873ea473ac
2014-11-02Allow disable of refresh golden for more than 1 layer encoding.Marco
The current logic was allowing for disabling golden refresh only for two pass svc encoding. This change disables it as long as more than 1 layer encoding is used (for example temporal layers under 1pass CBR). Change-Id: I4dc5204a7ad365c821ec7963e93b59da82e1826b
2014-10-31Bind motion vectors with frame buffer structure.hkuang
This will save a lot of memory for decoder due to removing of prev_mi, but prev_mi is still needed in encoder. So this will increase a little bit memory for encoder. Change-Id: I24b2f1a423ebffa55a9bd2fcee1077dac995b2ed
2014-10-24Merge "Tile based adaptive mode search in RD loop"Jingning Han
2014-10-24Tile based adaptive mode search in RD loopJingning Han
Make the spatially adaptive mode search in rate-distortion optimization loop inter tile independent. Experiments suggest that this does not significantly change the coding staticstics. Single tile, speed 3: pedestrian_area 1080p 1500 kbps 59192 b/f, 40.611 dB, 101689 ms blue_sky 1080p 1500 kbps 58505 b/f, 36.347 dB, 62458 ms mobile_cal 720p 1000 kbps 13335 b/f, 35.646 dB, 45655 ms as compared to 4 column tiles, speed 3: pedestrian_area 1080p 1500 kbps 59329 b/f, 40.597 dB, 101917 ms blue_sky 1080p 1500 kbps 58712 b/f, 36.320 dB, 62693 ms mobile_cal 720p 1000 kbps 13191 b/f, 35.485 dB, 45319 ms Change-Id: I35c6e1e0a859fece8f4145dec28623cbc6a12325
2014-10-24Merge "Enable dual arf with constant q."Paul Wilkins
2014-10-23Move frame re-sizing into the recode loopAdrian Grange
The point at which frames are scaled to their coded dimensions is moved into the re-code loop. This is in preparation for a further patch that will add logic into the re-code loop to reduce the coded frame size if the encoder is struggling to hit the target data rate at the native frame size. Change-Id: Ie4131f5ec6fb93148879f6ce96123296442bf2d1
2014-10-23Enable dual arf with constant q.Paul Wilkins
Add second level arf Q adjustment when using dual arfs in constant Q mode. Previously in constant Q mode enabling dual arf hurt by ~5% but with this change the average benefit is ~1-1.5% with some mid range data points up ~10%. Note however that it still hurts on some clips including some very low motion show content. Change-Id: I5b7789a2f42a6127d9e801cc010c20a7113bdd9b
2014-10-23Merge "Initialization bug for multi arf."Paul Wilkins
2014-10-22Merge "vp9_ethread: allocate frame contexts outside VP9_COMMON struct"Yunqing Wang
2014-10-22vp9_ethread: allocate frame contexts outside VP9_COMMON structYunqing Wang
This patch allocated frame contexts outside VP9_COMMON. This allows multiple threads to share the same copy of frame contexts, and reduces the overhead. It also guarantees the correct update of these contexts during bitstream packing. This patch doesn't change encoding result. Change-Id: Ic181a2460b891d1d587278a6d02d8057b9dbd353
2014-10-22Initialization bug for multi arf.Paul Wilkins
Moved erroneous reset of cpi->multi_arf_last_grp_enabled. Change-Id: Ibb0b96f6ed1d5eeb575a3b1c798e0fe2ee651d06
2014-10-20Extend --auto-alt-ref so it can enable multi-alt ref.Paul Wilkins
Extend --auto-alt-ref from parameter so we can use it to turn multi-arf on and off from the command line. For now the range is 0-off, 1-on, 2-multi-arf on. Rename play_alternate to enable_auto_arf Change-Id: Id7b64407cfbe76ba0090a83b588a03e22a240386
2014-10-16[spatial svc]Another workaround to avoid using prev_miMinghai Shang
We encode a empty invisible frame in front of the base layer frame to avoid using prev_mi. Since there's a restriction for reference frame scaling factor, we have to make it smaller and smaller gradually until its size is 16x16. Change remerged. Change-Id: I9efab38bba7da86e056fbe8f663e711c5df38449
2014-10-16Revert "Move input frame scaling into the recode loop"Paul Wilkins
This reverts commit 452dc21500a2339ee685cb28efbd2af1b856ea12. This change has introduced a significant quality regression on content with forced key frames. (e.g. the YT and yt-hd set). It is most noticeable in static content where the kf bits dominate. Here, despite key frames being apparently coded at the same Q, there is a drop in all metrics of ~20% (e.g clXR and BFa0). Change-Id: Iba14cc61778c0846fa0a59c33c55a9fc49512cb4
2014-10-16Revert "[spatial svc]Another workaround to avoid using prev_mi"Paul Wilkins
This reverts commit c113457af9880b8e15a36cdaabfd414d1c245693. Temporary revert to allow clean revert of another commit. Change-Id: Ia9b7b755e6c48e1b6e383329f121fef175a24b27
2014-10-14[spatial svc]Another workaround to avoid using prev_miMinghai Shang
We encode a empty invisible frame in front of the base layer frame to avoid using prev_mi. Since there's a restriction for reference frame scaling factor, we have to make it smaller and smaller gradually until its size is 16x16. Change-Id: I60b680314e33a60b4093cafc296465ee18169c19
2014-10-14Merge "Move input frame scaling into the recode loop"Adrian Grange
2014-10-14Remove an unneeded function callYunqing Wang
set_tile_limits() is called in vp9_change_config() already. Change-Id: I91c3a0df2c1c7fd7e71546d8f51fd5b65838a7da
2014-10-14Move input frame scaling into the recode loopAdrian Grange
Move the point at which input frames are scaled into the recode loop. This will allow us to change the coded frame size dynamically in response to previous attempts to encode the frame at a higher resolution. A following patch will implement a scheme for resizing the frame in the recode loop. Change-Id: I6a59c02d6ac1626512edad6de8b60063b79433e6
2014-10-09Rename highbitdepth functions to use highbd prefixDeb Mukherjee
Uses highbd_ prefix convention consistently. Change-Id: I58f7f799a7ff8e32701bcd71c955bcf1cdd4581e
2014-10-07Resolves some static analysis / undefined warningsDeb Mukherjee
Also fixes a case of distortion becoming negative and messing up the RDCOST computation. Change-Id: Id345af9e8dfff31ade622be5756e51f2cdface53
2014-10-02Merge "Make iscan and scan neighbor arrays static const."Yaowu Xu
2014-10-02Make iscan and scan neighbor arrays static const.Yaowu Xu
This commit changes the tables to be read only, which fixes issue #866 Change-Id: I85bbe03f9d344f50570f8c1c61699bdc5cee248f
2014-10-02Fix subsampling check for images 1 pixel wide/tallAlex Converse
Change-Id: I0e262ede7eb4a4ae0c86181922d744e542e93350
2014-10-01High-bitdepth bugfixesDeb Mukherjee
Miscellaneous bug-fixes for high bitdepth functionality. With this patch, high bit-depth profiles become mostly functional, except for an intermittent assert failure issue that is being tracked. Change-Id: I6a7fcbdcf1e5b09842e88535f8442d2e1230748c
2014-09-30Merge "Skip the partition search for still frames"Yunqing Wang
2014-09-30Misc. high-bit-depth fixesDeb Mukherjee
Change-Id: Ie9fb6a4078eb6a3fb7c4ff1453831ab9afe23121
2014-09-26Skip the partition search for still framesYunqing Wang
This patch re-enabled the feature in Pengchong's patch (commit 12861260732a4fd5f6b667ce9d5105dc9b606eda). Originally, it was turned on while use_lastframe_partitioning > 0(not used anymore). Now it was added as a feature, and turned on while speed >= 2. As described in the original patch, this feature helps speed up the slideshows in YouTube. Change-Id: I1b0f18d65da1ee1c8d1e117dabba910c5207c471
2014-09-24Merge "Fix build issue with stats enabled."Paul Wilkins
2014-09-24Fix build issue with stats enabled.Paul Wilkins
Compiler build issue when output stats enabled. Change-Id: I7b5409108f3f27ba61b0241b9340b412683eff45
2014-09-23Adds high bit-depth frame resize functionsDeb Mukherjee
Change-Id: I35b015a759325d72d0da427c61a09f19f8e69697
2014-09-23Adds high bit-depth psnr/sse functionsDeb Mukherjee
Also adds some miscellaneous high bit-depth setup functions. Change-Id: I66488b08a5a2a8cb9518ca10497cf1c1501ceded
2014-09-22Merge "[spatial svc] Remove vpx_svc_parameters_t and the loop that sets it ↵Minghai Shang
for each layer"
2014-09-22Adaptive mode search schedulingJingning Han
This commit enables an adaptive mode search order scheduling scheme in the rate-distortion optimization. It changes the compression performance by -0.433% and -0.420% for derf and stdhd respectively. It provides speed improvement for speed 3: bus CIF 1000 kbps 24590 b/f, 35.513 dB, 7864 ms -> 24696 b/f, 35.491 dB, 7408 ms (6% speed-up) stockholm 720p 1000 kbps 8983 b/f, 35.078 dB, 65698 ms -> 8962 b/f, 35.054 dB, 60298 ms (8%) old_town_cross 720p 1000 kbps 11804 b/f, 35.666 dB, 62492 ms -> 11778 b/f, 35.609 dB, 56040 ms (10%) blue_sky 1080p 1500 kbps 57173 b/f, 36.179 dB, 77879 ms -> 57199 b/f, 36.131 dB, 69821 ms (10%) pedestrian_area 1080p 2000 kbps 74241 b/f, 41.105 dB, 144031 ms -> 74271 b/f, 41.091 dB, 133614 ms (8%) Change-Id: Iaad28cbc99399030fc5f9951eb5aa7fa633f320e
2014-09-19Remove mi_grid_* structures.hkuang
mi_grid_* are arrays of pointer to pointer. They save the pointers that point to the MIs in cm->mi. But they are unnecessary and complicated. The original goal was to remove MODE_INFO_t copy. But with an extra MODE_INFO_t pointer inside MODE_INFO_t, same goal could be achieved. This commit totally removes the mi_grid_* structures. But there are still many dummy MODE_INFO_t inside cm->mi which are a waste of memory. Next commit will do on-demand MODE_INFO_t allocation in order to save these memories. Change-Id: I3a05cf1610679fed26e0b2eadd315a9ae91afdd6
2014-09-18[spatial svc] Remove vpx_svc_parameters_t and the loop that sets it for each ↵Minghai Shang
layer vpx_svc_parameters_t contains id, resolution and min/max qp for each spatial layer. In this change we will use extra config to send min/max qp and scaling factors, then calculate layer resolution inside encoder. Change-Id: Ib673303266605fe803c3b067284aae5f7a25514a
2014-09-18Adds high bitdepth convolve, interpred & scalingDeb Mukherjee
Change-Id: Ie51c352a6b250547207cbc1ebba833a01ed053e3
2014-09-16Adds high bitdepth quantization functionsDeb Mukherjee
Adds various high bitdepth quantization functions. Change-Id: I36fc0bf75a1bd15128ed271df8723de0ac134b0c
2014-09-15Move call to vp9_rc_get_second_pass_params().Paul Wilkins
Call to vp9_rc_get_second_pass_params() moved from Pass2Encode() to earlier in vp9_get_compressed_data(), to ensure that two pass stats and parameters are available before decisions such as frame scaling. Change-Id: If21537f0073919b04696a7d5e9aac78e23d76f39
2014-09-12Merge "[spatial svc] Output psnr for all layers in one packet."Minghai Shang
2014-09-11Adds high bitdepth transform functions and testsDeb Mukherjee
Adds various high bitdepth transform functions and tests. Much of the changes are related to using typedefs tran_low_t and tran_high_t for the final transform cofficients and intermediate stages of the transform computation respectively rather than fixed types int16_t/int. When vp9_highbitdepth configure flag is off, these map tp int16_t/int32_t, but when the flag is on, they map to int32_t/int64_t to make space for needed extra precision. Change-Id: I3c56de79e15b904d6f655b62ffae170729befdd8
2014-09-11[spatial svc] Output psnr for all layers in one packet.Minghai Shang
Change-Id: I97d0cf095e9cfefdfa0f65eb5e96d6848cc9ffca
2014-09-08Fix VS build issue.Paul Wilkins
Compile fails when CONFIG_INTERNAL_STATS flag is set. Change-Id: Iba7701c058169ca3fc0b9008619ac55a1fe1a8b6
2014-09-05Merge "Initializing intra modes without vpx_once()."Dmitry Kovalev
2014-09-04Merge "Removing local set_speed_features() function."Dmitry Kovalev