top of page
alkorempwibur

Visual Boy Advance Vsync



Im playing Pokemon Black and the fps is just fine, around 80-132. The problem is: I want to play with vsync enabled and frame rate capped at 60 fps (my monitor refresh rate is at 60hz too). I already activated the limit frame rate and vsync options, but when Im running in my bicycle and the screen starts to move, I noticed that always after a 5 seconds interval, the screen will stutter, like skipping 1 frame, no matter what I do it will always happen. Before it hits exactly 5 seconds, the screen just moves as smooth as milk, and then it stutters very quickly, and then it turns smooth again for more 5 seconds. I tried playing it on: Windows 7 64 bits, Windows 7 32 bits and Windows XP 64 bits and on 3 different computers and the same thing always happens:




visual boy advance vsync




you want sync-to-video. this isnt the same as vsync, although some emulators may call it that. theres no reason for it to be a common problem on nds emulators, desmume just doesnt have a sync-to-video option. vsync prevents tearing. sync-to-video prevents tearing and jittering. desmume syncs to the clock.


Thanks for this info, I already had seen this sync-to-video option in some emulators but I always thought that was the same as vsync lol. So lets hope they implement a sync-to-video system on this emulator in the future for a more accurate emulation, then it will be perfect =]


Yeah vsync, or whatever you call it, is totally unrelated accurate emulation, did you ever see a vsync option on the real hardware? Never felt the need for that option in desmume not even in Sonic Rush, in fact never seen it do a difference in any emulator. Maybe it only makes a difference in ass old and/or low end monitors, not sure, but on mine (iiyama prolite b240), it doesn't do jack shit.


cobrasa, real hardware is always vsynced, unless on newer consoles the game programmers decide they don't want it. the nds is certainly vsynced in real hardware. the problem is, when choosing it for emulation, it forces other decisions on you which impair accuracy. it causes discrepancies in the audio timing, not to mention the actual gameplay timing, since your monitor's refresh rate probably doesn't match the console's. whether the jitter is noticeable depends a lot on the game. some games are built to have perfect 1fps scrolling and it is very noticeable if they jitter; other games are more jittery by nature and it isnt so noticeable. finally, some other emulators can solve these tensions in a way that makes gamers happier than the way desmume does it, because of decisions and priorities of desmume developers being more about accuracy and reliability than perfectly smooth gaming.


as far as i know, sync-to-video (Double/triple buffering/fliping) only works in (true) full-screen mode without any speed loss while Vsync consumes a lot of CPU power...so many people prefer double buffering/fliping over vsyncjust try desmume with vsync (on/off), you will see the big difference...i personally prefer double buffering/fliping too, as in some cases (resolution+refresh rate) vsync doesn't work (like your case) as it should...also vsync is useless (specially emulators like desmume) when you are under -60fps, does nothing but further slowdown...


as for True Full-screen & sync-to-video (Double buffering) option, is there any chance any developer will add these features as an advanced options through INI ?it would be great help for those with CRT+ArcadeVGA or cabinet users, as well as 'full speed - 60fps without vsync'Vsync is great but too costy ...also true full-screen could provide a further boost in some cases i believe


I thought that historically most emulators were sacrificing scrolling integrity. We do the same. I dont think Ive ever seen an emulator that scrolls smooth. The idea seems foreign and bizarre to me. Some emulators which offer vsync MIGHT be doing "sync-to-video", but it isnt the norm. Sync-to-video isnt reliable since some video cards cant do it and some monitors dont run at 60hz)


I thought that historically most emulators were sacrificing scrolling integrity. We do the same. I dont think Ive ever seen an emulator that scrolls smooth. The idea seems foreign and bizarre to me. Some emulators which offer vsync MIGHT be doing "sync-to-video", but it isnt the norm. Sync-to-video isnt reliable since some video cards cant do it and some monitors dont run at 60hz)


Virtually every emulator for every major system (and some very obscure systems as well) has a working vsync option and exhibits no tearing or stuttering (assuming a powerful enough CPU is used). Further to that, I have never seen any distinction between vsync and vsync-to-video that you are making. And I have been using emulators since the late 90s with Nesticle.


