Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Some pretty heavy duty MAME HLSL changes incoming  (Read 23723 times)

0 Members and 1 Guest are viewing this topic.

bulbousbeard

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 522
  • Last login:August 25, 2015, 11:58:25 pm
  • I want to build my own arcade controls!
Some pretty heavy duty MAME HLSL changes incoming
« on: May 12, 2015, 11:15:39 am »
I'll compile this tonight and see if HLSL is better than OpenGL with the Lottes shader now.

Sunday 3rd May, 2015 at 12:41:05 UTC by imjezze
HLSL shader improvements

- changed shadow mask implementation, shadow count XY now represent the
number of pixel the shadow UV sized tiles will take on the screen
- implemented rotation of the shadow mask texture depending on the
default landscape or portrait view of the screen
- removed prescale and pixel border of the shadow mask texture
- added option to change the shadow UV offset, to reduce the color
bleeding of the shadow mask
- adjusted presets to work with the changed mask implementation
- reduced defocus offset
- improved downsampling for better blurring
- improved alignment of bloom layers (raster and vector)
- applied bloom effect to the render output of screenshot and AVI
recording
- changed curvature effect to fit screen size
- changed scanlines to be not rendered into bloom layers
- changed shadow mask to be not rendered into bloom layers
- changed color floor to not light the bloom layers
- changed shadow mask to not dark the color floor
- added image vignetting simulation and option
- added round screen corner simulation and option
- added screen light reflection simulation and option
- made usage of unused brightness offset (additive)
- removed unused pincushion option
- removed duplicate shadow count Y options
- removed artwork/adapture.png
- added artwork/adapture-grill.png
- added artwork/shadow-mask.png
- added artwork/slot-mask.png
- added hlsl/simple.fx
- removed unused shaders::blit() function
- added shaders::screen_pass() function, which handles the
(raster-)rendering on screen, into screenshot and AVI recording
- added effect:set_bool() function

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #1 on: May 12, 2015, 12:52:42 pm »
It's pretty nice and I quit using opengl for now.

Tell me what you think about these settings because I know that you know your stuff :)

Code: [Select]
hlsl_enable               1
hlslpath                  hlsl
hlsl_prescale_x           8
hlsl_prescale_y           8
hlsl_preset               -1
hlsl_write               
hlsl_snap_width           3200
hlsl_snap_height          1800
shadow_mask_alpha         0.5
shadow_mask_texture       shadow-mask.png
shadow_mask_x_count       6
shadow_mask_y_count       4
shadow_mask_usize         0.1875
shadow_mask_vsize         0.25
shadow_mask_uoffset       0.0
shadow_mask_voffset       0.0
curvature                 0.0
round_corner              0.0
reflection                0.25
vignetting                0.25
scanline_alpha            0.75
scanline_size             1.0
scanline_height           1.0
scanline_bright_scale     2.0
scanline_bright_offset    0.0
scanline_jitter           0.0
defocus                   1.0,0.0
converge_x                0.0,0.0,0.0
converge_y                0.0,0.0,0.0
radial_converge_x         0.0,0.0,0.0
radial_converge_y         0.0,0.0,0.0
red_ratio                 1.05,0.00,0.10
grn_ratio                 -0.10,1.00,0.25
blu_ratio                 -0.25,0.25,1.25
saturation                1.25
offset                    -0.30,-0.20,-0.05
scale                     1.15,1.05,0.90
power                     0.90,0.90,1.15
floor                     0.05,0.05,0.05
phosphor_life             0.5,0.5,0.5

#
# NTSC POST-PROCESSING OPTIONS
#
yiq_enable                0
yiq_cc                    3.59754545
yiq_a                     0.5
yiq_b                     0.5
yiq_o                     1.570796325
yiq_p                     1.0
yiq_n                     1.0
yiq_y                     6.0
yiq_i                     1.2
yiq_q                     0.6
yiq_scan_time             52.6
yiq_phase_count           2

#
# VECTOR POST-PROCESSING OPTIONS
#
vector_length_scale       0.8
vector_length_ratio       40.0

#
# BLOOM POST-PROCESSING OPTIONS
#
vector_bloom_scale        0.3
raster_bloom_scale        0.220
bloom_lvl0_weight         1.000000
bloom_lvl1_weight         0.320000
bloom_lvl2_weight         0.16
bloom_lvl3_weight         0.08
bloom_lvl4_weight         0.04
bloom_lvl5_weight         0.02
bloom_lvl6_weight         0.02
bloom_lvl7_weight         0.01
bloom_lvl8_weight         0.01
bloom_lvl9_weight         0
bloom_lvl10_weight        0

Again all credits go to Jezze, u-man, and anyone else that made this work possible :D

example screens









curvature and round_corner values applied with sliders



Have Fun! :)

abispac

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1528
  • Last login:Yesterday at 10:16:49 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #2 on: May 12, 2015, 02:03:31 pm »
Ive seen that HLSL thing around, can someone explain what this is please.

arquillos

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 46
  • Last login:April 17, 2024, 11:42:44 am
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #3 on: May 12, 2015, 03:39:12 pm »
HLSL is MAME filtering software. It uses heavily the GPU (not CPU) so systems with integrated graphic cards may suffer from lost frames if HLSL is used.

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #4 on: May 12, 2015, 04:18:09 pm »
I still wish you could add screen curvature to vector games. I also wish the color vectors had a shadow mask like on a real color vector monitor. That's really the only thing keeping me from building a Tempest LCD cab at this point.

bulbousbeard

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 522
  • Last login:August 25, 2015, 11:58:25 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #5 on: May 13, 2015, 12:20:40 am »
I experimented with it a bit. It is a big improvement over the previous iteration of HLSL. What hasn't changed, though, is how resolution-hungry HLSL is. The Lottes shader basically looks good at 1080p+.

