Skip to content

Commit

Permalink
Float precision is sufficient
Browse files Browse the repository at this point in the history
  • Loading branch information
jonfryd committed Aug 18, 2024
1 parent 35fd181 commit e187198
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion video_filterer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ VideoFilterer::VideoFilterer(const Demuxer* demuxer,

filters.push_back("format=rgb48");

float tone_adjustment = (tone_mapping_mode == ToneMapping::relative && peak_luminance_nits < other_peak_luminance_nits) ? static_cast<double>(peak_luminance_nits) / other_peak_luminance_nits : 1.0;
float tone_adjustment = (tone_mapping_mode == ToneMapping::relative && peak_luminance_nits < other_peak_luminance_nits) ? static_cast<float>(peak_luminance_nits) / other_peak_luminance_nits : 1.0F;
tone_adjustment *= boost_tone;

if (std::fabs(tone_adjustment - 1.0F) > 1e-5) {
Expand Down

0 comments on commit e187198

Please sign in to comment.