Skip to content

Conversation

Wukix
Copy link

@Wukix Wukix commented Apr 21, 2013

Hi Zach,

Offering these performance enhancements to VECTO, which can be rather slow sometimes on mobile devices. A major speedup is for string drawing, under a new function DRAW-STRING-FAST, which caches character glyph bitmaps rather than vector-rendering them repeatedly. Another major speedup is for PNG encoding, but it is conditional only to mocl because it calls out to mocl's own PNG encoder. FWIW, wanted to keep it under ZPNG, but just couldn't achieve the necessary level of performance in a reasonable amount of engineering time.

Not sure if this will completely fit your vision for VECTO or your preferred coding style, so please feel free to reject or modify whatever changes. If necessary, we can maintain our own fork instead rather than go the merge route.

Changes:

  • New type declarations for several functions.
  • Added DRAW-STRING-FAST: like DRAW-STRING, but much faster.
  • Added DRAW-IMAGE, which can combine images.
  • SAVE-PNG now calls an optimized PNG encoder under mocl.
  • WITH-CANVAS now provides an option not to close font loaders.

Wukix added 2 commits April 20, 2013 17:34
Changes:
* New type declarations for several functions.
* Added DRAW-STRING-FAST: like DRAW-STRING, but much faster.
* Added DRAW-IMAGE, which can combine images.
* SAVE-PNG now calls an optimized PNG encoder under mocl.
* WITH-CANVAS now provides an option not to close font loaders.
Changes:
* Fixnum declarations replaced by more meaningful ones
* Pluggable *write-png-function* created for better flexibility
* Replaced tab characters with spaces
@Wukix Wukix closed this Apr 21, 2013
@Wukix Wukix reopened this Apr 21, 2013
@Wukix
Copy link
Author

Wukix commented Apr 21, 2013

Attempted to address all the issues you've raised in a new commit. Let me know what you think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants