summaryrefslogtreecommitdiff
path: root/libs/gui/BLASTBufferQueue.cpp
diff options
context:
space:
mode:
author Sally Qi <sallyqi@google.com> 2023-08-07 15:28:30 -0700
committer Sally Qi <sallyqi@google.com> 2023-08-21 16:54:03 +0000
commita92d6d143fc803a1bbcd37c291f0b3fc17fb4b72 (patch)
tree4ef1d9d919643a989367b12e7a0c67e5d95f9789 /libs/gui/BLASTBufferQueue.cpp
parent32829c7ab19d3ab1688cee2ca74a9b230eeae2f0 (diff)
Refactor `isHdrDataspace` function.
- Rename it to `getHdrRenderType` and return a ternary enum. - return the hdr type that we want to treat based on the dataspace, format and hdr/sdr ratio. - pixelformat is optional, in case no source buffer but there is a source color. - hdr/sdr ratio is 1.0f by default, render rengine doesn't take care this param. - The ternary enum has 3 types: just SDR; generic hdr, namely those we need to tonemap; display hdr, namely those self-promoting to HDR by using extended brightness API. - This fix also contains commit I094836e460e0d64b28492061128cff11f22944d9 Bug: 261485283 Test: HdrRenderTypeUtils_test, TextureViewTest#testSDRFromSurfaceViewAndTextureView, OutputLayerUpdateCompositionStateTest Change-Id: I281687a010bbf5bff555f6fa893002c2a9b324d1 Merged-In: I281687a010bbf5bff555f6fa893002c2a9b324d1
Diffstat (limited to 'libs/gui/BLASTBufferQueue.cpp')
0 files changed, 0 insertions, 0 deletions