Add Blink.DecodedImage.JpegDensity metric reporting JPEG bits per pixel size.
This new metric computes the image file size relative to the image area, also called "compression density" in the compression world. This value is the number of compressed bits per pixel, and it is only reported for large enough images (at least 100px per side), to avoid degenerated cases where the image is too small giving a meaningless value. Image compression formats and encoders for these formats use different techniques to compress an image, discarding some of the original data (for lossy compression). Depending on the range of the desired quality (as measured in bits per pixel) some techniques are more efficient than others. For example, at very low qualities (such as 0.2 bits per pixel) typical 8x8 DCT strategies like in JPEG are not the best since the 8x8 independent blocks are too small to allow sharing information (only 12.8 bits per block). Test: Added unittest. Checked chrome://histograms after browsing some pages. Bug: None Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel Change-Id: Ia4454f66f1b7bde6a1d1b2cfb533f7539f425780 Reviewed-on: https://chromium-review.googlesource.com/1177750Reviewed-by:Philip Rogers <pdr@chromium.org> Reviewed-by:
Steven Holte <holte@chromium.org> Commit-Queue: Philip Rogers <pdr@chromium.org> Cr-Commit-Position: refs/heads/master@{#584172}
Showing
Please register or sign in to comment