Until you run HLSL at 4k, you're getting noticeable artifacts in the shadow mask. Even 2560x1440 isn't enough pixels for it.

At 4k, HLSL might be slightly better now just because it has more options and HLSL never had that weird scaling glitch with the Genesis MESS driver that OpenGL has, but if you're not running at that, I'd stick with OpenGL and the Lottes shader.

Here's a shot of my settings for comparison (note that imgur compression just butchers it). I like to soften the image slightly, add a touch more bloom, and basically go for "ideal" color settings.

« Last Edit: May 13, 2015, 01:34:31 am by bulbousbeard »

floob

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 36
  • Last login:January 11, 2023, 04:36:51 pm
  • Looking to buy a pre-made MAME cab.
    • Retrogaming on a Raspberry Pi
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #6 on: May 13, 2015, 04:27:21 pm »
I wish there was somethign as easy to use as this to get OpenGL working
http://mame-hlsl-gallery.blogspot.co.uk/

Do I have to use MAMEUIFX as opposed to MAME?

Is there a guide to getting the lottes shader working with this?

I'm loving the way HLSL makes the games look, but it seems to need tweaking on a per system basis, and the opengl route seems to be a one stop shop?

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #7 on: May 13, 2015, 05:19:01 pm »
Hello Gentleman,

HLSL made a huge step forward, as the MAME devs finally agreed to include Jezze´s HLSL shader improvements. If they wouldnt agree, we had plans to do it with MAMEUIFX exclusively  :D  . We are all happy that this was not needed to do and that Jezze´s work found finally a way into the official MAME source, so that everyone can benefit from it and that coders can maybe even more improve HLSL as it is now on Github.

Jezze did a awesome job here, just look at the changes vs. old HLSL. There are still minor things left from the old version, but i guess the majority will not even notice them. Maximum respect here for this man.... good job, well played  :D

Is HLSL the way forward?

Good question... my main aim was to have shaders that suits to the hardware that a user have.
For low-end resources and graphicscards the community has now the CRT-geom shader, which runs without a big impact on frames, but misses bloom/glow .
For highend users, there is HLSL and Lotte´s shader now, which is slightly more hungry on resources.
I prefer HLSL over Lotte, because you have sliders for playing around and way more parameters to manipulate the final image and you can adjust it to run even on mid-range cards or good integrated graphics like Intel HD 2000 and up. Not to mention that OpenGL has drawbacks, because it will miss additional tweaks that people have done over the time for Direct3D. Open GL also has no options for Vector-shading other than brightness, contrast and gamma vs. many things which you can do with HLSL.

All in all, there where huge improvements over the last three months for LCD and shader fans outthere and I think, we can all be very happy with the results  :D

cheers u-man
« Last Edit: May 13, 2015, 08:06:09 pm by u-man »
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

cmoses

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 718
  • Last login:July 27, 2023, 05:19:00 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #8 on: May 13, 2015, 05:36:05 pm »
Enjoy seeing the new enhancements, will need to give them a try

bulbousbeard

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 522
  • Last login:August 25, 2015, 11:58:25 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #9 on: May 13, 2015, 09:06:03 pm »
Played around with it some more at 4k. I definitely prefer the Lottes shader. It just looks more like a CRT. With HLSL, I just can't get a good defocus value that looks sharp like a CRT but not too sharp like an LCD.

With these improvements, HLSL is better than it was at least. The only problem with the Lottes shader is that MAME has that graphics corruption bug in the Genesis driver with OpenGL.

bulbousbeard

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 522
  • Last login:August 25, 2015, 11:58:25 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #10 on: May 13, 2015, 09:08:29 pm »
I wish there was somethign as easy to use as this to get OpenGL working
http://mame-hlsl-gallery.blogspot.co.uk/

Do I have to use MAMEUIFX as opposed to MAME?

Is there a guide to getting the lottes shader working with this?

I'm loving the way HLSL makes the games look, but it seems to need tweaking on a per system basis, and the opengl route seems to be a one stop shop?

OpenGL/GLSL is actually simpler than Direct 3D/HLSL. The Lottes shader basically looks great in every game with the same settings. It's less of a nuisance than HLSL.

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #11 on: May 13, 2015, 09:37:59 pm »
Played around with it some more at 4k. I definitely prefer the Lottes shader. It just looks more like a CRT. With HLSL, I just can't get a good defocus value that looks sharp like a CRT but not too sharp like an LCD.

With these improvements, HLSL is better than it was at least. The only problem with the Lottes shader is that MAME has that graphics corruption bug in the Genesis driver with OpenGL.

Cant agree with any of your arguments here...especially the Defocus, but I dont own a 4K screen  :P
If you got moire-artefacts then your prescale is to low, try to set it to 8 or higher and see if it gets better.
Without your settings, it is hard to tell, what you are doing wrong, but I am sure it can be better.
Lotte also has only one shadowmask, is way, way more heavy on GPU (and you cant do nothing against this) and if i add all my points posted before, it doesnt have the things I want for proper gaming.

OpenGL/GLSL is actually simpler than Direct 3D/HLSL. The Lottes shader basically looks great in every game with the same settings. It's less of a nuisance than HLSL.

Simply not true... period. With the new HLSL you can do the same.

Everyone has a opinion... and this is mine.
« Last Edit: May 14, 2015, 11:28:57 am by u-man »
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #12 on: May 13, 2015, 10:53:38 pm »
Why can't the aperture grill code in the Lottes shader be implemented in HLSL as an option?

BorgDog

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 436
  • Last login:August 22, 2021, 02:22:52 pm
  • Not a hipster for over 50 years!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #13 on: May 14, 2015, 08:50:06 am »

For low-end resources and graphicscards the community has now the CRT-geom shader, which runs without a big impact on frames, but misses bloom/glow ...


