diff options
author | Campbell Barton <ideasman42@gmail.com> | 2015-06-15 21:15:57 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2015-06-15 21:16:27 +0300 |
commit | b633c2857f141093ba16152b7c4c91f79d32d4c8 (patch) | |
tree | 8bdfb67f1c16aa7f1b4155e918c4cf19b9c8f114 /source/blender/blenkernel | |
parent | 3f7ea7489ee172be54f320b948167f9ca61a4eb3 (diff) |
Fix integer division error with image scopes
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/colortools.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/colortools.c b/source/blender/blenkernel/intern/colortools.c index a6ba13471f6..9cce9294bb4 100644 --- a/source/blender/blenkernel/intern/colortools.c +++ b/source/blender/blenkernel/intern/colortools.c @@ -1087,6 +1087,7 @@ void scopes_update(Scopes *scopes, ImBuf *ibuf, const ColorManagedViewSettings * /* convert to number of lines with logarithmic scale */ scopes->sample_lines = (scopes->accuracy * 0.01f) * (scopes->accuracy * 0.01f) * ibuf->y; + CLAMP_MIN(scopes->sample_lines, 1); if (scopes->sample_full) scopes->sample_lines = ibuf->y; |