Page 1 of 1

RECOLour in QPC

Posted: Thu Feb 08, 2018 11:35 am
by Martin_Head
Does the RECOL command work in any mode other than 512x256, QL Colour mode, in QPC2?

If not. Ii there any way to reproduce the command it in higher screen resolution/colour modes.

I am trying to update an old Basic program to work on newer systems, and it uses RECOL. I could maybe program around it.

Also, with the QPC_QLSCREMU command. If I have a screen greater than 512x256. Will QPC_QLSCREMU only ever copy the original 32K screen at 131072 into the top left hand corner of the display, and not stretch it to cover the entire screen. Part of the above program draws graphic images by writing directly to the display, and I would like to make it draw on a larger canvas.

Re: RECOLour in QPC

Posted: Thu Feb 08, 2018 1:14 pm
by tofro
No, it doesn't. See QPC Keywords Manual, page 95.

If you think about it a bit, for a 64k colour screen and even for 256 colors that command would require quite some arguments...

Your best bet to replicate RECOL for high-color, high-res modes is probably machine code or a combination of the Turbo Toolkit SEARCH_MEMORY and POKEs into screen memory. But I wouldn't expect something like that to be anything like quick...

Tobias

Re: RECOLour in QPC

Posted: Thu Feb 08, 2018 5:00 pm
by pjw
Check out the excellent PHGTK (available from Dilwyn's). Perhaps you can use that to develop some kind of work-around..

Re: RECOLour in QPC

Posted: Fri Feb 09, 2018 1:34 pm
by Martin_Head
Thanks for the replies, I did not expect that there would be an easy work around.

For RECOL, I think I can just flip the paper and ink colours, and redraw the screen again (keeping track of the paper and ink's).

For the other problem of where the image is plotted directly to the screen memory. I was wondering if I could replace the routine that plots the lines, with one that uses the draw routines. As the Y axis is the other way up in the graphics routines, I expect the image would come out upside down. Would switching the start and end Y values of the line to be drawn, flip the image the right way up?