Running low end hardware I was intrigued by this statement.  I've tried HLSL previously and liked the look better, my hardware just can't keep up.  So I googled around looking for how to setup CRT-geom and really couldn't find any straight forward setup instructions.  Does anybody have a link to some instructions on this?  I'm not looking for perfect, just better.

Thanks,
My Projects:
MisSpent Youth a Vigolix bartop,  Little Bastard a rotating tablet/display bartop,
Pin-Dog a mini pin-cab on vpforums.org  Star Wars a wedgehead pincab on vpinball.com

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #14 on: May 14, 2015, 11:14:11 am »
Either install latest MAMEUIFX and configure easily via GUI interface or download the shader here and configure it manually:
https://www.dropbox.com/s/nadpowd7ekwfmat/CRT_Geom.zip?dl=0

There are four files in this archive. The only difference is that the "VERT" version rotates the shadow mask by default.
The idea here is that you use the VERT version in a "vertical.ini" so that it gets used for vertical games only.
Put the files of this zip into a folder of your choice (I recommend a OpenGL named folder inside your MAME installation).
 
To activate the shader, you need to change the following line of your mame.ini OSD VIDEO OPTIONS section :
 
Code: [Select]
video                     opengl
and put the path to the shader in this line of the # OpenGL-SPECIFIC OPTIONS and activate the shader by following line:
Code: [Select]
gl_glsl                   1
gl_glsl_filter            1
glsl_shader_mame0         put the path to the content of the zip-file here\CRT-geom

this is just a example :
 
Code: [Select]
gl_glsl                   1
gl_glsl_filter            1
glsl_shader_mame0         D:\GAMESTATION\OpenGL_MAME_0161_64\glsl\CRT-geom

Make a copy of your mame.ini and put it in the ini folder of your MAME installation, naming it vertical.ini
In your copy, change the path setting to point at CRT-geom_VERT.
 
this is just a example :
 
Code: [Select]
glsl_shader_mame0         D:\GAMESTATION\OpenGL_MAME_0161_64\glsl\CRT-geom_VERT
thats it.... try it and enjoy the shader :) .

Good tutorial for configuring the shader: http://mame32fx.altervista.org/forum/viewtopic.php?f=1&t=184
Credits goes to Hunter K., who did the main part of it .... ;) thx for help, dude.

PS: same applies to Lotte´s shader. You can grab it here, but you need a strong GPU :

https://www.dropbox.com/s/z873a41i5ty2qjc/331873-Lottes_CRT_VERT_SEP_10.zip?dl=0
« Last Edit: May 14, 2015, 11:25:04 am by u-man »
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

BorgDog

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 436
  • Last login:August 22, 2021, 02:22:52 pm
  • Not a hipster for over 50 years!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #15 on: May 14, 2015, 12:41:41 pm »
Awesome, thanks man I'll check it out.
My Projects:
MisSpent Youth a Vigolix bartop,  Little Bastard a rotating tablet/display bartop,
Pin-Dog a mini pin-cab on vpforums.org  Star Wars a wedgehead pincab on vpinball.com

RxBrad

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 188
  • Last login:May 31, 2023, 12:41:00 pm
  • I like burritos.
    • bit.ly/1GDVYUu
    • RxBrad.com
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #16 on: May 14, 2015, 01:23:25 pm »

example screens









curvature and round_corner values applied with sliders



Have Fun! :)

Probably a dumb question...  Your screenshots show SNES, NES, and Sega Genesis games..  How do you get the shaders to work on those?  Which emulator?

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #17 on: May 14, 2015, 01:27:32 pm »
(psssst  MESS is mame's console counterpart......  all things that apply to mame also apply to mess)

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #18 on: May 14, 2015, 02:14:57 pm »

example screens









curvature and round_corner values applied with sliders



Have Fun! :)

Probably a dumb question...  Your screenshots show SNES, NES, and Sega Genesis games..  How do you get the shaders to work on those?  Which emulator?

If you don't know how to compile a GIT pull then wait for 0.162 to release which should be the last Wednesday of this month.

Haze

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1296
  • Last login:October 04, 2023, 08:30:02 am
  • I want to build my own arcade controls!
    • MAME Development Blog
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #19 on: May 14, 2015, 04:05:00 pm »
(psssst  MESS is mame's console counterpart......  all things that apply to mame also apply to mess)

pssst, as of 0.162 MAME will support everything that MESS does out of the box, so your statement becomes redundant, but yeah, people have been enjoying a lot of these effects with the console parts of our code already.

Oh and 0.162 will also support Golden Tee Fore! thanks to the work of Ted Green (thread hijacking, but some people here have asked about it in the past)




« Last Edit: May 14, 2015, 04:07:57 pm by Haze »

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #20 on: May 14, 2015, 04:14:12 pm »
Nice to know after all this time Haze will still come out of hiding to "correct" things I've said that actually aren't incorrect.  :cheers: Nice to hear from you man. 

I haven't decided if I'm excited about the official merger yet or not.  If the listxml output isn't modified to flag all the various systems now it'll be a nightmare because many arcade games had console counterparts and vice-versa, but other than that I'm sure it eliminates a lot of hassle via a singular compile. 

Haze

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1296
  • Last login:October 04, 2023, 08:30:02 am
  • I want to build my own arcade controls!
    • MAME Development Blog
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #21 on: May 14, 2015, 04:53:30 pm »
Nice to know after all this time Haze will still come out of hiding to "correct" things I've said that actually aren't incorrect.  :cheers: Nice to hear from you man. 

I haven't decided if I'm excited about the official merger yet or not.  If the listxml output isn't modified to flag all the various systems now it'll be a nightmare because many arcade games had console counterparts and vice-versa, but other than that I'm sure it eliminates a lot of hassle via a singular compile.

It'll be worked out over time, internally MAME knows if something is a computer / console / arcade, and any intelligent frontend could work out a good guess based on something having a keyboard / coinslot etc.

The majority of games in MESS are still in the softlists (think of them as user removable based media lists) so really the only thing you'll see listed as 'machines' in MAME are the actual consoles alongside the arcade 'machines', so it will be fairly obvious anyway.  There are a handful of games in MESS that were standalone units just like the arcade games, and will be treated as such (things like the Batman TV game) but again it's pretty obvious they're home games because they have no coin slot listed.

As I said tho, any kinks will be worked out over time as we move towards a more hardware driven rather than game driven project.  From a development point of view filtering by hardware used (the ultimate goal) makes more sense anyway; we've seen more and more cases where the arcade hardware is comprised mostly of home parts stuck together, eg. the Golden Tee Fore stuff is PC components (PCI bus, Voodoo, sound system etc.) but driven by a MIPS processor, they're even built on top of a bunch of Open Source software (some have claimed the original games are actually in violation of various Open Source licenses, but I can't comment, never researched the exact software they used)




« Last Edit: May 14, 2015, 05:12:21 pm by Haze »

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #22 on: May 14, 2015, 09:47:03 pm »
Yeah the softlist thing has always kind of annoyed me.  On the one hand I understand it, and it does allow for some flexibility when it comes to homebrew and hacks, but on the other I think it makes MESS more complex than it should be for the average noob to use.  Having one fixed romname for, oh I dunno, Sonic on the genesis that when selected automatically calls the right system and ect for the console would be more ideal from the useability standpoint.  Then you've got systems like the snes where carts contain more custom chips than you can shake a stick at, where game-based selection definitely makes more sense.  Then of course there is the obvious notion that we should have a pan-ultimate list of games, with verified rom crcs and all, for the older systems at this point, yet we don't and mess's softlists aren't exactly helping. 

I'm just saying.... system based sorting only makes sense if you only want to preserve the system hardware.... if you want to preserve the game hardware/software as well, it starts making less sense. 

RxBrad

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 188
  • Last login:May 31, 2023, 12:41:00 pm
  • I like burritos.
    • bit.ly/1GDVYUu
    • RxBrad.com
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #23 on: May 15, 2015, 08:28:39 am »
(psssst  MESS is mame's console counterpart......  all things that apply to mame also apply to mess)

Yeah..  I figured it was something as easy as that.



Never used MESS before, so I'll hold off for the next version of MAMEUIFX that has all of this baked in.

lamprey

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:January 17, 2019, 07:03:11 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #24 on: May 15, 2015, 01:33:27 pm »
I wish there was somethign as easy to use as this to get OpenGL working
http://mame-hlsl-gallery.blogspot.co.uk/

Do I have to use MAMEUIFX as opposed to MAME?

Is there a guide to getting the lottes shader working with this?

I'm loving the way HLSL makes the games look, but it seems to need tweaking on a per system basis, and the opengl route seems to be a one stop shop?
Floob,

I don't want to derail this thread as it is more about the HLSL changes, so maybe it'd be better to start another thread asking for help setting up GLSL. But, are you having a particular issue getting GLSL to work with MAME?

I could be missing a step, but you really just need:
1. a build of MAME that supports GLSL (all new version do by default)
2. the shader files some place
3. then just point the mame.ini at the shader (with GLSL enabled) and you are good to go.

Here is an older thread that may help:
http://www.mameworld.info/ubbthreads/showflat.php?Cat=&Board=mamechat&Number=332320

millercentral

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 99
  • Last login:March 07, 2024, 04:38:47 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #25 on: May 17, 2015, 12:19:28 pm »
Is it possible to simulate monitor curvature with OpenGL/Lottes like it is with the HLSL implementation?

cubadoo1

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 2
  • Last login:May 24, 2015, 04:07:11 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #26 on: May 19, 2015, 10:51:32 am »
HI FOLKS new to this forum . here are my settings for 161 mame . i use a 2560x1440 ips monitor and i think theses settings look nice  :)

# DIRECT3D POST-PROCESSING OPTIONS
#
hlsl_enable               1
hlslpath                  hlsl
hlsl_prescale_x           6.4286
hlsl_prescale_y           6.4286
hlsl_preset               -1
hlsl_write                1
hlsl_snap_width           2560
hlsl_snap_height          1440
shadow_mask_alpha         0.30
shadow_mask_texture       Real_Scanlines.png
shadow_mask_x_count       1
shadow_mask_y_count       1
shadow_mask_usize         0.375
shadow_mask_vsize         0.25
shadow_mask_uoffset       0.0
shadow_mask_voffset       0.0
curvature                 0.15
round_corner              0.03
reflection                0.03
vignetting                0.03
scanline_alpha            1.0
scanline_size             1.0
scanline_height           1.050
scanline_bright_scale     1.1
scanline_bright_offset    0.30
scanline_jitter           0.0
defocus                   3.5,3.5
converge_x                -0.3,0.0,0.3
converge_y                -0.3,0.0,0.3
radial_converge_x         0.0,0.0,0.0
radial_converge_y         0.0,0.0,0.0
red_ratio                 1.0,0.0,0.0
grn_ratio                 0.0,1.0,0.0
blu_ratio                 0.0,0.0,1.0
saturation                1.01
offset                    -0.15,-0.15,-0.15
scale                     1.15,1.15,1.15
power                     1.05,0.95,0.8
floor                     0.02,0.02,0.02
phosphor_life             0.2,0.2,0.2

#
# NTSC POST-PROCESSING OPTIONS
#
yiq_enable                0
yiq_cc                    3.59754545
yiq_a                     0.5
yiq_b                     0.5
yiq_o                     1.570796325
yiq_p                     1.0
yiq_n                     1.0
yiq_y                     6.0
yiq_i                     1.2
yiq_q                     0.6
yiq_scan_time             52.6
yiq_phase_count           2

#
# VECTOR POST-PROCESSING OPTIONS
#
vector_length_scale       0.8
vector_length_ratio       500.0

#
# BLOOM POST-PROCESSING OPTIONS
#
vector_bloom_scale        0.35
raster_bloom_scale        0.115
bloom_lvl0_weight         0.90
bloom_lvl1_weight         0.5
bloom_lvl2_weight         0.19
bloom_lvl3_weight         0.17
bloom_lvl4_weight         0.15
bloom_lvl5_weight         0.14
bloom_lvl6_weight         0.13
bloom_lvl7_weight         0.12
bloom_lvl8_weight         0.11
bloom_lvl9_weight         0.10
bloom_lvl10_weight        0.09

By the way what does the vignetting option do?

cubadoo1

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 2
  • Last login:May 24, 2015, 04:07:11 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #27 on: May 20, 2015, 05:44:57 am »
I experimented with it a bit. It is a big improvement over the previous iteration of HLSL. What hasn't changed, though, is how resolution-hungry HLSL is. The Lottes shader basically looks good at 1080p+.

Until you run HLSL at 4k, you're getting noticeable artifacts in the shadow mask. Even 2560x1440 isn't enough pixels for it.

At 4k, HLSL might be slightly better now just because it has more options and HLSL never had that weird scaling glitch with the Genesis MESS driver that OpenGL has, but if you're not running at that, I'd stick with OpenGL and the Lottes shader.

Here's a shot of my settings for comparison (note that imgur compression just butchers it). I like to soften the image slightly, add a touch more bloom, and basically go for "ideal" color settings.


Hi bulbousbeard can you post your ini settings at 4k for me to try please?

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #28 on: July 20, 2015, 05:04:32 pm »
I finally got a chance to play with the new HLSL in the latest releases. It's great for raster games but vector games seemed to have regressed. The new bloom effect is sterile as hell and looks nothing like a Vector monitor. How did this happen?

Phreakwars

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 592
  • Last login:Yesterday at 11:26:11 pm
  • Waka-Waka
    • forum.arcadecontrols.com/index.php/topic,146325.0.html
    • My Facebook Page
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #29 on: July 21, 2015, 02:01:59 am »
HLSL is MAME filtering software. It uses heavily the GPU (not CPU) so systems with integrated graphic cards may suffer from lost frames if HLSL is used.

I've toyed around with it as well. On my main PC, I use a GeForce GTX 960, so I have no issues at all with it slowing me down. On the cabinet I'm building I'm using integrated graphics from the A-6 5400 CPU. I'm hoping it will be decent enough to use HLSL. I wouldn't try it with Intel integrated, or even GeForce integrated, but AMD has really surprised me with their APU's performance. I've built several PC's utilizing them but haven't tried MAME with HLSL yet... guess I'll find out later this week how it performs.

lamprey

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:January 17, 2019, 07:03:11 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #30 on: July 21, 2015, 12:15:28 pm »
I finally got a chance to play with the new HLSL in the latest releases. It's great for raster games but vector games seemed to have regressed. The new bloom effect is sterile as hell and looks nothing like a Vector monitor. How did this happen?
I didn't seem like it changed that much. But, you can still adjust it to look like it did before. It never looked much like a real vector monitor anyway so, until the dev team improves the vector simulation, it is what it is.

yotsuya

  • Trade Count: (+21)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19956
  • Last login:Today at 12:09:41 am
  • 2014 UCA Winner, 2014, 2015, 2016 ZapCon Winner
    • forum.arcadecontrols.com/index.php/topic,137636.msg1420628.html
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #31 on: July 21, 2015, 01:08:18 pm »
I bought a dedicated Asteroids because few things are cooler than the streaks and glow of the bullet trails on an authentic vector monitor.
***Build what you dig, bro. Build what you dig.***

lamprey

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:January 17, 2019, 07:03:11 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #32 on: July 21, 2015, 01:16:28 pm »
I bought a dedicated Asteroids because few things are cooler than the streaks and glow of the bullet trails on an authentic vector monitor.
Same. I picked up an Asteroids Deluxe a few weeks ago. The 3D affect with the mirror and the black-light.. way cool.

floob

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 36
  • Last login:January 11, 2023, 04:36:51 pm
  • Looking to buy a pre-made MAME cab.
    • Retrogaming on a Raspberry Pi
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #33 on: July 21, 2015, 02:48:48 pm »
I bought a dedicated Asteroids because few things are cooler than the streaks and glow of the bullet trails on an authentic vector monitor.

Thats what makes me want to buy a Vectrex


dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #34 on: July 21, 2015, 03:19:13 pm »
I didn't seem like it changed that much. But, you can still adjust it to look like it did before. It never looked much like a real vector monitor anyway so, until the dev team improves the vector simulation, it is what it is.

All the bleed and flicker is gone. I played with the settings for quite a while and couldn't get it back.

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #35 on: July 21, 2015, 03:22:52 pm »
I bought a dedicated Asteroids because few things are cooler than the streaks and glow of the bullet trails on an authentic vector monitor.

The B&W vectors are especially impressive, I would love a Star Castle.

lamprey

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:January 17, 2019, 07:03:11 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #36 on: July 21, 2015, 03:37:54 pm »
I didn't seem like it changed that much. But, you can still adjust it to look like it did before. It never looked much like a real vector monitor anyway so, until the dev team improves the vector simulation, it is what it is.

All the bleed and flicker is gone. I played with the settings for quite a while and couldn't get it back.
You can try looking at this thread from mameworld. Uman posted some settings that might help. I'm not sure about the flicker as I don't use that option, but the bloom and such should still be doable:
http://www.mameworld.info/ubbthreads/showflat.php?Cat=&Number=341593
 

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #37 on: July 21, 2015, 05:11:09 pm »
Yeah, it looks like you just have to adjust it above 1.0 for the bleed to start. You can't do that with the slider controls any more, it has to be done in the .ini file. It's a lot more GPU intensive though, I wonder why.
« Last Edit: July 21, 2015, 05:16:43 pm by dmckean »

Xiaou2

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4098
  • Last login:November 12, 2023, 05:41:19 pm
  • NOM NOM NOM
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #38 on: July 23, 2015, 10:59:38 pm »
You may wish to consider selectable monitor models...  meaning... a user can select a certain monitor type, and there are settings that match that particular monitors specs.

 The idea being similar to how they make guitar effects pedals these days, that simulate various kinds of Amps.

 For example, there are monitors with lower dot pitch than others.
 Some monitors have different color output specs
 Some have different shadowmask patterns

 And because there are now console games in mame...  one can have things like:

 Amiga 1024s monitor
 C64 1702 monitor
 etc.
« Last Edit: July 23, 2015, 11:01:22 pm by Xiaou2 »

8BitMonk

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 989
  • Last login:October 19, 2023, 05:27:00 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #39 on: July 24, 2015, 12:06:28 am »
Still prefer the Lottes shader over any HLSL settings I've seen.
Games: Asteroids Deluxe | Atomiswave | Centipede | Championship Sprint | Defender | Donkey Kong | Dig Dug | Frogger | Ikari Warriors | Missile Command | Pac-Man | Pole Position | Robotron | Spy Hunter | Tempest | Super Mario Strikers

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #40 on: August 07, 2015, 10:10:15 am »
And I give a ---gosh-darn--- ---steaming pile of meadow muffin---, if you prefer Lotte over HLSL, as Lotte is GLSL and you will have problems with correct V-Sync and Tearing in general. Not to mention Vector Games, with nö options at all.
« Last Edit: August 07, 2015, 10:14:20 am by u-man »
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #41 on: August 19, 2015, 08:27:38 pm »
And I give a ---gosh-darn--- ---steaming pile of meadow muffin---, if you prefer Lotte over HLSL, as Lotte is GLSL and you will have problems with correct V-Sync and Tearing in general. Not to mention Vector Games, with nö options at all.

It's not that of a big deal, just force it externally in the driver. A D3D version of the Lottes shader would be great though. I know it's not an accurate it representation of a CRT but it fixes the look of pixel art, is pretty convincing and I think that's what most people want anyway.

I've been playing MAME .163 and the HLSL Vector options getting Tac/Scan working for my cab and I'm now pretty impressed with the new glow code. It's really nice. I wish the ridiculously high default value of 500 for Vector Attenuation Length Limit could be fixed. Somewhere between 25-80 would be much more appropriate. It's hard to tell what the effect even does when it's set that high.

Can whoever did these changes add a realistic flicker effect for Vector games? Would robbing the code from RobeeJ's vector diff be that hard? Vector games look a lot more convincing with that flicker and it's why I'm using vector diff over HLSL on my cab. I'm only using HLSL for Tac/Scan because Tac/Scan crashes on MAME .144.

Eventually I think the Vector code needs a lot of changes. It'll never look like the real thing until MAME tracks the amount of time each line/dot is being drawn in each frame. Without that you can't get the super bright dots/lines in B&W vector games. It'd also be nice to do a shadow mask for color vector games.

epetti

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 344
  • Last login:September 14, 2023, 10:15:20 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #42 on: October 12, 2015, 01:45:49 pm »
Now that there's pretty good default settings in MAME. Are you still finding a need to do a lot of per game ini tweaking based on the system and the monitor that it used in the original arcades? I know posts in other forums from older versions of MAME definitely emphasized heavily needing per game (or bios) ini files, not just for resolutions but to get gamma and color settings feeling correct for the game. Didn't know if that was still as much of an issue?

Also, I'm starting to setup my HLSL settings. I have a 20" 1600x1200 LCD monitor. At this point, what HLSL settings are specifically resolution dependent on a person's monitor that need adjustment from the defaults?

lamprey

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:January 17, 2019, 07:03:11 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #43 on: October 14, 2015, 01:21:07 pm »
Now that there's pretty good default settings in MAME. Are you still finding a need to do a lot of per game ini tweaking based on the system and the monitor that it used in the original arcades? I know posts in other forums from older versions of MAME definitely emphasized heavily needing per game (or bios) ini files, not just for resolutions but to get gamma and color settings feeling correct for the game. Didn't know if that was still as much of an issue?

Also, I'm starting to setup my HLSL settings. I have a 20" 1600x1200 LCD monitor. At this point, what HLSL settings are specifically resolution dependent on a person's monitor that need adjustment from the defaults?
Obviously, you can tweak all that you want. But, realistically, for raster games, you just need to figure out which mask you want to use (shadow, slot, aperture) and set the shadow_mask_x/y_count and shadow_mask_u/vsize appropriately. Additionally, you'll probably want to up the percale value to something greater than 6 too.

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #44 on: November 02, 2015, 06:50:07 am »
And I give a ---gosh-darn--- ---steaming pile of meadow muffin---, if you prefer Lotte over HLSL, as Lotte is GLSL and you will have problems with correct V-Sync and Tearing in general. Not to mention Vector Games, with nö options at all.

It's not that of a big deal, just force it externally in the driver. A D3D version of the Lottes shader would be great though. I know it's not an accurate it representation of a CRT but it fixes the look of pixel art, is pretty convincing and I think that's what most people want anyway.

I've been playing MAME .163 and the HLSL Vector options getting Tac/Scan working for my cab and I'm now pretty impressed with the new glow code. It's really nice. I wish the ridiculously high default value of 500 for Vector Attenuation Length Limit could be fixed. Somewhere between 25-80 would be much more appropriate. It's hard to tell what the effect even does when it's set that high.

Can whoever did these changes add a realistic flicker effect for Vector games? Would robbing the code from RobeeJ's vector diff be that hard? Vector games look a lot more convincing with that flicker and it's why I'm using vector diff over HLSL on my cab. I'm only using HLSL for Tac/Scan because Tac/Scan crashes on MAME .144.

Eventually I think the Vector code needs a lot of changes. It'll never look like the real thing until MAME tracks the amount of time each line/dot is being drawn in each frame. Without that you can't get the super bright dots/lines in B&W vector games. It'd also be nice to do a shadow mask for color vector games.

Well i guess your prayers where heard :D ...  Jezze did huge improvements for vector games, and nearly everything you said is covered by HLSL now...
Timing for each frame, will be a ridiculous amount of work... i personally dont see this happening for the next (maybe) years, but everything else you said is done :D .... and we will improve it further, once a plan is build for future improvements... be patient ;) .
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

epetti

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 344
  • Last login:September 14, 2023, 10:15:20 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #45 on: November 02, 2015, 12:03:44 pm »
I was reading the release notes. How much will upgrading from 0.165 to 0.167 mess up existing settings? I was seeing things like separate bloom settings now being gone. Will all ini files including per game ones need to be tweaked to account for the changes?

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #46 on: November 02, 2015, 07:58:50 pm »
You can use vector.ini and raster.ini.... so copy the relevant bits into those files. 

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #47 on: March 06, 2016, 02:23:17 am »
Well i guess your prayers where heard :D ...  Jezze did huge improvements for vector games, and nearly everything you said is covered by HLSL now...
Timing for each frame, will be a ridiculous amount of work... i personally dont see this happening for the next (maybe) years, but everything else you said is done :D .... and we will improve it further, once a plan is build for future improvements... be patient ;) .

