Page 1 of 1

monitor/CRT emulation

Posted: Sun Mar 08, 2015 2:46 am
by snoopy
Hi, I just completed a playthrough of my first game using Hatari (Baal). I loved the whole experience. Hatari is a great piece of software. Lots of thank yous to the creators for their work.

I am no programmer, so go easy on me if the following question sounds a bit naive to you:
When I was playing around with the screen modes in Hatari, I found the scanline mode to be the nicest. Recently, some emulators started using shaders (HLSL orGLSL) or some other effect to emulate CRT monitors/TVs (MAME, retroarch, SainT).
I was really positively surprised when I activated this the first time: Everything looks so much more authentic (down to the adjustable screen curvature and fluorescence).
For example: http://mybroadband.co.za/vb/showthread. ... ost8559531


Is it possible or even planned to integrate such an effect in Hatari?
Or is there an external way to apply such an effect to the Hatari window (something like sweetFX)?

Thanks for answering.
Snoopy/roloway

Re: monitor/CRT emulation

Posted: Sun Mar 08, 2015 10:42 am
by Eero Tamminen
Hatari uses SDL features for screen updates for portability reasons. DirectX (HLSL) is Windows specific and even OpenGL (GLSL) shaders aren't supported on all platforms where Hatari runs (e.g. high-end Atari clones). SDL works everywhere.

Re: monitor/CRT emulation

Posted: Sun Mar 08, 2015 6:09 pm
by snoopy
Thanks a lot for the quick answer and again thank you and the rest of the team for keeping hatari alive and advancing it.
There are not many good Atari ST (and Falcon) emulators left.

After understanding the problem a bit better,I started digging a bit. What I found gives me at least a little hope:
DOSBox (SDL) and SDLmame also added the use of shaders, for example from the open libretro library of shaders.
The crt shader itself seems to be free, ready and working - no idea if the integration is a lot of work or if it was more like a "plug and play" sort of thing.
Check it out at work here in DOSBox: http://www.dosgames.com/forum/about1994 ... highlight=
It looks awesome.

So maybe one day it will be possible in Hatari as well or as an optional addon for PC users (like sweetFX).

To conclude:
This would have been a nice extra, but Hatari is already great as it is.
Keep up the good work!

For more info:
http://emulation-general.wikia.com/wiki/CRT_Geom
https://github.com/libretro/common-shaders

Re: monitor/CRT emulation

Posted: Mon Jul 31, 2017 10:51 pm
by nonameno
up !! ;)

Re: monitor/CRT emulation

Posted: Wed Aug 02, 2017 2:14 pm
by Eero Tamminen
Good CRT emulation requires emulating multiple things:
* aspect ratio
* color bleeding between pixels
* gradual pixel color change between frames

None of the Hatari developers is looking into these, but you could make a try at them and post patches for consideration to hatari-devel.

Note that doing last item properly requires monitor which refresh rate is multiple of Atari's 50Hz / 60Hz / 71Hz refresh frequencies. 100-120Hz monitors aren't yet that common.

Re: monitor/CRT emulation

Posted: Tue Aug 15, 2017 11:59 am
by MrMaddog
Only thing I can think of is using the Hatari core on RetroArch which does let you use CRT shaders & overlays. Good luck getting it set up though...