Output fullscreen without scaling to display?

I’ve been fortunate enough to come across a CRT computer monitor, which I hope to use for emulation. I don’t have it with me—my dorm room isn’t big enough for 2 CRTs—so I can’t test anything until I get home for the holidays; however, I’ve been doing some research on problems I’m likely to run into. The hookup shouldn’t be a problem, since my graphics card has DVI-I, so I can get a passive converter for a dollar and be set. Output resolution seems to be a hurdle, however.

AMD recently (I think recently) added some fine-grained controls for display resolutions and timings (includes presets for CVT, CVT-reduced blanking, GTF, DMT, and allows custom timings). I’m sure I could get any single console resolution working perfectly with this, provided it works as advertised, but that’s the eternal problem…it would have to be manually changed every time I switch consoles, and for any games that switch resolutions (I think Wild Arms does this)…forget about it. Kinda defeats the purpose of a unified, beautiful frontend, no?

My question, though: what if Retroarch could output a fullscreen image, but without any scaling? Would it work? Is it possible?

I’m assuming that some programs run in fullscreen, but change the desktop resolution. Cave Story comes to mind—the alt-tab overlay gets scaled up, pixelated, and stretched while the game has focus, since it actually runs at 640x480 (or less). But then again, I don’t know for sure whether my monitor is scaling the image, or if Windows scales everything, even if it was rendered at a lower resolution. That would put an end to my plans, but I’m hoping there’s a potential here.

I took a quick look for utilities to output a window in fullscreen, which I could use on Retroarch in 1x windowed mode, but I didn’t find anything. This is pretty niche, so I expect any solution I find to be mostly hacks held together with twine and duct tape (should I be so lucky).

So…thoughts? If I’m nuts, just tell me. Thanks!

The easiest way to achieve what you’re describing is to set your OS to an ultrawide resolution with 1920 or even better 3840 on the x-axis and 240 or 480 on the y-axis. Then, launch RetroArch fullscreen with integer scaling ON. This works pretty well for consoles that were hooked up to an NTSC TV, as well as for most horizontal arcade games.

If you use *x240, you’ll probably need to set your modeline to use 120 Hz refresh rate (unless it’s a special, multisync monitor) and any games that use interlacing will look weird. If you use *x480, you can use a normal 60 Hz refresh rate and use the interlacing shader (in the ‘misc’ shader subdirectory). It looks almost as good as 240p and handles interlaced content properly.

There are a few threads on the forum that go over more details.

Thanks for the summary. I’ll get that set up when I’m able, doesn’t sound like too much trouble. If it is…I’ll figure it out, I’m smarter than I look. Your help is always appreciated, hunterk! :slight_smile:

For a general purpose PC CRT, you can pretty much do this:

[ul] [li]Create custom resolution mode with the GPU driver’s custom resolution tool, or use Custom Resolution Utility if you want to use an EDID override. When you create the resolution resolution mode, the horizontal refresh in KHz must be within your monitor’s limits, so mind the vertical refresh rate and vertical resolution (e.g. 320x240 60Hz (15KHz) won’t work on a 31KHz+ PC CRT). Horizontal resolution only matters as far as the pixel clock limits of your video card go, so you actually drive it sky high without any complaints from the CRT . The ideal modes to use are 3840x480 60Hz or 3840x240 120Hz, either should work on most PC CRTs made since the 90s, and the high horizontal resolution will make them as general purpose as possible by allowing games that use different horizontal resolutions to scale losslessly. [/li] [li]In order for RetroArch to actually use the resolution, it must be configured to do so. The most important settings for doing this are the video_fullscreen_x, video_fullscreen_y, and video_refresh_rate, because those are used to set the video mode when using non-windowed fullscreen (i.e. when video_fullscreen is true and video_windowed_fullscreen is false); the fullscreen x/y settings are not exposed in the menu so you’ll have to edit or add them to your config file. With the superwide 3840 width modes listed above, you will also need to set the video_aspect_ratio to a value that makes it stretch to the full length of the video mode (x resolution divided by y resolution will do it), and set the aspect_ratio_index to 19 so the “Config” aspect ratio is used. The RGUI menu driver is the only one that will display correctly in this manner, so it should be used over XMB or GLUI. So if you use 3840x480 60Hz, your config file would need the following to start up in that display mode: [/li]

video_fullscreen_x = 3840
video_fullscreen_y = 480
video_refresh_rate = 60.0
video_aspect_ratio = 8.0
aspect_ratio_index = 19
video_fullscreen = true
video_windowed_fullscreen = false
menu_driver = rgui