I am not posting this to start an argument or anything. I'm posting this only because Desmume is by far the best DS emulator (and one of the best emulators out there, period!) - and frankly lack of proper vsync is the only thing holding it back. I cannot help with coding, but I'm more than happy to assist with testing if you decide to implement new vsync code. Heck I'd even donate a bit of cash if that would be helpful to the cause!


If you're using a CRT or an LCD with a slow refresh rate in a cold room, you might not notice normal hiccups in a variety of emulators. Perhaps youve found a game stuttering in desmume for another reason and conflated it with vsync-related scroll stuttering.


It is very easy for programmers to add a scroll-mangling vsync. You have to have a clock-based throttle anyway, so all they do is enable the vsync flag in their 3d API. It is more work to remove the clock-based throttle in the case where vsync is enabled, and then you have to worry about the fact that by locking the sync to video, the audio is now mis-timed and suffers from the audio equivalent of scrolling hiccups. The human ear is extremely tuned to notice that, and it is very difficult to fight. Because of all those reasons, and the fact that some people (possibly most people) would not prefer the sync-to-video set of tradeoffs, sync-to-video is usually optional, if it exists at all.


I no longer have VirtualBoyAdvance or any GBA ROMS so I was going off memory there. What I can directly compare to today is Kega Fusion. By loading Castlevania Bloodlines and moving around the first area, staring very closely, there is no tearing or stuttering whatsoever. This game scrolls quite slowly so I think it's a good test for proper sync - in fact Castlevania games on all systems are a good benchmark.(running Kega Fusion 3.64 fullscreen 1920x1080 with vsync enabled. 44khz superhq sound)


I also tested Silhouette Mirage on pSX 1.13 (the only decent sidescroller on PSX I have at the moment) and it is similarly perfectly free of tearing, stuttering or audio glitches with fullscreen 1080p vsync enabled. I have Castlevania Symphony of the Night somewhere... Would be admittedly a better test case.


PSX uses looped PCM samples for its music usually, which should cause timing problems with this sync method, however it also has its own envelopes, so most instruments can be set-and-forget, and naturally fill in during the audio sync accomodation, much as the genesis FM does. So PSX might be another situation where we get lucky. Finally, PSX timing generally isn't understood well, so there would be less inclination from an emulator programmer to resist changing the system clock speed to match the host vsync rate.


To my memory every single one of the emulators I listed does have correct vsync. I just mentioned those two above because I have those currently installed and tested them today (since as you said memory can be 'faulty'). I'll go back and check some of those emulators once I find the DVDs I have all that stored on, if it's useful.


Another important option is vsync_adjust. Most modern displays work fine at 60hz, but some games run at 60.6 hz (like Donkey Kong for the arcades) which is a "non-standard refresh rate". Therefore, MiSTer has what is called a "framebuffer". The game is still running at 60.6hz but the frames are sent at 60hz. So occasionally there is a little "stutter" on the screen to make up for the frames going too fast and being adjusted. To use a framebuffer adds a minimal amount of lag. Here's a list of the options and what they do.


vsync_adjust=0 This matches the refresh rate of your monitor (e.g. 60hz) and has about 1-2 frames of lag. Video output can be a little jittery as the core is still running at it's native rate, which isn't exactly 60hz. vsync_adjust=1 This makes the video output at exactly the frame rate of the game (e.g. 60.6hz). It has 1 frame of lag, but it is less compatible with modern televisions. Video output is very smooth. vsync_adjust=2 This makes the video output draw to the screen as fast as possible, and can result in sub-frame lag consistently (independent of your controller and display's built-in lag). However this is the least compatible mode and it may result in unplayable behavior on some televisions using certain cores. The video output is the very smooth. Additionally, because of the way this special mode works there is a mismatch in the refresh rate of the scaled output and the core's original video output.


Generally speaking, the rule of thumb is that if you want the smoothest video output and lowest lag then start at vsync_adjust=2 and if a core doesn't work that you want to play on reduce it to 1 or 0 to see if the compatibility is resolved. Your results may vary depending on the display you are connected to and what core you are using. 2ff7e9595c


0 views0 comments

Recent Posts

See All

Comments


bottom of page