All this certainly didn't go unnoticed by me. Vector games look better than ever. And I know timing for each frame will be impossibly hard, but it's the only way we're going to get B&W vectors behaving like the real thing.

I wish I could contribute, but I'm no help.

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #48 on: March 06, 2016, 03:41:16 am »
Speaking of vector and other presets. Jezze has been kind enough to add presets to his repo ---> https://github.com/ImJezze/mame/tree/master/ini

I'm also pretty happy with what I'm using at the moment mostly taken from Jezze's settings ---> http://pastebin.com/kUGFXkNV

Key seems to be correct balance of screen brightness, contrast, and gamma depending on machine like nes, snes, or game.

Richardgregory

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 360
  • Last login:November 17, 2021, 01:15:10 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #49 on: March 09, 2016, 12:51:26 pm »
Where can I get Jezze's shader for HLSL?  Or any excellent shader for that matter. 

Appreciate any help.


Richardgregory

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 360
  • Last login:November 17, 2021, 01:15:10 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #50 on: March 09, 2016, 12:52:58 pm »
Lotte's shader is only for GLSL correct?

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #51 on: March 09, 2016, 05:06:31 pm »
Jezze's work is in the newer versions of MAME. The Lotte's shader is only for GLSL.

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #52 on: March 09, 2016, 07:09:42 pm »
Where can I get Jezze's shader for HLSL?  Or any excellent shader for that matter. 

