ctx: update from upstream - more enabled features
CTX_PARSER - for parsing SVG path data inline.
CTX_GSTATE_PROTECT for sanity checking on save/restore balance (the sanity checking we already get, with ctx_gstate_protect() and ctx_gstate_unprotect() inserted around "user" code, balance will also be restored.
CTX_FORMATTER - for recording vector "screenshots" and transmitting display contents over TCP.
Pixel encodings GRAY1, GRAY2, GRAY4 - for efficient large lowbith grayscale textures, we've got lots of memory, but we can stretch it much further by using 1-4bit per pixel rather than 24/32 for some high-contrast use cases.
Pixel encoding GRAYA8 - to handle grayscale PNGs with alpha.
Merge request reports
Activity
this is part of the changes earlier kept as a work-in-progress base of fixes underneath st3m_media. With this, some incorrect use of ctx (also internal in ctx) will be less damaging to the global graphics state and reported on to stderr. And I think grayscale PNGs with alpha might have been a lingering PNG variant that first starts working now.
I also have not tested,. but uctx already has bindings for ctx.parse() that get conditionally enabled. This might be a bigger feature. Instead of translating a SVG path data string of d="M 100 100 L 120 120 l -40 0 z" string into individual drawing commands like ctx.move_to(100,100).line_to(120,120).rel_line_to(-40,0).close_path() one should can now be able to call ctx.parse("M 100 100 L ...").
As well as using the rest of https://ctx.graphics/protocol/ which is a superset of SVG path data.
Edited by pippinadded 9 commits
-
e390e9b1...89363462 - 7 commits from branch
main
- 716a767a - ctx: update from upstream - more enabled features
- b07a77d8 - mypy: sprinkle ctx docs
-
e390e9b1...89363462 - 7 commits from branch
enabled an automatic merge when the pipeline for b07a77d8 succeeds