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: ArcadeVGA and vertical tearing  (Read 4462 times)

0 Members and 1 Guest are viewing this topic.

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
ArcadeVGA and vertical tearing
« on: November 04, 2007, 01:09:50 am »
I've been having some issues getting games in MAME to run at their proper resolutions using my ArcadeVGA card along with MAME .120u1.

So far, the problem seems to exist mainly within Neo-Geo games.  Using the AVRes program, games such as Metal Slug are set to run at "336x240" resolution.  The game will start up looking great... until the scene begins to scroll.  When the game begins scrolling horizontally, I start getting pretty significant vertical tearing.  I tried experimenting with synconrefresh, vsync, and triplebuffer options with the same results.  If I set the resolution to 640x480, it runs great with no tears (however, it is not the resolution the game should be running at and thus defeats the purpose of having purchased an ArcadeVGA).

Like I said, this is mainly with Neo-Geo games/resolution, other games don't seem to exhibit this problem (though I haven't tested all 6000+ of them).  Does anyone have any solutions/suggestions for eliminating this vertical tearing issue?

My system specs are pretty decent (ArcadeVGA 2, AMD XP 2800+, 1Gb RAM, stripped-down windows, etc) and the games appear to play superb otherwise.

DaveMMR

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3244
  • Last login:April 28, 2025, 11:33:13 am
Re: ArcadeVGA and vertical tearing
« Reply #1 on: November 04, 2007, 10:14:14 am »
I actually was going through this problem yesterday.  There are some good threads and some discussions on the forum about that problem.  Do a search for "screen tearing".

Basically, you have to enable triple buffering (not vsynch or syncrefresh).  If it ends up giving you sound problems though, you can enable it on a game by game basis (your game's specific ".ini" file).

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #2 on: November 04, 2007, 11:37:07 am »
Like I stated in my post, I've messed around with the triplebuffer option (with syncrefresh and vsync off) and had pretty much the same result.  I've searched the forums pretty thoroughly, but the only real solution that people come up with is to turn on triplebuffer, which doesn't eliminate the problem for me.

Additionally, upon closer inspection, running at 640x480 only makes the tears less noticeable, but they still appear to be present.

Are there any ArcadeVGA owners who have encountered this problem (most specifically with Neo-Geo games such as Metal Slug) with a sure fire way to eliminate this issue?

DaveMMR

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3244
  • Last login:April 28, 2025, 11:33:13 am
Re: ArcadeVGA and vertical tearing
« Reply #3 on: November 04, 2007, 01:53:18 pm »
Are there any ArcadeVGA owners who have encountered this problem (most specifically with Neo-Geo games such as Metal Slug) with a sure fire way to eliminate this issue?

There isn't always a "surefire" way to eliminate problems in mame - especially since there are so many different configurations out there.  I wish there were - because the constant struggle is discouraging sometimes.   Sigh...

Anyway, back on topic:  I checked some random Neo-Geo game ini's and it seems to be mostly (all) at 321x240.  That sounds about right since I found this on some NeoGeo FAQ page:

Quote
Video hardware: resolution 320×224, 2 palette banks with 4096 (15-bit) colours each

The AutoRes utility probably picked the closest resolution when it made the ini files since I didn't see 320x224 on the list of available resolutions.

Anyway, try editing the ini for one Neo-Geo game using 321x240, first without triplebuffer, and see how it performs.  They try it with and see what happens.

Good luck.

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #4 on: November 04, 2007, 02:31:34 pm »
I tried messing around with the settings for quite a bit and managed to make some semi-decent progress.

I was poking around and found that under the cfg folder, a file named "mslug.cfg" is generated.  For some reason (even though I have hwstretch disabled in the mame.ini) inside this cfg file I found this string: hstretch="1.054945"

If I change it to hstretch="1.0", then run mame with the metal slug resolution set to 321x240, NO TEARS!  However, if I quit the game and re-open the mslug.cfg file, the hstretch string disappears completely.  Then, if I try running Metal Slug again (using 321x240 like before) the tears start occurring again.  Sure enough, when I quit, the hstretch="1.054945" re-appears.

Another problem is that when I am running the game with the hstretch set to 1.0, I get black bars on either side of the screen that go down about 9/10's to the bottom.  Attached is the screenshot of what it looks like.  When the game is tearing (and the hstretch set to 1.054945), the bars cease to exist.

Is there a way I can prevent MAME from generating the hstretch="1.054945" string and not get those weird black bars?

sega_mad

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 284
  • Last login:July 09, 2015, 04:03:08 am
Re: ArcadeVGA and vertical tearing
« Reply #5 on: November 04, 2007, 03:00:40 pm »
Hi,

I know what you mean. This drove me nuts, but my fix was quite simply turning on triple buffer!!

I'm running a 3.33Ghz, only 0.5 Gig ram & of course AVGA card, with XP Tiny (rev. 2)

I remember when I installed the AVGA card it said to change  these 3 things: HARDWARE STRETCH MUST BE OFF
YOU MUST USE DIRECT-DRAW NOT DIRECT3D
SWITCH RESOLUTIONS MUST BE ENABLED

Well I did that and the picture was terrible I changed them back to the way they were and it was 'mint'.

So basically, I'm running stock standard settings, with Triple Buffer on, and I have no sound stutter or tearing. I was concerned about games like Wonder Boy, and Rally X, and had never played Metal Slug, so just went & had a game, and it was all good with those too!

My F.E is Mala, and I set that to run all games at 640*480......seems to work for me!!

Sorry I can't be of more help, but these are the settings that worked for me.

Forgot to mention...I'm running MAME 1.14

Good luck
« Last Edit: November 04, 2007, 03:13:25 pm by sega_mad »

DaveMMR

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3244
  • Last login:April 28, 2025, 11:33:13 am
Re: ArcadeVGA and vertical tearing
« Reply #6 on: November 04, 2007, 04:41:32 pm »
This might sound silly but do you have hwstretch enabled by accident in the game specific .ini?  It should be set to "0" for 321x240 resolutions.

Here's my mslug.ini file settings:
Code: [Select]
## mslug ##

screen0 \\.\DISPLAY1
switchres 1
hwstretch 0
bezel 0
backdrop 0
resolution 321x240
resolution0 321x240

AFAIK, the .cfg files are generated automatically based on your settings (the .ini files).  Don't edit the .cfg - edit the .ini only.  If you're still having problems, try deleting and regenerating the file

Quote
My F.E is Mala, and I set that to run all games at 640*480......seems to work for me!!

If it works and you're happy with it then there's nothing wrong with using it.  But you are, technically, defeating the purpose of using an arcade monitor.  But it's all good.

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #7 on: November 04, 2007, 05:10:07 pm »
Thanks for the help, it seems that MAME stretching the Neo-Geo games was causing the issue.  I'm just going to set the hstretch to 1.0 and set the file to read-only for the time being.

So, the vertical line tears have been fixed.

I'm still having issues with horizontal tearing, however.  I get occasional horizontal line tears with just about all of my games.  I've tried the standard triplebuffering solution, but then the audio studders.  I've searched quite a bit on the forums and this issue seems to be the same for just about everyone.  So, I guess this brings up the question:

Is there ANY way I can eliminate the horizontal screen tearing without suffering from audio studdering created by using triplebuffering/vsync in ddraw?

I've already tried lowering the audio sample rate to 22050, using the lowest/closest resolution possible, etc.  There has to be a way to run games with no tearing, non-studdering audio, and ddraw mode.

DaveMMR

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3244
  • Last login:April 28, 2025, 11:33:13 am
Re: ArcadeVGA and vertical tearing
« Reply #8 on: November 04, 2007, 05:46:16 pm »
First off, you may want to move to an official build of mame (not any with "u" in it).  It's easier to pinpoint problems without worrying about the bugs that may have crept in in between official releases.

Personally, I keep Mame .116 as my main emulator but then I also have FastMame .098b and regular Mame .99.   I'll throw the rom to an earlier version and test to see if it runs faster and better. 

Unfortunately, there is no easy answer, as I said previously. You have to play around with the settings (including lowering sound quality - which you already did, disable processor hogs, etc.) to squash the sound problems and still have triplebuffer do its thing.

(OFF-TOPIC EDIT: Did I say "FastMame .098b"?  Disregard that.  It has this naggy little habit of completely ignoring the cfg files and thus, my custom settings.  So I'm trying out FastMame084)
« Last Edit: November 05, 2007, 08:13:32 pm by DaveMMR »

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #9 on: November 04, 2007, 06:08:52 pm »
I'll try an earlier version of MAME to see if that helps, but I honestly don't think speed is an issue here.  The copy of Windows I'm running is a fresh install with next to all of the services turned off and ZERO programs running in the background.  Last time I counted, it had < 15 processes running.  On top of that, the stuttering even occurs in relatively older games (I've been using Sunset Riders to test the stuttering/tearing).

Through searching, I've found some people claim the issue is related to the display frequency of the individual games not matching up with my monitor frequency.  This doesn't seem to make much sense to me, because MAME shows Sunset Riders has a 60hz display (which is what Windows is running at).  Have you heard of anything similar to this?

ahofle

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4544
  • Last login:August 30, 2023, 05:10:22 pm
    • Arcade Ambience Project
Re: ArcadeVGA and vertical tearing
« Reply #10 on: November 05, 2007, 12:06:10 am »
I remember when I installed the AVGA card it said to change  these 3 things: HARDWARE STRETCH MUST BE OFF
YOU MUST USE DIRECT-DRAW NOT DIRECT3D
SWITCH RESOLUTIONS MUST BE ENABLED

[...]

My F.E is Mala, and I set that to run all games at 640*480......seems to work for me!!


You bought an ArcadeVGA card to run all your games at 640x480?

To the original poster, I have the same issues with my arcade monitor even when the game's refresh rate matches my monitor's rate exactly in some cases.  I'm not sure what the problem is, but I'm guessing it's a MAME issue.  I have just learned to live with the tearing.
« Last Edit: November 05, 2007, 12:07:52 am by ahofle »

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #11 on: November 05, 2007, 08:44:46 am »
@ahofle:

Do you get the tearing problem with ALL games?  If so, how often?  For me, some games such as Metal Slug exhibit it all the time while others like Street Fighter II it is significantly less noticeable.

I guess I'm just slightly peeved I threw out $90 for a special video card that is supposed to help bring the "proper" arcade experience, but instead I have a bunch of ugly tears running through 99% of my games.  Sure, there is triplebuffering, but then the sound is awful.  Had I known a problem like this was unavoidable, I would've just run D3D through a card I have laying around.

ahofle

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4544
  • Last login:August 30, 2023, 05:10:22 pm
    • Arcade Ambience Project
Re: ArcadeVGA and vertical tearing
« Reply #12 on: November 05, 2007, 10:42:59 am »
No it's not all games (which is why I think it's a MAME issue), and most games that don't have scrolling you can't even tell if it's tearing anyway.  I still think it's 500 times better than D3D and scaling though -- I would never even consider going back to that.

