-
-
Notifications
You must be signed in to change notification settings - Fork 275
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhanced Bit-Depth Support and Error Handling for adjustColor #705
Comments
if I transform the image into a regular jpeg, i don't see strange colors, so this seems to be related to tiff decoding. |
The adjustColor function isn't handling 16-bit images, so for now you can make sure the image is 8-bit: final editedImage = adjustColor(
image.convert(format: Format.uint8),
exposure: 0.5
); |
Converting to 8-bit resolves the immediate issue, but adding native support for 10-bit, 12-bit, and 16-bit image adjustments would greatly enhance the library's usability and flexibility for modern workflows. Currently, the library's silent handling of higher bit-depth images by returning incorrect values can lead to subtle bugs that are difficult to track down. Instead, the library should fail gracefully by throwing a clear exception when an unsupported bit depth is used with Implementing this change would not only improve the robustness of the library but also set a clear path for potential future enhancements that support higher bit-depth operations. It could be a significant improvement for developers working with high-fidelity image processing tasks. |
I pushed the fix for adjustColor. I'll still look into seeing if the different filters can be improved. |
I pushed some changes to hue and saturation in the adjustColor function, to make the adjustments in HSV space. |
test images:
testHorizontal.tiff.zip
The text was updated successfully, but these errors were encountered: