summaryrefslogtreecommitdiff
path: root/vp9/vp9_cx_iface.c
AgeCommit message (Collapse)Author
2022-06-17vp9_cx_iface: set default cpu_used=5 w/CONFIG_REALTIME_ONLYJames Zern
this avoids a crash if cpu-used is not explicitly set as there are some (unnecessary) checks against use_nonrd_pick_mode which would cause encoding to be skipped if the old default of 0 were used Bug: webm:1773 Change-Id: I62fba5fb51d8afa422689b7de3f03e8f7570e50b Fixed: webm:1773
2022-05-31vp9e_set_config: setjmp before calling vp9_change_configJames Zern
vp9_change_config may call functions that perform allocations which expect failures detected by CHECK_MEM_ERROR to not return. Change-Id: I1dd1eca9c661ed157d51b4a6a77fc9f88236d794
2022-03-30L2E: Make SimpleEncode take vp9 level as an inputCheng Chen
Level conformance is standadized in vp9. If a specific target level is set, the vp9 encoder is required to produce conformant bitstream with limit on frame size, rate, min alt-ref distance, etc. This change makes the SimpleEncode environment take the target level as an input. To make existing tests pass, we set the level to 0. Change-Id: Ia35224f75c2fe50338b5b86a50c84355f5daf6fd
2022-02-05Update error messages in validate_img()Wan-Teh Chang
Change-Id: I4aa6d2e16e077d29e4e9eabfc7056fcfed6786d6
2021-12-09vp[89]_initalize_enc(): protect against multiple invocationsJames Zern
this removes the burden from callers; the rtcd functions are left with a mostly redundant (outside of tests) once() as top-level functions should ensure their constraints are met Change-Id: I5bdbcfa4671c6a1492cfe9c7d886c361c26caaa9
2021-11-17vp9 encoder: fix some integer overflowsFyodor Kyslov
cap bitrate to 1000Mbps, change bitsaving budget to int64_t this make test coverage for 2048x2048 - same as for vp8 Bug: webm:1749 Fixed: webm:1749 Change-Id: Ic58d73cb7529b0826d1f501ad09af8e80f706a6e
2021-07-26Merge "Remove unused old FP_MB_STATS code" into mainYunqing Wang
2021-07-23Remove unused old FP_MB_STATS codeYunqing Wang
Change-Id: I78ac1f8ce1598de295efd2ac1fe8244072d9b501
2021-07-22Add control to get QP for all spatial layersJerome Jiang
Change-Id: I77a9884351e71649c8f8632293d9515c60f6adbc
2021-07-13Add codec control for rtc external ratectrl libJerome Jiang
This will do 3 things: Turn off low motion computation Turn off gf update constrain on key frame frequency turn off content mode for cyclic refresh Those are used to verify the external ratectrl lib works as expected. Change-Id: Ic6e61498de82d6b3973e58df246cf5e05f838680
2021-07-02Add codec control to get loopfilter levelJerome Jiang
Change-Id: I70d417da900082160e7ba53315af98eceede257c
2021-06-21Add use_simple_encode_api to oxcfAngie Chiang
Use this flag to change the encoder behavior when SimpleEncode APIs are used BUG=webm:1733 Change-Id: I9f0852a03ff99faa01cdd8eee8ab71718cc58632
2021-04-26Add limits to Vizier input parameters.Paul Wilkins
Imposed provisional upper and lower limits to each parameter that can be adjusted in the Vizier ML experiment. Also in some cases applied secondary limits on on the range of the final "used" values. Defaults and limits may well require further tuning after subsequent rounds of experimentation. Re-factor get_sr_decay_rate(). Change-Id: I28e804ce3d3710f30cd51a203348e4ab23ef06c0
2021-04-20Further normalization of Vizier parameters.Paul Wilkins
Further changes to normalize the Vizier command line parameters. The intent is that the default behavior for any given parameter is signaled by the value 1.0 (expressed on the command line as a rational). The final values used in the two pass code are obtained by multiplying the passed in factors by a default values if use_vizier_rc_params is 1. Where use_vizier_rc_params is 0 the values are explicitly set to the defaults. This patch also changes the default value of each parameter to 1.0 even if not set explicitly. This should ensure safe /default behavior if the user sets use_vizier_rc_params to 1 but does not set all the the individual parameters. Change-Id: Ied08b3c22df18f42f446a4cc9363473cad097f69
2021-04-14Pass vizier rd parameter valuesCheng Chen
Add command line options for three rd parameters. They are controlled by --use_vizier_rc_params, together with other rc parameters. If not set from command line, current default values will be used. Change-Id: Ie1b9a98a50326551cc1d5940c4b637cb01a61aa0
2021-04-13Set vizier rc parametersCheng Chen
If pass --use-vizier-rc-params=1, the rc parameters are overwittern by pass in values. It --use-vizier-rc-params=0, the rc parameters remain the default values. Change-Id: I7a3e806e0918f49e8970997379a6e99af6bb7cac
2021-04-06Change zm_factor for Vizier.Paul Wilkins
Changes the exposed zm_factor parameter. This patch alters the meaning of the zm_factor parameter that will be exposed for the Vizier project. The previous power factor was hard to interpret in terms of its meaning and effect and has been replaced by a linear factor. Given that the initial Vizier results suggested a lower zero motion effect for all formats, the default impact has been reduced. The patch as it stands gives a modest improvement for PSNR but is slightly down on some sets for SSIM (overall psnr, ssim % bdrate change: -ve is better) lowres -0.111, 0.001 ugc360p -0.282, -0.068 midres2 -0.183, 0.059 hdres2 -0.042, 0.172 Change-Id: Id6566433ceed8470d5fad1f30282daed56de385d
2021-04-05Pass vizier rc parameter values with range checkCheng Chen
This is similar to the change: https://chromium-review.googlesource.com/c/webm/libvpx/+/2771081 Which fails libvpx nightly test. Here we add range check to get rid of the warning of "divided by zero". BUG=webm:1723 Change-Id: I7712efe7abd4b11cdb725643d51fd1c0a300d924
2021-04-02Revert "Pass vizier rc parameter values from command line to twopass"Tom Finegan
This reverts commit f32829a2e5db3cd1624e8a7a530af84c382762ef. BUG=webm:1723 Change-Id: I866cdf288f9873c350b32091515a6d5f4df362a3
2021-03-29Pass vizier rc parameter values from command line to twopassCheng Chen
Change-Id: I02eabeccf2fe4604875820d38e23c2586a63e290
2021-03-29Add command line options for a few rc parametersCheng Chen
These rate control parameters are for the Vizier experiment. They are defined as rational numbers. Change-Id: I23f382dd49158db463b75b5ad8a82d8e0d536308
2021-01-20Handle vp9_extrc functions' return status properlyAngie Chiang
Bug: webm:1716 Change-Id: I204cd3ab35b493759808500b799da3b9e55686d4
2020-11-13Merge "vp9: Allow for disabling loopfilter per spatial layer"Marco Paniconi
2020-11-12vp9: Allow for disabling loopfilter per spatial layerMarco Paniconi
For SVC: add parameter to the control SET_SVC_PARAMS to allow for disabling the loopfilter per spatial layer. Note this svc setting will override the setting via VP9E_SET_DISABLE_LOOPFILTER (which should only be used for non-SVC). Add unittest to handle both SVC (spatial or temporal layers) and non-SVC (single layer) case. Change-Id: I4092f01668bae42aac724a6df5b6f6a604337448
2020-10-19Add unit test for vp9_ext_ratectrlAngie Chiang
Fix three bugs along the way. 1) Call vp9_extrc_send_firstpass_stats() after vp9_extrc_create() 2) Pass in model pointer in vp9_extrc_create() 3) Free frame_stats buffer in vp9_extrc_delete() Bug: webm:1707 Change-Id: Ic8bd62c7b4ebd85a7479ae5e4c82d7f6059d782f
2020-10-09Add vp9_extrc_init/create/deleteangiebird
Change-Id: I9fcb9f4cc5c565794229593fadde87286fcf0ffd
2020-10-09Add callback functions for external_rate_controlangiebird
Change-Id: I20a1179a2131d2cd069dae9076aa2c18b80784f3
2020-10-02Add codec control for external rate control libangiebird
VP9E_SET_EXTERNAL_RATE_CONTROL One can assign an external library using the control flag, VP9E_SET_EXTERNAL_RATE_CONTROL. The args alongside the control flag should be of type char**. args[0]: char* points to the path of rate control library args[1]: char* points to the config of the rate control library. Change-Id: Iae47362cdfafa00614bac427884bffcf6944c583
2020-10-02Add SetEncodeConfig and DumpEncodeConfigsangiebird
Change-Id: Ie6864b1133c26021d9c4883df033ecd2969585ed
2020-10-02Add codec control to disable loopfilter for vp9Jerome Jiang
Change-Id: I6d693e84570c353d20ec314acea43363956c0590
2020-08-25vp9-rtc: Add control to disable maxq on overshootMarco Paniconi
Add encoder control to disable feature to increase Q on overshoot detection, for CBR. Default (no usage of the control) means the feature is internally enabled. Add the control to the sample encoders, but keep it disabled as default (set to 0, so feature is on). Change-Id: Ia2237bc4aaea9770e5080dab20bfff9e3fd09199
2020-07-15Add SetEncodeSpeed() to SimpleEncodeangiebird
Change-Id: I2fcf37045a96bb101de3359e2e69dcc266c1dc10
2020-07-09Cap target bitrate to raw rate internallyJerome Jiang
BUG=webm:1685 Change-Id: Ida72fe854fadb19c3745724e74b67d88087eb83c
2020-06-02Add NV12 supportJerome Jiang
Change-Id: Ia2a8221a156e0882079c5a252f59bc84d8f516b1
2020-04-24Revert "Revert "Remove RD code for CONFIG_REALTIME_ONLY in vp9.""Jerome Jiang
Under CONFIG_REALTIME_ONLY flag, map speed < 5 to speed 5. Bug: webm:1684 This reverts commit 85cb983682fe9ca14fd302b50d27d762da05d665. Change-Id: I67b7ed37e8b74417db310ea0c817d3c5a5de9e44
2020-02-18Cap delta_q_uv to -15..15Jerome Jiang
only 4 bits in bitstream Change-Id: I338fe54475e094ee5e556467e0b66c982bb560fa
2020-02-05Add coded_frame to EncodeFrameResultsangiebird
This coded_frame represents the raw coded image. Change-Id: Iea439da2f9e84c4507b082d77ebaac49bfd74fff
2020-01-28Fix initialization of delta_q_uvJerome Jiang
Change-Id: If778c6534a5e68a9bcd5974f778e97e1c5cc89ee
2020-01-22Merge "vp9: fix control for delta qp for uv"Jerome Jiang
2020-01-21vp9: fix control for delta qp for uvJerome Jiang
It could be overwritten by other controls. Change-Id: I86b430842d6819d3858bc65e728f7cb2bd471284
2020-01-17add static_assert.hJames Zern
unify COMPILE_TIME_ASSERT definitions and rename to VPX_STATIC_ASSERT Change-Id: Id51150c204e0c4eaf355ee45b20915113209d524
2020-01-17vp9: add delta q for uv channel. add tests.Jerome Jiang
Add control for delta q for uv. 0 by default. Change-Id: Ib8ed160b1a5c9a61ba15985076f6c6f121477103
2019-11-22Change vp9_get_encoder_config.angiebird
Add vp9_dump_encoder_config for config comparison. This function will generate the same VP9EncoderConfig used by the vpxenc command given below. The configs in the vpxenc command corresponds to parameters of vp9_get_encoder_config() as follows. WIDTH: frame_width HEIGHT: frame_height FPS: frame_rate BITRATE: target_bitrate INPUT, OUTPUT, LIMIT will not affect VP9EncoderConfig vpxenc command: INPUT=bus_cif.y4m OUTPUT=output.webm WIDTH=352 HEIGHT=288 BITRATE=600 FPS=30/1 LIMIT=150 ./vpxenc --limit=$LIMIT --width=$WIDTH --height=$HEIGHT --fps=$FPS --lag-in-frames=25 \ --codec=vp9 --good --cpu-used=0 --threads=0 --profile=0 \ --min-q=0 --max-q=63 --auto-alt-ref=1 --passes=2 --kf-max-dist=150 \ --kf-min-dist=0 --drop-frame=0 --static-thresh=0 --bias-pct=50 \ --minsection-pct=0 --maxsection-pct=150 --arnr-maxframes=7 --psnr \ --arnr-strength=5 --sharpness=0 --undershoot-pct=100 --overshoot-pct=100 \ --frame-parallel=0 --tile-columns=0 --cpu-used=0 --end-usage=vbr \ --target-bitrate=$BITRATE -o $OUTPUT $INPUT Change-Id: If7fd635d6f3fad4e6199a4fbcd556323efc1c250
2019-11-18Add frame_type and show_idx to EncodeFrameResultangiebird
Let vp9_get_compressed_data update ENCODE_FRAME_RESULT, a C version of EncodeFrameResult. Let unit test to test frame_type and show_idx properly. Change-Id: Id810c26c826254fd82249f19ab855ea3b440d99c
2019-11-18Add SimpleEncode::EncodeFrame()angiebird
Change-Id: I08f074b7db2011f88769bd1d9d50cb376c238fe5
2019-11-18Add ComputeFirstPassStats()angiebird
Change-Id: Iaed87a4fa35f456aec5d88d07fade636280eb211
2019-11-15vp9_cx_iface: quiet unused fn warning w/CONFIG_REALTIME_ONLYJames Zern
since: 71684703a Remove output_pkt_list from cpi Change-Id: I14afae6598051680fdaf8c7509b6705d73789dd6
2019-11-14Remove output_pkt_list from cpiangiebird
Move the pkt operations to encoder_encode Change-Id: Ibe730baab61bf7a395998641f106eb0f06d3b8ae
2019-11-13Pack psnr pkt outside of vp9_get_compressed_dataangiebird
Change-Id: I5549c3dbcbe1550824deaebf03178e38c1b07d54
2019-11-13Add g_timebase/g_timebase_in_ts to oxcfangiebird
Use get_g_timebase_in_ts() to set priv->timestamp_ratio and oxcf->g_timebase_in_ts Change-Id: Iea9d589cb7e5611067bcedfdf6f5becd4592d3cf