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: Issue with CHD games and multithreading  (Read 3845 times)

0 Members and 1 Guest are viewing this topic.

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Issue with CHD games and multithreading
« on: February 15, 2016, 05:32:39 pm »
I'm sure this has been answered but I can't find it, sorry.

Some games, in particular CHD based games that switch resolutions between when their BIOS loads and when Gameplay begins, end up in the background (ie I need to Alt-Tab over to them rather than them being onscreen).  I do not recall this issue with previous versions of Mame I have used over the years and it makes it difficult for guests using these games.

Example games:
- Blitz2K (I fixed this one but do not know what I did exactly).
- Mace (not working at all at the moment - probably since I fixed Blitz)
- WG3DH (Wayne Gretzky 3D hockey) - Currently has this issue.

I've played back and forth with many options (lock/unlock supported modes, lock/unlock system modes primarily, I believe this is how Blitz2K was fixed and probably how I broke MACE). 

I am attaching the log for WG3DH, I just need some help understanding the issue so I can go ahead and create inis for each affected game since there seems not to be a single fix.

Thanks!


Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7463
  • Last login:July 01, 2025, 01:29:14 pm
  • Quote me with care
Re: Issue with CHD games and multithreading
« Reply #1 on: February 15, 2016, 05:45:04 pm »
Disable multithreading for those games.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #2 on: February 15, 2016, 06:02:43 pm »
Disable multithreading for those games.

Ok so that solves the issue I asked about but it results in WG3DH running at about twice its proper speed. 

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7463
  • Last login:July 01, 2025, 01:29:14 pm
  • Quote me with care
Re: Issue with CHD games and multithreading
« Reply #3 on: February 15, 2016, 06:24:25 pm »
Apart from multithreading are you using anything different from default options such as frame_delay?
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #4 on: February 15, 2016, 06:54:52 pm »
Frame Delay is Zero,

Here are some items I am not completely sure about:
lock_system_modes         1
lock_unsupported_modes    1
refresh_dont_care         0

interlace                 1
doublescan                1
cleanstretch              2
changeres                 1
frame_delay               0
vsync_offset              0
black_frame_insertion     0
throttle                     1


An interesting thing with WG3DH is it needs both multithreading and triplebuffering enabled individually (to run at proper speed).  I thought that multithreading would use triplebuffering automatically but I guess only if its enabled?
« Last Edit: February 15, 2016, 06:56:53 pm by BuZz880 »

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1537
  • Last login:Yesterday at 11:02:43 am
  • retro maniac
Re: Issue with CHD games and multithreading
« Reply #5 on: February 19, 2016, 04:57:53 am »
I already mentioned problems with many 3D games here and http://forum.arcadecontrols.com/index.php/topic,143528.0.html

Problem is probably how driver and video, audio parts was written by author (in most cases Aaron Giles). The same games does not work correctly even in official mame using synctorefresh and disabled throttling.

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #6 on: February 19, 2016, 08:58:56 am »
No man. I can fix the speed issue, game plays pretty well. It's just the issue mentioned a couple posts back where the game launches in the background and I have to alt-tab over to it. Calamity told me how to fix that but then I got the 200% speed so can't use that fix so I'm still hoping someone chimes in on this background issue. 

As for your post I haven't tried Carnevil but pretty sure the other games you mention run at the proper speed for me. I have same video card as you. You need multithreading 1 and triplebuffer 1. Triplebuffer 0 will not work. Let me know if you'd like me to double check anything on those games. 

Edit: Confirmed: Gauntletdl runs at right speed

Sent from my Nexus 6P using Tapatalk

« Last Edit: February 19, 2016, 08:03:10 pm by BuZz880 »

haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1537
  • Last login:Yesterday at 11:02:43 am
  • retro maniac
Re: Issue with CHD games and multithreading
« Reply #7 on: February 20, 2016, 07:01:46 am »
BuZz880, what hardware You use? It's hard to get 100% even on G3258 4,2 GHz with standard mame not to mention groovymame.

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #8 on: February 20, 2016, 09:55:42 am »
I didn't check if it's 100%. I played it for half an hour with my daughter and it seemed fine to me.

I thought your complaint was 200% speed? I don't get anywhere near that.

I gave my hardware a couple posts back.

Sent from my Nexus 6P using Tapatalk


haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1537
  • Last login:Yesterday at 11:02:43 am
  • retro maniac
Re: Issue with CHD games and multithreading
« Reply #9 on: February 20, 2016, 10:06:59 am »
The problem with Carnevil and some other games was changing speed not only during gameplay but also during title, highscore. For example everything is fine on title screen but in play game goes unthrottled even without mt option.

http://forum.arcadecontrols.com/index.php/topic,143528.0.html

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #10 on: February 20, 2016, 10:15:13 am »
I haven't tried Carnevil. But I do not have weird speed-up issues that I am aware of as long as I keep MT and TB enabled.

Sent from my Nexus 6P using Tapatalk


haynor666

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1537
  • Last login:Yesterday at 11:02:43 am
  • retro maniac
Re: Issue with CHD games and multithreading
« Reply #11 on: February 20, 2016, 12:17:39 pm »
I didn't tested triplebuffer in groovymame for this game but in official mame I can't get 100% with synctorefresh and throttle off combined with triplebuffer. The only way to get 100% is use throttle and triplebuffer. This way no tearing but picture will stutter.

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #12 on: February 21, 2016, 07:22:27 pm »
I get perfect everything but the games unplayable! (As far as I can tell)

Sent from my Nexus 6P using Tapatalk
« Last Edit: February 22, 2016, 06:08:20 pm by BuZz880 »

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7463
  • Last login:July 01, 2025, 01:29:14 pm
  • Quote me with care
Re: Issue with CHD games and multithreading
« Reply #13 on: February 24, 2016, 07:09:01 am »
So you need triplebuffer & multithreading on, ok. But that makes games start in the background due to resolution switching issue. Take a certain game and see what its main resolution is, the one during gameplay rather than presentation screens. For that resolution in a game's ini. This will force dynamic resolution switching not to happen. Let me know if that fixes the issue.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #14 on: February 25, 2016, 12:02:21 am »
I actually have WG3DH working properly now, all I had to do is create an ini for it and I set multithreading 0 and triplebuffer 0.

So what I don't understand is why when I set these same options in mame.ini with no individual game ini, I had problems but in wg3dh.ini they get the intended result with no 200% speed issue?  I'm still on 169, will go to 171 probably tomorrow so perhaps this issue has been fixed.  Or is it an issue at all?  Maybe this is expected behaviour?  Its a bit confusing but now that I am aware of the issue I can solve these problems as they occur.

Thanks for your help.

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7463
  • Last login:July 01, 2025, 01:29:14 pm
  • Quote me with care
Re: Issue with CHD games and multithreading
« Reply #15 on: February 25, 2016, 11:30:45 am »
So what I don't understand is why when I set these same options in mame.ini with no individual game ini, I had problems but in wg3dh.ini they get the intended result with no 200% speed issue?

Yeah that's because for triplebuffer & syncrefresh, a value of "0" is interpreted as "auto" by GroovyMAME. That's why it's important to learn how to read the logs, it shows all the stuff going on clearly.

When you specify "0" in a specific game ini, it has higher priority than mame.ini and it means "disabled".

Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

BuZz880

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 201
  • Last login:November 16, 2023, 02:16:43 pm
  • I'm a llama!
Re: Issue with CHD games and multithreading
« Reply #16 on: February 25, 2016, 02:22:17 pm »
Cool. Didn't think to check the logs. Figured it was a bug that would go away with a new version. Thanks.

Sent from my Nexus 6P using Tapatalk