04 September 2021, 16:42 | #1 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
> 50 FPS in WinUAE, making all games play too fast
I've tried to pinpoint the error, but it even happens with Quickstart > Set Configuration > Start: see screenshot.
The only thing I do that is special is that my monitor runs at 100 Hz. Monitor drivers are set to default (VSync on) for WinUAE64.exe. When it boots, it goes too high FPS. After the screenshot, with nothing moving on the screen I guess, it settles down to 50 FPS. Same during loading of a game. But when the game starts and things move, up it goes again with an uneven and too high framerate. I'm using the default Windowed.uae as Host config. Win7x64, Intel Core i7, RTX 3070 OC. |
04 September 2021, 17:15 | #2 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,515
|
If only possible choice is 100Hz and you have VSync: you get 100Hz, you wanted VSync, you got it
Any high frequency monitor should also support 50Hz. Make sure it is available and selected in WinUAE display panel. If your monitor is gsync/freesync capable, you shouldn't select VSync in WinUAE. |
04 September 2021, 18:26 | #3 | |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
Quote:
I got the bug in 4.4.0, deleted all configs and all Host configs except Windowed, and it seemed to work for a while, creating my own config from Quickstart+changes. Then again today I get this behavior back, also for Quickstart (no config). In Fullscreen mode 100Hz and Display > Refresh set to PAL as always, framerate is solid 50 FPS both when things are moving and not. Since 99% of users have 60Hz or higher in desktop, and VSync is default on in GPU drivers, they should all get too high FPS. The above setting has always limited framerate before, or all emulated games would be too fast. I'm sure it's something else. Could you have a look? I noticed installing newer versions of WinUAE did not replace the Windowed.uae host config. Can I reset it fully somehow? I've attached the fullscreen config and will try to convert it into a Windowed config, but I also noticed it seems Host configs are not loaded automatically when loading a Configuration. Are we supposed to load the Configuration first, and then load a Host config manually for it as well every time we start WinUAE, or is a Host Config saved in a Configuration as "belonging" to it? Last edited by Photon; 04 September 2021 at 19:01. |
|
04 September 2021, 18:36 | #4 |
Registered User
Join Date: Aug 2001
Location: Connecticut USA
Posts: 617
|
Basically, when you select standard VSYNC you are telling UAE to base its emulation timing on the monitor's refresh / sync rate.
Outright disabling VSYNC should (IIRC) cause UAE to sync instead on audio / Paula timing (so things run at the correct speed), and send out screen updates at the completion of an emulated screen refresh. There are also "lagless Vsync" modes for if you have a really fast system, where it races the beam, and this is supposed to improves latency a bit, but I wasn't able to use it without side effect on my emulation system (I3-10100 + GTX1050Ti + Gsync monitor), and the "Vsync Off" (shows as "-") provided what seems to be the optimal settings, providing smooth tear free scrolling with no audio popping or stuttering, and undetectable (to me) latency on audio and video (using minimal audio buffer size). If you're using an nvidia card, make sure you go to Nvidia Control Panel -> Display -> Set up G-SYNC (you won't see this if you don't have a variable refresh rate monitor IIRC) -> Apply the following changes, and tick off "Enable G-SYNC, G-SYNC Compatible" and apply the chnages. |
04 September 2021, 18:55 | #5 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
@Toni, strange, when I load the fullscreen Configuration it says under Host that I'm using Windowed.uae host config! All I had to was change to Display > Fullscreen to Windowed and save the Configuration, and now it runs fine in windowed mode with solid 50 FPS. The scaling is too big of course, but I've attached the "fixed" Configuration and screenshot. Maybe you can compare it to the first windowed config I posted. I also attached new ini and bootlog.
@Shadowfire, thx but read my account above This is not a monitor Hz issue. A massive amount of users are running WinUAE windowed at 60Hz and above on a laptop, with no need for an extra expensive gaming monitor (like mine) to avoid too high FPS. It has always worked fine and run at 50 FPS. Edit after some testing: It's very strange, because it seems like this: If I load a Configuration that doesn't give the too high FPS bug, it keeps working as it should, even if I quit completely out of WinUAE in between tests. Even the same test as in OP with Quickstart > Set > Start ! Outside WinUAE, the only thing I've done is open and close Chrome. All other apps that were open (Sublime text editor, Thunderbird email client etc, no games or anything relying on DirectX) stayed open during tests. Toni: I've attached another bootlog & ini from second and successful try with Quickstart only, if you can find a difference from the one in OP. It *seems* I can sort it on my own with some manual work for now, so have a great weekend, this can wait a few days. Last edited by Photon; 04 September 2021 at 20:05. |
04 September 2021, 20:05 | #6 |
Registered User
Join Date: Aug 2001
Location: Connecticut USA
Posts: 617
|
This is a brief rundown of the various configurations you can have and what seems to be the drawbacks:
Config: 60hz only display (like we have in the states especially hooked up to a TV) Cons: 99% of the games you want to run are PAL. You can either run with Vsync off and get screen tearing / perfect audio, or run Vsync On and games run too fast, no screen tearing, and audio has intermittent pops. Config: 50hz display (no Gsync/freesync) Cons: Vsync off = screen tearing / perfect audio. Vsync on = Games run correctly, no tearing, audio has intermittent pops. Config: Any G-sync or Freesync compatible monitor/video card combo. Cons: Vsync off = No cons whatsoever, game runs at correct speed, no screen tearing, perfect audio. Vsync on = game runs at the monitors max refresh rate, making them unplayable if it has a refresh rate >60hz. (Likely also has audio pops as well, but I didn't bother to check as the game was running at 240fps or almost 5x speed) To reiterate: Running with Vsync on forces WinUAE to time the emulation according to your display's refresh rate; audio buffers are misaligned when they update and you will get occasional pops and stutters. Running with Vsync off allows WinUAE to time the emulation according to the chipset audio emulation; audio buffers are aligned correctly, but screen updates are pushed out when the emulation says its ready and are not synchronized with your display, which (without freesync/gsync) causes tearing. Edit: Yes, I see. You were originally set to Vsync on, with a full-screen 100hz refresh rate. What was happening is if the internal frame emulation took less than 1/100th of a second, you were running at 100hz. If something happened (emulation took more than 1/100th of a second, due to additional emulation complexity of the new frame, or even if something in the background stole your processor core to do something) it would skip frames and run at 50hz. Last edited by Shadowfire; 04 September 2021 at 20:16. |
04 September 2021, 20:06 | #7 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
@Shadowfire, it's an intermittent bug. We are talking FPS only, not syncing at all. Everyone runs PAL games just fine in 50 FPS and no higher on their mom's laptop with 60Hz screen. So please let us stay on topic
|
04 September 2021, 21:40 | #8 |
Registered User
Join Date: Jul 2019
Location: Poland
Posts: 308
|
Photon do you have VRR screen? With Freesync I sometimes get these problems too. Perhaps it's related to how DWM handles windows on VRR screens?
You might like to see if switching Variable Refresh Rate option in Windows' Graphics settings changes anything... Also see if WinUAE has any profiles in nVidia settings - I had some funky stuff going on when I had some sync-related settings set in WinUAE Radeon profile. |
05 September 2021, 03:07 | #9 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
As mentioned, I seem to have solved it (but I did before, and it came back...)
Toni: Forget about Windowed.uae comparison, Quickstart uses Host Default Configuration which doesn't seem to be a file. Ideally, if Vsync is on (whether windowed or fullscreen), and Vsync is honored, then emulation should output as many frames as the platform is emulating, and a higher Hz means it doubles some frames. Otherwise, emulation of platforms that do not match exactly the Hz on random laptop, will emulate incorrectly. Last edited by Photon; 05 September 2021 at 21:15. |
05 September 2021, 10:29 | #10 |
Bug hunter
Join Date: Jul 2006
Location: Italy
Age: 48
Posts: 2,161
|
If you got g/free-sync: http://eab.abime.net/showpost.php?p=...8&postcount=78
|
05 September 2021, 16:16 | #11 |
Registered User
Join Date: Feb 2008
Location: Italy
Posts: 98
|
How use?
|
05 September 2021, 18:34 | #12 |
Bug hunter
Join Date: Jul 2006
Location: Italy
Age: 48
Posts: 2,161
|
|
05 September 2021, 20:04 | #13 |
Registered User
Join Date: Aug 2001
Location: Connecticut USA
Posts: 617
|
Yeah, but these people are not turning on Vsync. (And no, windowed modes usually aren't even aware of Vsync. They let Windows Display Compositor decide when to update the screen.)
|
05 September 2021, 21:33 | #14 | |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
Quote:
GPU drivers settings are not heeded in Win7x64, and as I understand it, not in later Windows versions either: Vsync is forced on for the active window, regardless of GPU driver profiles for the application. This should make the later versions of Windows undesirable for emulation of all European (50 FPS) platforms. This doesn't matter for my support question. It seems there's an intermittent bug, or perhaps Quickstart's Default configuration doesn't apply the setting that ends up in a saved configuration. For now, I fixed the issue by repeatedly creating new configs until the bug didn't happen, and then used that config to create the other Amiga machines (including Fullscreen). So I'll only respond to this thread if Toni wants more files or tests from me to investigate the mysterious case of a default configuration's FPS going up and down in FPS depending on if something is moving on the screen or not. |
|
05 September 2021, 23:42 | #15 | |
Missile Command Champion
Join Date: Aug 2005
Location: Germany
Age: 52
Posts: 12,444
|
Default graphics driver Vsync is a mess. Nobody should use it. It should be set to "Always off, unless the application specifies". And then use Vsync in WinUAE directly, if you must. Really, G-sync/Freesync hardware is the way to go these days.
edit: Ah, ok. You insist of using Window, not full screen. Ok, different problem. Quote:
Last edited by Retro-Nerd; 05 September 2021 at 23:59. |
|
06 September 2021, 17:11 | #16 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,515
|
It works as designed. Sort of. In my experience windowed mode vsync can work too strangely (depending on windows versions, drivers etc) and afaik asking D3D present to wait 2 frames won't work in windowed mode.
VRR monitor is much simpler solution if you want smooth scrolling, even latency is at least slightly better in VRR mode than in traditional vsync. Note (if there is some misunderstanding) that WinUAE "VSync" means Amiga frame rate is synchronized to host display frame rate (including sound and everything. From running Amiga software point of view everything still runs normally.). It is basically same feature as Display panel FPS.Adj with different sync source. It does not only mean usual basic meaning of vsync == prevent tearing by making sure display buffers are swapped during host displays vsync period. |
06 September 2021, 18:26 | #17 |
Ex nihilo nihil
Join Date: Oct 2017
Location: CH
Posts: 4,884
|
For the uninitiated reading this thread (in summary - my knowledge on the subject is not that precise, feel free to complete if needed):
- VSync : Vsync attempts to reduce/eliminate tearing (image "cut") by forcing the graphics hardware to "match" with the refresh rate of the display. - FreeSync : FreeSync attempts to dynamically adjust the display's refresh rate to match the rate at which the graphics hardware is outputting frames. It requires an AMD GPU. The protocol used is royalty-free (VESA's DisplayPort Adaptive-Sync) and works over HDMI. - G-Sync : G-Sync works like FreeSync but requires an NVidia GPU. The protocol used is royalty-pay NVidia protocol. |
06 September 2021, 19:43 | #18 | |||
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
Quote:
Quote:
Quote:
Anyway, I fixed it on the second evening in a straight 1 hour session of only WinUAE and creating configs. Suddenly, after creating a fullscreen config and converting it to a windowed config I think, the windowed config worked. Now Quickstart host default config works too. |
|||
07 September 2021, 23:15 | #19 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
|
Found it! Quickstart > Host Default config selects WASAPI: Default Audio Device as the default option.
I got it again when creating a stock A1200 config from Quickstart for testing for a friend. Changing to DSOUND or OpenAL fixes it. WASAPI has an exclusive mode which may or may not play nice with modern gaming headsets. (The FPS is fine if I restart WinUAE after switching to another modern external USB card and still use WASAPI. Both devices work perfectly in all games and applications in Windows.) When this happens and the FPS careens, you also get no sound except random clicks. Guess: Could it be you get many error messages that make the code skip to the wrong place and therefore skip the emulation of "Amiga-frames per second"? Last edited by Photon; 07 September 2021 at 23:30. |
08 September 2021, 17:07 | #20 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,515
|
Sorry but I don't think I still understand what are you trying to do and whats the exact problem. First it was about vsync and now it isn't anymore?
Sound working in games is totally different and irrelevant. Playing back pre-recorded samples is simple, impossible to have glitches (unless some effect generation/mixing has issues). Low latency on the fly sample generation is totally different. Traditional vsync and WASAPI isn't fully stable, it is already known because there are two sync sources (emulator needs to follow both display refresh and sound). There is some possible solution(s) but last year or so has been mainly chipset rewrite, no time for other things... And VRR solves it automatically anyway. Do you mean you have to use 100Hz because your monitor requires it for BFI? (If yes, please explain it in first post, this is very important detail! and quite rare) -- And finally the usual: does it happen if you use extremely large sound buffer? Without vsync. Without anything. It is always good idea to start from very basics because sometimes real cause is something totally different. |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
FPS Locking Games That Run to Fast | CryptidWorks | support.Games | 4 | 17 January 2021 23:13 |
Shadow Warrior - MS-DOS FPS making its way on to the Amiga | Neil79 | News | 23 | 17 September 2016 15:00 |
Making AmigaOS as fast as possible for 060 Amigas | 8bitbubsy | support.Hardware | 8 | 04 December 2010 01:11 |
How to play games with others online via WinUAE? | Drake008@ | support.WinUAE | 11 | 10 January 2010 03:46 |
|
|