Sony Megatron Colour Video Monitor

Looks like you can specify different backends with command line switches:

The d3d option in mame is obsolete and is about to be removed (so they say). The best option to be used in modern hardware is -video bgfx -bgfx_backend d3d11 , possibly -video bgfx -bgfx_backend d3d12

source: some guy on reddit

2 Likes

Trying to understand here: This means I won’t be able to use this shader at all?

It’s a fairly recent version of MAME, 0.249.

May I ask how you conclude that it “MAME itself sounds like its not using Directx 10+”?

Hope there’s a workaround. :slight_smile:

1 Like

May need to try that then in the MAME ini file I suppose.

1 Like

Ok so this is interesting, while in MAME, I open reshade and go to statistics. There it shows the API as D3D9. Is that the API MAME uses or is that the API I selected when setting up reshade? Because I was sure I select Direct X 10/11/12

1 Like

it looks like mame uses dx9 unless you specifically tell it to use otherwise, so yeah, your reshade is probably fine if you set it up to use a higher level and it’s mame that’s using an older one.

2 Likes

Yup that sounds like the fix - thanks @hunterk!

2 Likes

Hi again. I’ve been trying to ‘upgrade’ my direct x version of Mame from what we believe it is now, D3D9, but whenever I modify this line below in my MAME ini file to something other than ‘auto’, reshade simply doesn’t work at all, meaning hitting “home” button doesn’t bring up the reshade window. So if I change below where it says D3D to D3D10 for example, then I cannot open reshade even though I know for a fact I selected the Direct X 10/11/12 API during reshade initial setup. When I change to auto, reshade works but the Megatron shader fails to compile.

OSD VIDEO OPTIONS

video D3D

numscreens 1

window 0

maximize 1

waitvsync 1

syncrefresh 0

monitorprovider auto

I guess it looks like I’m saying I’ve no idea how to modify my Mame Direct X setting to something higher than D3D9.

1 Like

Hmm not sure on what mame is doing. Reshade dumps a reshade modified dxgi.dll into the directory of the mame.exe and if its using directx it should use that dll. the only time that wont work is if the dxgi.dll is 32bit and mame is 64bit or vice versa.

I have an idea. Why not just use the MAME Core from RetroArch and the slangp version of Sony Megatron Color Video Monitor?

2 Likes

Just got it working - change ‘video d3d’ to ‘video bgfx’ and add the line that @hunterk posted above i.e bgfx -bgfx_backend d3d11. Or do as @cyber said and just use retroarch’s mame.

2 Likes

I got it to work now, but some other things are now not entirely clear, chiefly that with the Megatron shader and autoHDR both enabled, the picture is incredibly desaturated, almost black and white, judging by these Final Fight screenshots. Disabling AutoHDR and switching to SDR in the Megatron shader params alleviates things considerably, but I should be able to use HDR methinks.

I

My monitor is an HDR capable monitor, but how would the monitor pick up that I’m displaying HDR content? With Retroarch you can enable HDR in RA, but I don’t use Retroarch for Mame. I like my high scores to actually save. So how can reshade tell my monitor to switch to HDR?

Got a few more questions, but will leave those for tomorrow.

1 Like

This almost certainly that the AutoHDR addon isnt working for some reason. Have you added it into reshade - can you see that its active? You will need to have HDR on in Windows - see display properties. We’ll get you there. You might need to edit the shader as well as reshade is not as good as retroarch in providing different resolution support but we can get to that after you fix the hdr problem.

Anyone else noticed an update to this shader has broken HDR with vulkan? The colours are washed out unless I select SDR in the parameters, yet the screen is running with full HDR brightness. DX11/12 are fine. Older megatron presets are working fine using vulkan so I compared files and the main difference is this: scale_type_x2 = “viewport” scale_x2 = “1.000000” scale_type_y2 = “viewport” scale_y2 = “1.000000”. I removed that section from my preset then HDR worked normally again… very odd.

3 Likes

Ok so thats really odd - I dont even remember adding that. Ill take a look and update/fix this. Thanks for letting me know!!!

This probably was @hunterk when he updated the repo presets so that viewport like passes were set to viewport. This is so that when someone uses the append action to append another preset on top.

That said, it’s not something that “should” affect anything, but obviously from your tests it does affect it.

2 Likes

Back again. yeah, so HDR was not enabled through Windows 11. I changed that now, I can select HDR on my monitor. Meanwhile, I confirm AutoHDR addon seems to function, at least it is there in reshade and I can select it and modify params. Unfortunately, things are still depressingly dim and non-vibrant. Like playing the Saving private Ryan version of Arcade games. :slight_smile:

TV HDR

Home tab reshade

Statistics tab reshade (Note it says D3D11 now under API), which is funny because in my mame ini under OSD Video options I only added bgfx under ‘video’ and none of that other stuff Hunterk mentioned yesterday, but my megatron shader no longer gave me a ‘failed to compile’ error so I guess all is well in that regard.

1 Like

Right so thats not the autohdr.addon you are looking at thats the autohdr.fx which is a shader you can use if you’re not using the SonyMegatron.fx. Remove the autohdr.fx and go and look at the ‘add-ons’ tab instead.

Hm, ok interesting. looks like this is where things may go awry. Please check the screenshot. !

IMG_20230524_144826|690x317

I navigated to where my addon pack is where it says addon search path, then went back to home tab of reshade, saw autoHDR.fx and assumed that was the addon and all was ok. As you can see, there is nowhere in the addon tab where I can choose HDR even though I use reshade 5.8.0. addon version

Not sure where the issue is.

1 Like

Ok wow things are improving, in that same screenshot I now do see the HDR checkmark. !

IMG_20230524_150338|690x317

But it is also giving me error loading addon message. :thinking:

here is the error from the log

I think I get it. my addon being used is the 64 bit version and that works, but in that directory there is also the 32 version and I guess that’s throwing up an error, but it’s an error which I assume has no impact whatsoever for me. Right?

1 Like

Hmm, I don’t think that would be me, since I only touched the base megatron preset and the crt-sony-megatron-aeg-CTV-4800-VT-hdr.slangp preset (for some reason lol; I probably did one and then looked at the number of others and was like ‘eff it’) and I only added the combined x+y scaling, not separated:

but in any event, yeah, dunno why that would have any effect :confused:

3 Likes