projects
/
goodguy
/
cinelerra.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
histogram fix, use_thumbnails fix, zoom popup width tweak, cut/paste for mixer apply...
[goodguy/cinelerra.git]
/
cinelerra-5.1
/
plugins
/
histogram
/
histogram.C
diff --git
a/cinelerra-5.1/plugins/histogram/histogram.C
b/cinelerra-5.1/plugins/histogram/histogram.C
index da67c208694425820ffdc42af07f0949562086d7..1d24200135994d351b7620d087c85760f0b58b0e 100644
(file)
--- a/
cinelerra-5.1/plugins/histogram/histogram.C
+++ b/
cinelerra-5.1/plugins/histogram/histogram.C
@@
-280,7
+280,8
@@
float HistogramMain::calculate_level(float input,
// Scale to input range
if(!EQUIV(config.high_input[mode], config.low_input[mode]))
{
// Scale to input range
if(!EQUIV(config.high_input[mode], config.low_input[mode]))
{
- output = (input - config.low_input[mode]) /
+ output = input < config.low_input[mode] ? 0 :
+ (input - config.low_input[mode]) /
(config.high_input[mode] - config.low_input[mode]);
}
else
(config.high_input[mode] - config.low_input[mode]);
}
else