<table><tr><td style="">lancaster added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D28767">View Revision</a></tr></table><br /><div><div><p>"Rob, I actually disagree that you get the accurate saturation value. E.g. your technique wouldn't work for signed shorts or signed bytes or floating point where the range is 0 to 1.0, or for that matter, cameras where Indi would put out 0-4K values, etc. In the end, I think we'll need a user-supplied input for this, but all that, I think, should get worked out when you complete your Sextractor parameter integration, and this could be one of the parameters that we offer the user the ability to modify. Until then, I believe this will be good enough. It shouldn't do any harm, and it might improve the situation over the current system. I did, though, modify my code to check to see if it was a byte type, and if so, change the saturation threshold to 250."</p>
<p>Hy you are of course correct on this, and I have not fully finished it yet as you pointed out. One possible thought I have on how to fix this is to either divide by 2 or raise to one less power of two for signed data types, but the only way I can think to determine whether it is signed or not is to just have an if statement or case switch statement based on the types that should be signed. I am not sure that we can determine what saturated means for a float or double image, but we might not have to because their max value is incredibly high. I did already make a user supplied value, basically a threshold percentage of saturation they would like to remove, I think this will be easier for end users to work with, assuming that I can get the data types worked out.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R321 KStars</div></div></div><br /><div><strong>BRANCH</strong><div><div>sep-focus-improvements (branched from master)</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D28767">https://phabricator.kde.org/D28767</a></div></div><br /><div><strong>To: </strong>murveit, mutlaqja, lancaster, TallFurryMan<br /><strong>Cc: </strong>kde-edu, narvaez, apol<br /></div>