[li]If you want an optimal image, you’ll want to use pixel shaders that will interpolate horizontally, allow color adjustments, and/or blank out doubled lines. The shader presets in shaders_cg/cgp/tvout+interlacing will do this for 480p modes, with the simplest one being tvout+interlacing.cgp. The other presets in that folder have extra things like NTSC effects or dither pattern removal. If you are using a 240p mode, use the shader presets in shaders_cg/cgp/tvout instead which omit the interlacing shader. You can either load the shader preset in the menu using Load Shader Preset, or set video_shader to the path of the shader preset in your config file. The shader presets have settings for “signal resolution” (horizontal blur), colors, and other things like overscan cropping that you can adjust by going into Preview Shader Parameters which take effect instantly and Menu Shader Parameters which take effect when you use Apply Shader Changes and are saved into a working shader preset. [/li][/ul] When you have this set up, RetroArch should start up using your configured display mode with the selected shader, which will result in output that is 240p and will switch to 480i when needed.

Some extra considerations for CRT monitors:

[ul] [li]If you choose to use a 120Hz mode, you will want to either use Black Frame Insertion or Vsync Swap Interval 2 (but not both), and set video_refresh_rate to 60. On the Windows version of RetroArch, either of those settings being enabled will automatically double the configured refresh rate before setting the video mode, which is done because the refresh rate setting is also used for audio synchronization. Black Frame Insertion will darken the image by 50% but will eliminate visible frame duplication and bring motion quality equal to that of 60Hz output, which can be doable if the CRT has enough brightness. On the other end, perfect frame doubling is achieved by using Vsync Swap Interval set to 2, so that Vsync swaps occur twice per frame. It is not recommended to use video_refresh_rate at 120.0 with both options disabled since that will disable audio synchronization due to the large timing skew needed to sync 60Hz games to 120Hz with no frame doubling, resulting in stuttering. [/li][li]The video_refresh_rate setting can be set to a fractional number, but it will be rounded up when RetroArch chooses the display mode on Windows. You can create display modes in Windows with fractional vertical refresh rates but they will be reported as a whole number in the OS, so that is somewhat of a limitation. Linux xrandr modelines don’t have this limitation, from what I understood. RetroArch also uses the video_refresh_rate setting to synchronize the game’s refresh rate to your display’s refresh rate by resampling the game’s audio rate, it works best when you use the value reported by the Estimated Monitor Framerate after 2048 frames for an accurate sampling. If you are fine tuning the vertical refresh in your modeline, then you probably already know that value anyway. [/li][li]Overscan cropping may need to be disabled in some cores for best results on CRTs, most cores these days are using core options for overscan cropping instead of the global “Crop Overscan” option. You can also use shaders to crop overscan, but it can only be done losslessly on the horizontal axis if using superwide display modes; lossless vertical cropping would require using the monitor’s physical controls. [/li][li]You can create multiple configs or use per-core/per-game overrides to set different display modes for different situations. I generally use per-resolution configs in the config folder that can be hotswapped at runtime with the Load Configuration option or with a shortcut that uses --config commandline switch. Windows probably has a limit on the number of display modes that can be defined in the driver, so be careful about creating too many. From what I’ve read, Nvidia is limited to 30 custom modes, and AMD/ATI is limited to custom 60 modes with unmodded drivers. [/li][li]Using 480p with inserted lines or 120Hz 240p with black frames will cut display brightness by 50%. You will probably want to use a CRT monitor that has an option to increase brightness without affecting black levels, by either increasing the color intensity to maximum or having a CRT that offers a SuperBright setting like the NEC Diamondtron. [/li][/ul]

For the CRT resolution configs that I use, they’re all based on this template which includes all settings needed to run out of the box (for the Windows version at least) and can be quickly modified for a new resolution. Suggested timings for the 3840x480 60Hz mode can be seen here

Thank you for the technical information, this will be a huge help when I set things up.

It also just occurred to me that Windows takes a few seconds to change fullscreen resolutions, so everything really does need to be scaled to the same resolution to work properly. So never mind about my grand idea earlier.

Looking forward to putting all this to use!

I hate to bring this thread back up from the depths, but I just had to thank the both of you for your help. I was able to get up and running in under fifteen minutes thanks to the detailed info. I haven’t had any troubles with contrast—the screen seems about as bright as usual. It might be because I have the refresh rate set to 120 Hz. (I can push 640x480 on my monitor at 180 Hz, but it produces an audible buzz at that frequency.) I might try to get it to work with MAME or I might…not. I’ll think about that later sometime.

Thanks again! You guys are the best.