-
Notifications
You must be signed in to change notification settings - Fork 7
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
Support displaying high dynamic range images, #26 #27
base: main
Are you sure you want to change the base?
Conversation
This commit will: - Change JXL.parse to use JxlDecoderGetColorAsEncodedProfile - Add support for itur_2100_PQ and displayP3_PQ color spaces - Add a MTKView view to the storyboard - Add a MetalImageView class to display HDR images with EDR enabled - Update build_libjxl.sh to work with latest libjxl version - Change build_libjxl.sh to use a tagged released version of libjxl instead of the latest changes in the main branch - Switch JXLook to libjxl v0.8.2, the latest released version - Remove use of libbrotlienc - Add application settings to allow some control over rendering of HDR images - Lower macOS deployment target to 10.15 from 11.0 - Add support for unified logging using OSLog - Add logging of JXLook version and libjxl version at startup - Apply Xcode 14.3 recommended settings - Correct CFBundleVersion warning - Add .DS_Store to .gitignore The NSImageView is now a subview of the MTKView. The NSImageView subview is preferred and will be used whenever it is able to properly render the image. The MTKView is used to display HDR images encoded with the PQ transfer function when the screen supports EDR, tone mapping the image to stay within the display headroom.
@yllan @JLHwung Thank you for creating JXLook! Internet posts indicate macOS Sonoma will contain support for JPEG XL. Great news. However as customary, Sonoma adds to the list of Macs that are no longer supported by the latest macOS version. Users running older versions of macOS will still need a JPEG XL viewer. With the changes in this PR JXLook is able to display HDR images with EDR enabled. I have tested this on a MacBookPro18,2 with the M1 chip and XDR display running macOS Ventura as well as a MacBookAir8,2 running macOS Catalina. I am operating way outside of my area of expertise, so I'm sure an expert will be able to point out lots of errors. However these changes certainly improve the display of HDR images. This is what the new settings window looks like: The following shows the logs messages emitted in a test where the JXLook window was initially on an external display that does not support EDR and then moved to the built in display that does:
Initially the image was displayed using the NSImageView. Then to support EDR tone mapping JXLook switched to the MTKView. |
@low-batt This PR looks awesome. Thank you. |
The HDR JPEG XL images posted by Eric Chan on mit.edu look great on a Mac with an XDR display. I tried to put a lot of comments in the code to make it clear what it is doing. Any questions or if you want me to make changes I'm around. |
great work man! How to run this? or install it? is there an .app file available for download since i dont know how to compile an .app |
I am currently patiently waiting for the creator of Since this was posted Apple has released macOS Sonoma. I have not upgraded yet over concerns about some of the problems people have reported. I am going to have to upgrade and see how much JPEG-XL support Apple added. I'm not seeing any active forks, so I don't think anyone has pulled these changes and published an app. So as you suspected currently you must build JSLook with these changes using Xcode. This project is not too hard to build. Xcode needs to be installed along with the command line tools. The repository needs to be cloned. Then you need to switch to this PR which can be easily done using the GitHub CLI. Then the At least I think that is all that is needed. Been a while since I built |
This commit will:
The NSImageView is now a subview of the MTKView. The NSImageView subview is preferred and will be used whenever it is able to properly render the image. The MTKView is used to display HDR images encoded with the PQ transfer function when the screen supports EDR, tone mapping the image to stay within the display headroom.