QL Screen View online

Anything QL Software or Programming Related.
User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

QL Screen View online

Post by badaman »

My friend Miguel Ángel Rojo asked yesterday about applications to view QL screens on the PC, and although he found one that works for him (Multipaint), I was bitten by the possibility of creating something like that myself, and here is the result.

This display only supports (for now) 8-color mode (MODE 8), but I will expand its capabilities to support mode 4. <- UPDATED!

The program looks like this:

Image

It consists of an HTML file that you can use online or download to your computer, and that allows you to open a file in QL format and display it in the appropriate 4:3 aspect ratio.

It can be used online here:

https://javguerra.github.io/qlscrview/

The image that is uploaded is also available in the repository:

https://github.com/JavGuerra/qlscrview/tree/main

Download qlcolors_scr to try, from the docs folder.

I hope you enjoy it.
Last edited by badaman on Fri Feb 09, 2024 12:42 am, edited 3 times in total.


User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

Re: QL Screen View online

Post by badaman »

Update. It is now possible to display screens in mode 4 as well.

Update. A feature has been added whereby it is possible to download, in PNG format, the image that has been displayed.
Last edited by badaman on Mon Feb 05, 2024 8:15 am, edited 1 time in total.


User avatar
dilwyn
Mr QL
Posts: 2761
Joined: Wed Dec 01, 2010 10:39 pm

Re: QL Screen View online

Post by dilwyn »

Nice work, Javier. I just tried it now, works OK on Edge browser on Windows 10 on my PC.

I hope I'm correct in assuming that

a) Javascript needs to be enabled in the browser (not looked at the HTML to check)?
b) it only handles 512 x 256 QL screens at the moment?

For me, a natural development would be to add support for higher resolution screens and PIC files and of course for high colour screens. I expect most people will only use it to display mode 4 and 8 QL screens though..

As higher resolution screens don't include width and height dimensions, you have to guess the width and height based on file sizes corresponding to common screen dimensions, e.g. 640x480 pixels (76800 bytes), 800x600 pixels (120000 bytes), 1024x768 pixels (196608 bytes).

PIC files have the 10 bytes before the graphics data, holding:

word - ident $4AFC
word - width in pixels
word - height in pixels
word - line increment (number of bytes from start of one line to the next)
byte - mode number
byte - spare, unused


User avatar
bwinkel67
QL Wafer Drive
Posts: 1202
Joined: Thu Oct 03, 2019 2:09 am

Re: QL Screen View online

Post by bwinkel67 »

Oh, that's so handy. I was just playing around with Photon over the holidays so this tool is nice to have to see what the _scr file looks like.


martyn_hill
Aurora
Posts: 933
Joined: Sat Oct 25, 2014 9:53 am

Re: QL Screen View online

Post by martyn_hill »

Dear Javier

What a truly handy online utility! Thank you :-)

Here's a rendition from your tool of my favourite 32k QL mode-8 _scr, courtesy of ACG/Ultimate - one I use for testing my Networking developments (hope I'm not encroaching on copyright - if so I'll delete it immediately.)
JP_scr.png


User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

Re: QL Screen View online

Post by badaman »

dilwyn wrote: Mon Feb 05, 2024 10:44 am Nice work, Javier. I just tried it now, works OK on Edge browser on Windows 10 on my PC.

I hope I'm correct in assuming that

a) Javascript needs to be enabled in the browser (not looked at the HTML to check)?
b) it only handles 512 x 256 QL screens at the moment?

For me, a natural development would be to add support for higher resolution screens and PIC files and of course for high colour screens. I expect most people will only use it to display mode 4 and 8 QL screens though..
It's right. JavaScript needs to be enabled to work.

I hadn't thought about continuing to work on other modes yet, because I'm reserving the weekend to unify the two modes into a single HTML, but the information you give me is very useful, and I'm going to see if I can do it.

Thank you very much for the information!


User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

Re: QL Screen View online

Post by badaman »

Thank you martyn_hill and bwinkel67.

I'm glad you like this little utility.

The code can be downloaded and modified without copyright problems, as it is under the GPL license.

Regards!


User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

Re: QL Screen View online

Post by badaman »

A curious thing. Since the application does not check the file extension, because there is no convention for the extension, and since QL images are data without a descriptive header, we can load anything, for example, a ROM image. What you see here is a screenshot of Minerva 1.89. Obviously only 32 Kb are shown. Do you recognize the image? XD
min189_rom_QL4.png


User avatar
badaman
Over Heated PSU
Posts: 134
Joined: Sun Jan 12, 2020 12:18 pm
Location: Spain
Contact:

Re: QL Screen View online

Post by badaman »

Here are a few images in QL mode 4 to practice.

https://badaman.badared.com/ql/images/index.htm


User avatar
desin
Chuggy Microdrive
Posts: 54
Joined: Mon May 10, 2021 10:33 am

Re: QL Screen View online

Post by desin »

good work !
can you implement some kind of preview so
we can see if the QL screen is mode 4 or mode 8

Greetings from Switzerland
Markus


Post Reply