-
Notifications
You must be signed in to change notification settings - Fork 6
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
iTerm IIP support #43
Conversation
With the last commit we gain 3-6 times faster processing speed by avoiding string + gc pressure, also atob seems to be much slower than the custom base64 decoder. Things now get usable with typical web optimized image sizes, but we are not there yet - for bigger images the blocking of the base64 decoder + blob creation on the mainthread is a clear showstopper (~70ms for a 25MB png file). |
- optimized b64 decoder - determine image type and dimensions upfront - avoid blocking from resizing drawImage, apply resize on bitmap directly
Seems the new base64 decoder is quite speedy:
|
Some promising results with base64 decoding in SIMD (needs nodejs v16 to run):
Not sure yet whether to go that path, as it creates frictions with Safari (still needs the scalar version). Edit:
In long term all these issues will be a dealbreaker for Safari, they better get things supported or Safari will die as a target platform for many web developers needing performant solutions. I really dont get it why apple neglect its once superior engine and turns it into the new ugly kid. |
Supported formats:
Other formats are possible but not yet a goal (theoretically only limited by browser support). Same with animated GIF or APNG - we have currently no way to output animated image content, as we do canvas scraping driven by xterm.js' render cycle. Maybe with a later incarnation...
TODO:
png-ts
dependencyIssues:
again web workers for the rescue?- nope