summaryrefslogtreecommitdiff
path: root/libs/jpegrecoverymap/jpegdecoderhelper.cpp
diff options
context:
space:
mode:
author Nick Deakin <deakin@google.com> 2023-02-10 15:39:08 -0500
committer Nick Deakin <deakin@google.com> 2023-02-13 13:11:17 -0500
commitd19e576fef9a1bd99a2118bb7edb6e2549ddde49 (patch)
treecb2fa818dc0168c7e24abb2c274a6b5b932a5a8f /libs/jpegrecoverymap/jpegdecoderhelper.cpp
parent82a999b81bdbe9650901777523ae4b34fd88b7d1 (diff)
jpegrecoverymap: Add min boost to metadata.
This change updates recovery map metadata from specifying only max boost (with implied min boost of its inverse) to specifying both min and max boost explicitly. Places where this matters are also updated to handle calculating, encoding, extracting, and applying boost appropriately. Updated tests and added new tests for relevant new edge cases. Also add benchmark test. To make this nice, make generateRecoveryMap() and applyRecoveryMap() functions protected instead of private in the RecoveryMap class. Current results on Pixel 7 Pro for 12MP are: * generate map: ~150ms * apply map: ~95ms This is a bit slower than before for generate (~110ms) because we now also sample the SDR image when determining the metadata's boost values. Also fix a bug in the applyRecoveryLUT test where we weren't actually iterating over the LUT and instead only tested the first entry, and another bug with LUTs in general where we were incrementing values by 1/number of entries when we should actuall increment by 1/(number-1). Bug: 264715926 Test: tests pass Change-Id: I687eb9c2f788e9220a14311497a129956b2077fd
Diffstat (limited to 'libs/jpegrecoverymap/jpegdecoderhelper.cpp')
0 files changed, 0 insertions, 0 deletions