Skip to content

Commit

Permalink
Fix prescreener with float inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
sekrit-twc committed Sep 22, 2021
1 parent 380c58e commit bbdabfd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion znedi3/znedi3_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ znedi3_filter::znedi3_filter(const NNEDI3Weights &weights, const znedi3_filter_p
assert(model_set.find(traits) != model_set.end());
const PredictorModel &model = *model_set.find(traits);

double pixel_half_val = static_cast<double>((1UL << bit_depth) - 1) / 2.0;
double pixel_half_val = (m_type == PixelType::HALF || m_type == PixelType::FLOAT) ? 0.5 : static_cast<double>((1UL << bit_depth) - 1) / 2.0;

switch (params.prescreen) {
case ZNEDI3_PRESCREEN_NONE:
Expand Down

0 comments on commit bbdabfd

Please sign in to comment.