Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Discussion about displays and related hardware including MiSTer filters and video settings.
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by sofakng »

Is it possible to have a 31 kHz monitor emulate a 15 kHz display by injecting blank/scanlines?

I was watching a video from Bob at RetroRGB (https://www.youtube.com/watch?v=iLkN2AZLBMA) that showed a 31 kHz (480p) VGA monitor connected to an OSSC and by using the OSSC scanline feature he was able to have the 31 kHz monitor look identical to the 15 kHz display.

Can MiSTer do this? If so, are there optimal settings?
User avatar
mapf
Posts: 153
Joined: Mon Aug 31, 2020 8:05 pm
Has thanked: 58 times
Been thanked: 51 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by mapf »

MiSTer has the

Code: Select all

forced_scandoubler
parameter. When it is active, 15 kHz signals get line-doubled to 31 kHz. In the OSD you can then choose from 25%, 50% or 75% "blank" depending on your preference.
akeley
Top Contributor
Posts: 1303
Joined: Mon May 25, 2020 7:54 pm
Has thanked: 416 times
Been thanked: 399 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by akeley »

Yes, but 15Khz CRTs weren't just about scanlines. It might look similar in a youtube video, but in reality image from most VGA monitors will look duller.
thorr
Top Contributor
Posts: 1100
Joined: Mon Jul 06, 2020 9:37 pm
Has thanked: 537 times
Been thanked: 252 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by thorr »

Agreed. TV's are made for viewing across the room. Monitors sit in front of your face and are not as bright. Also CRT TV's tend to bloom much more than monitors which black scanlines alone won't replicate. With that being said, I like the idea of having a scan doubler option with black lines instead of duplicated lines.
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by sofakng »

Yeah I do understand a CRT monitor won’t be the same as a TV hopefully it’s still a good option.

Does 100% scan lines display the original 240p and then blank (black) lines where they would normally be?
FoxbatStargazer
Top Contributor
Posts: 994
Joined: Thu Dec 10, 2020 5:44 pm
Has thanked: 309 times
Been thanked: 228 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by FoxbatStargazer »

Theoretically it would but there's no 100% framedoubler scanline option in any core at the moment, 75% is the max. Where that is basically 25% brightness on the doubled lines, so dark but not quite black.

For fun you can make a custom resolution for 240p/120hz with vysnc_adjust=0 and vga_scaler=1 (and forced_scandoubler=0), and it will display natural scanlines on your VGA CRT, though it will add a bit of lag.

Probably the more useful option is to use vga_scaler to go to 720p resolution or higher (and again turn off scandoubler) and use one of the scanline filters, just like you would on an HDMI display. This lets you use vsync_adjust=2 for minimal lag.
ash2fpga
Posts: 237
Joined: Tue May 26, 2020 6:20 pm
Has thanked: 62 times
Been thanked: 28 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by ash2fpga »

akeley wrote: Mon Jun 07, 2021 3:04 pm Yes, but 15Khz CRTs weren't just about scanlines. It might look similar in a youtube video, but in reality image from most VGA monitors will look duller.
Wishful thinking, but I would love to see a low lag external shader video processor.

Megathread on libretro showing what shaders can do:
https://forums.libretro.com/t/please-sh ... n-do/19193
rcade
Posts: 100
Joined: Wed May 27, 2020 7:57 pm
Been thanked: 13 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by rcade »

It doesn't look the same. 15KHz machines output the 60Hz picture twice on the same scanlines instead of every other line, which makes it brighter.

A VGA monitor won't do that, you just get one scanline and then a black one. It's darker... like all fake scanline options.

Maybe you can adjust the brightness way up to compensate.
Sepheriel
Posts: 5
Joined: Sat Jun 12, 2021 6:51 pm
Been thanked: 2 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by Sepheriel »

I've implemented 100% scanlines in the NES Core (i just hardcoded it into "scanlines.v" to rapidly see the results) to test it out on a Sony CPD-420GS and it's looking great. The brightness could easily be compensated within the monitors settings.

NES Core 75% Scanlines
IMG_20210612_191943.jpg
IMG_20210612_191943.jpg (7.65 MiB) Viewed 5899 times
NES Core 100% Scanlines
IMG_20210612_191843.jpg
IMG_20210612_191843.jpg (4.18 MiB) Viewed 5899 times
It would be awesome to have it as an option without the need to patch it manually :/
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by sofakng »

Could you upload your modified core so I can give it a test?
Sepheriel
Posts: 5
Joined: Sat Jun 12, 2021 6:51 pm
Been thanked: 2 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by Sepheriel »

My settings are "forced_scandoubler=1" and i've connected my VGA monitor to my MiSTer I/O Board.

You'll have to set the "scandoubler fx" to 75% in the modified cores settings. This will enable 100% Scanlines in the modified cores despite the wrong labelling.

I've also made two more pictures, as the previous ones weren't that good to show the differences

SNES core 75%
IMG_20210613_113809[1].jpg
IMG_20210613_113809[1].jpg (3.42 MiB) Viewed 5841 times
SNES core 100%
IMG_20210613_113712[1].jpg
IMG_20210613_113712[1].jpg (3.45 MiB) Viewed 5841 times
Sepheriel
Posts: 5
Joined: Sat Jun 12, 2021 6:51 pm
Been thanked: 2 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by Sepheriel »

Seems my post was moderated and the links to the cores were deleted without a notification or edit message from the mod. I suppose links to external file service are not allowed?
Sepheriel
Posts: 5
Joined: Sat Jun 12, 2021 6:51 pm
Been thanked: 2 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by Sepheriel »

I zipped the modified NES and SNES cores and attached the archive to this post :)
Attachments
Modified_NES_SNES_Cores.zip
(3.33 MiB) Downloaded 148 times
FoxbatStargazer
Top Contributor
Posts: 994
Joined: Thu Dec 10, 2020 5:44 pm
Has thanked: 309 times
Been thanked: 228 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by FoxbatStargazer »

I figured there was some technical reason for no 100% scanlines in official, but here it is working. Would love to hear an explanation why this wasn't implemented sooner.
Sepheriel
Posts: 5
Joined: Sat Jun 12, 2021 6:51 pm
Been thanked: 2 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by Sepheriel »

I think it was simply not thought about that use case. The MiSTer plattforms main focus is to bring old systems to modern hardware (modern Displays, USB Input etc ) and with the I/O boards purists can even use "original" periphery (PAL/NTSC CRT TV etc.). The target audience for this specific use case is small and from that small group only a bunch will even notice or care about the emulation of 240p scanlines on VGA CRTs and that emulation also has negative side effects like reduced brightness (halved).

But it would certainly be nice for that small group to have the option :D

Also, my "implementation" is rather a quick hack and was only tested on my CRT :)
FoxbatStargazer
Top Contributor
Posts: 994
Joined: Thu Dec 10, 2020 5:44 pm
Has thanked: 309 times
Been thanked: 228 times

Re: Possible to emulate 15 kHz display on 31 kHz (480p) by using scanlines?

Unread post by FoxbatStargazer »

Well no you probably just answered it. The scandoubler options were probably created for 15+31khz PVMs (which would just cycle to scandoubler off for genuine 240p), and not the far more common/cheaper VGA monitors. (Why are they the "niche" choice?)
Post Reply