katzinator

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 14
  • Last login:August 17, 2020, 09:27:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #13 on: November 05, 2007, 11:24:27 pm »
OK, well I tried using some older versions of MAME and found out that versions up to .112 are able to have triplebuffer enabled with no sound studdering.  I'm not sure what core changes were made, but versions .113 and above sound like crap with triplebuffer enabled.  Now I can play tear-free and enjoy decent sound!

I really hope this helps anyone else who has been pulling their hair out over this issue.

MAME TIME

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 175
  • Last login:March 23, 2019, 10:23:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #14 on: November 06, 2007, 12:54:52 pm »
When i get home i'll post my specs i had this problem awhile back but nobody was able to answer my question, figured it out after hours of configing and testing, i run mame106 with atomic fe, and play both ver and hor games on my wg k7000
Too Much Game, check out my ish!!!

Geometry Arcade



Neo Geo 360


MK2 standup



SF2 champ edition X2


MAME TIME

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 175
  • Last login:March 23, 2019, 10:23:19 pm
Re: ArcadeVGA and vertical tearing
« Reply #15 on: November 07, 2007, 11:16:46 pm »
Ok after hours of testing and multiple threads, Here are the options im using on my machine, i must warn you this might not solve your problem but it might give you better insight on using the ini files and which options to use with mame

Windows xp sp2
P4 3.2ghz
80gb sata
arcadevga v2
mame 106, using ddr3 and triple buff, switch res
mk2 cab with wg k7000

Using the quick res utility i set the desktop to 352x256 and set your front end to the same as well, it will save you the flicker from exiting the game back to the frontend

Using avres program you can generate the ini's for each game or create your own

Most vertical games and older games like the 640x480 with HWstrech on, you'll get the side boarders but what the hell its better then nothing
most capcom games like to use the 368x240 res option
You might want to try the 321x240 for geo games like Davemmr suggested

If you get the tear at the top (left and right) its likely that your using the wrong res and no matter how much you mess with the hor knob it wont get rid of it,
I've tried these options with mame 117 and 120 and most games run slow
« Last Edit: November 07, 2007, 11:18:33 pm by MAME TIME »
Too Much Game, check out my ish!!!

Geometry Arcade



Neo Geo 360


MK2 standup



SF2 champ edition X2