06-17-2010, 05:43 AM
Definitely working on that.
I've realised that there's a tradeoff between speed and flexibility - a routine that could do it all could be written, but then it would spend a lot of time testing to see which bits of code need to be run, and graphics (and sound, I suppose) are the parts of programs that are most speed critical.
As a result, I think I'll end up with three subroutines - put down blocks of data, paint in one colour, paint data into the colour area.
If you find those aren't fast enough, I suppose it's possible to combine two of them to put down pixel and colour data - faster than two successive calls.
Even two calls should be fairly fast, though.
Suffice to say: Working on the paintAttr one.
I've realised that there's a tradeoff between speed and flexibility - a routine that could do it all could be written, but then it would spend a lot of time testing to see which bits of code need to be run, and graphics (and sound, I suppose) are the parts of programs that are most speed critical.
As a result, I think I'll end up with three subroutines - put down blocks of data, paint in one colour, paint data into the colour area.
If you find those aren't fast enough, I suppose it's possible to combine two of them to put down pixel and colour data - faster than two successive calls.
Even two calls should be fairly fast, though.
Suffice to say: Working on the paintAttr one.