Skip to content

Commit

Permalink
Remove unnecessary rounding. (#1867)
Browse files Browse the repository at this point in the history
  • Loading branch information
maryla-uc authored Dec 11, 2023
1 parent 7b9a072 commit d894acf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/gainmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,8 +479,8 @@ avifResult avifRGBImageComputeGainMap(const avifRGBImage * baseRgbImage,
for (int c = 0; c < 3; ++c) {
gainMapMetadata.gainMapMin[c] = gainMapMinLog2[singleChannel ? 0 : c];
gainMapMetadata.gainMapMax[c] = gainMapMaxLog2[singleChannel ? 0 : c];
gainMapMetadata.baseHdrHeadroom = avifRoundf(log2f(baseMax));
gainMapMetadata.alternateHdrHeadroom = avifRoundf(log2f(altMax));
gainMapMetadata.baseHdrHeadroom = log2f(baseMax);
gainMapMetadata.alternateHdrHeadroom = log2f(altMax);
// baseOffset, alternateOffset and gainMapGamma are all left to their default values.
// They could be tweaked based on the images to optimize quality/compression.
}
Expand Down

0 comments on commit d894acf

Please sign in to comment.