Appreciate any help.

Latest official MAME is your best bet because it will contain all the work he is doing and it will have the correct .fx files

Richardgregory

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 360
  • Last login:November 17, 2021, 01:15:10 pm
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #53 on: March 09, 2016, 10:50:25 pm »
I tried the settings as below, but I'm finding the screen way too dark even when adjusting the brightness and contrast.  How can I make it brighter?  Not sure what setting in HLSL will do that.



Speaking of vector and other presets. Jezze has been kind enough to add presets to his repo ---> https://github.com/ImJezze/mame/tree/master/ini

I'm also pretty happy with what I'm using at the moment mostly taken from Jezze's settings ---> http://pastebin.com/kUGFXkNV

Key seems to be correct balance of screen brightness, contrast, and gamma depending on machine like nes, snes, or game.

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #54 on: March 10, 2016, 12:35:56 am »
Are you talking about a vector game or raster game?

You could try cranking up the Gamma or Bloom Scale settings.

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #55 on: March 18, 2016, 02:55:57 am »
A very big update and very nice work by Jezze :)

https://github.com/mamedev/mame/pull/724

For those that Don't or can't compile GIT then you can expect these in the next release

Game Boy preset -->


Game Boy Advance preset -->


Vector preset -->


Quote

This is quite a big update that mainly changes the size used for render targets and re-introduces the correct usage of texture coordinates instead screen coordinates by the shaders.

