AgonConsole8 / agon-vdp

Official Firmware for the Agon Console8: ESP32 VDP
MIT License
38 stars 17 forks source link

enhance how line plots that omit start/end points work #157

Open stevesims opened 7 months ago

stevesims commented 7 months ago

The way in which these PLOT commands are implemented takes a copy of the on-screen pixel at the start and/or end point of the line, and will then replace that pixel back to screen after drawing the line.

this is inefficient, and requires the drawing queue to be flushed to guarantee it works properly which may incur flickering

a better solution is to have the line plotting function inside vdp-gl's genericAbsDrawLine routine optionally omit the first and/or last pixel of the line, thus ensuring it never gets drawn in the first place.

additionally absDrawThickLine should probably also provide some kind of support for these line drawing operations

stevesims commented 6 months ago

Inbuilt support for line options was improved in AgonConsole8/vdp-gl#8 which adds the ability to directly omit start/end pixels from a line

This is implemented in #163

No adjustments have been made to absDrawThickLine for now

stevesims commented 5 months ago

fix for simple line plots released in 2.7.0

leaving this issue open tho as there is not a proper solution just yet for absDrawThickLine. a solution for thick lines might be to walk the line by the number pixel the line thickness is currently set to in order to get a new start or end point