Quote:
Originally Posted by kaminkatze
Any hints on how to condense the line? I tried some things with awk but had problems with \x00 in the input. (Never used awk before so this could be entirely my fault.)
|
For the K4 and Touch, I used value \x01 instead of \x00, which truncates to \x00 inside the eink kernel mode drivers. For a K3 or DX, this could be a slight speed problem because ANY grayscale that is drawn or overwritten makes the eink drivers choose a slower update algorithm to support grayscale.
When using "dd" it is a LOT easier and faster to just copy \x00 from /dev/zero (see the "tangle" demo above, which draws both black and white on a K3 eink display). Pure black and white is MUCH faster with smoother animation.
I plan to implement a particle animation system (and a Chipmunk Physics port) when I switch to using C for my kindle native mode GUI creations.
P.S. I will check out your code later. Busy now...
EDIT: Checkout the "tangle" script a few posts back. I did it for you, as an example of how you can have fast small filled objects to populate occupied grid elements for your gliders (and other "life" constructs). I did triangles just to get an example out there so you can see just how fast it is, but you should modify the midpoint circle algorithm used in "spoxbrane" instead. This example draws both black and white filled areas, for a Kindle 3. And check out PoP's Kindle 3 backport of "rippleweave" to see another example of double-wide pixels like I am using in "tangle". Good luck!