Refactored render targets

    HLSL now uses NPOT sized render targets (this breaks the compatibility with graphics cards based on R300/R400/NV30, anno 2005 and older)
    HLSL render targets now have the exact size of the screen
    removed HLSL pre-scale factor
    improved overall performance (based on the previously required pre-scale factor, you might notice a 5-50% speed-up depending on your graphics card, more if you used a higher pre-scale factor)
    improved shadow mask quality (pixel-perfect) in screen-mode
    HLSL now uses a sharp bi-linear interpolation to pre-scale textures to screen size, based on [Themaister's] implementation
    added proper texture coordinates to vector screen quad
    removed ./hlsl/artwork_support folder (the default shaders supports artworks again)
    known issue: cocktail mode for vector screen looks wrong

Improved scanline simulation

    changed the amount of scanline darkness, a setting of 1.0 now becomes fully black (to get the same result as before half your current setting)
    added scanline variation, which makes the scanline height dependent on the brightness of the underlying color
    the amount of the scanline brightness and overdrive now depends on the scanline darkness
    renamed 'Scanline Screen Height' to 'Scanline Screen Scale' and 'Scanline Indiv. Height' to 'Scanline Height'

Refactored bloom

    fixed dimensions of bloom targets, which results in a much better alignment especially for games with very low resolution (therefore current bloom settings might look a little less intense than before)
    reduced blur width for raster screen
    added usage of shadow u/v option for source tile mode

HLSL presets

    added general presets for raster and vector screens
    added example presets for Game Boy (monochrome LCD) and Game Boy Advance (color LCD)
    options are now reset to loaded preset when game is closed

MAME Testers #06144: Fixed infinite loop

    fixed infinite loop while building slider list, when more than one window was created

p.s. The fix for #06144 is more of a workaround, because it doesn't achieve the intended functionality, but at least the application does not freeze anymore

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1471
  • Last login:April 22, 2024, 03:17:30 am
  • retro maniac
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #56 on: March 18, 2016, 03:30:21 am »
That very nice. On 4K monitor vector will be almost 100% auntentic :)

