faster DM42 Hitomezashi algorithm
|
08-27-2023, 03:45 PM
Post: #1
|
|||
|
|||
faster DM42 Hitomezashi algorithm
On a 1/23/22 post entitled "Calculator Graphics Drawing Benchmark", the Hitomezashi algorithm implemented for the DM42 takes 18.7 seconds on a 400x240 screen. Because the DM42 does not have a line command, a lot of time is consumed drawing lines pixel by pixel. However, using the AGRAPH command, this can be greatly increased in speed. There is the AGRAPH limitation of drawing 8 pixel vertical lines, however, a 200x120 screen can be used if longer looking lines are desired (still limited to a maximum of 8 pixels size). Store the size in the variable S (using a number from 3 to 8). On line 4, a 3 specifies a 400x240 screen, and a 2 specifies a 200x120 screen. I used the original benchmark posting code as a reference, but wrote my own implementation of the Hitomezashi algorithm, to make use of the AGRAPH command.
Here are the times using an unscientific method of a stopwatch: 400x240 using USB cable: S=4 - 3.55 sec. S=8 - 1.42 sec. 400x240 using battery: S=4 - 8.55 sec. S=8 - 2.58 sec. Code:
|
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
faster DM42 Hitomezashi algorithm - arhtur - 08-27-2023 03:45 PM
|
User(s) browsing this thread: 1 Guest(s)