dmckean

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 729
  • Last login:January 13, 2024, 08:50:41 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #57 on: March 18, 2016, 12:08:58 pm »
Now they need to rewrite the way vacuum fluorescent displays games are handled in MAME so we can get those to glow too. Right now they use static artwork files.

cmoses

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 718
  • Last login:July 27, 2023, 05:19:00 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #58 on: March 18, 2016, 12:51:53 pm »
Looking forward to these changes in the next version of mame.


Sent from my iPad using Tapatalk

Nocturnaloner

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 212
  • Last login:May 05, 2016, 12:39:53 pm
  • AARRRRcade!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #59 on: March 18, 2016, 08:01:53 pm »
I have a really dumb, basic question that's probably been answered a million times:  In what order do .ini files take precedence, and are they additive?  In other words, can I put my controller settings in mame.ini with no hlsl settings,  then only my appropriate hlsl settings in raster.ini and vector.ini and nothing else in those files?

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #60 on: March 18, 2016, 09:00:17 pm »
The specific ini files override what's in mame.ini and anything inserted at command line trumps the both of those.

Nocturnaloner

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 212
  • Last login:May 05, 2016, 12:39:53 pm
  • AARRRRcade!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #61 on: March 18, 2016, 09:20:32 pm »
The specific ini files override what's in mame.ini and anything inserted at command line trumps the both of those.

That makes sense.  What if my control settings are in mame.ini, and my hlsl settings are in vector.ini.  If I start a vector game, will my control settings revert to default if there are none in vector.ini?

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #62 on: March 18, 2016, 10:37:58 pm »
The specific ini files override what's in mame.ini and anything inserted at command line trumps the both of those.

That makes sense.  What if my control settings are in mame.ini, and my hlsl settings are in vector.ini.  If I start a vector game, will my control settings revert to default if there are none in vector.ini?

No. It will still use what's set in mame.ini


Nocturnaloner

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 212
  • Last login:May 05, 2016, 12:39:53 pm
  • AARRRRcade!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #63 on: March 18, 2016, 10:40:20 pm »
The specific ini files override what's in mame.ini and anything inserted at command line trumps the both of those.

That makes sense.  What if my control settings are in mame.ini, and my hlsl settings are in vector.ini.  If I start a vector game, will my control settings revert to default if there are none in vector.ini?

No. It will still use what's set in mame.ini

Got it.  Thanks!

u-man

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 87
  • Last login:November 29, 2023, 05:57:09 am
  • I want to build my own arcade controls!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #64 on: March 21, 2016, 07:07:59 am »
That very nice. On 4K monitor vector will be almost 100% auntentic :)
I wouldnt go that far, as this update will not change much for Vector-games. This update will mainly improve Performance, as the prescale factors are automatically calculated and some functions for older cards are cutoff, that prevented improved Performance on newer cards.

Scanlines will behave much more like the real ones. Darker areas will have thinner scanlines and brighter areas will have bigger scanlines. We examined this phenomenon on Real scanlines and Jezze did a good job implementing this fact.

So these two things and the initial presets are the main points of this update.
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music."

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1471
  • Last login:April 22, 2024, 03:17:30 am
  • retro maniac
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #65 on: March 21, 2016, 10:06:15 am »
I'm not planning to buy 4k monitor anytime soon. We will see in future how effects will progress. After all we now have BGFX that could have much more possibilities than HLSL.

Josef1975

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:July 09, 2021, 06:01:15 am
    • MY ARCADE CABINET
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #66 on: April 02, 2016, 01:12:20 pm »
after upgrade to mame 0.172 I  lost monitor curvature in my hlsl preset.
curvature is set to 0.3 (as before theupgrade).
someone can help me or post new mame hlsl preset to try?
(the look of my games has changed a bit now an without curvature so I want to try new presets)
thanks!

edit: solved...
need to modify also raster.ini instead of mame.ini
« Last Edit: April 02, 2016, 03:41:03 pm by Josef1975 »

B2K24

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 216
  • Last login:May 10, 2023, 09:33:05 pm
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #67 on: April 02, 2016, 03:55:45 pm »
after upgrade to mame 0.172 I  lost monitor curvature in my hlsl preset.
curvature is set to 0.3 (as before theupgrade).
someone can help me or post new mame hlsl preset to try?
(the look of my games has changed a bit now an without curvature so I want to try new presets)
thanks!

backup your old mame.ini (in case it's needed for something) and execute mame64-cc

After doing that open mame.ini that was just created (not your backup) and you'll notice
Code: [Select]
inipath                   .;ini;ini/presets
In your mame folder of 172 you should notice a presets folder (MAME\ini\presets) these will take effect when you have HLSL enabled

I would recommend opening the raster.ini and making these changes

Code: [Select]
defocus                   0.8,0.0
saturation                1.20
floor                     0.0,0.0,0.0
phosphor_life             0.0,0.0,0.0
bloom_scale               0.20

In mame.ini I also changed gamma to 0.9




Nocturnaloner

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 212
  • Last login:May 05, 2016, 12:39:53 pm
  • AARRRRcade!
Re: Some pretty heavy duty MAME HLSL changes incoming
« Reply #68 on: April 03, 2016, 02:54:04 am »
Starting with a completely fresh .0172 install, turning on HLSL gives no filtering or slider controls.  I selected Direct3D video, and turned off bicubic filtering.  Any suggestions?