Welcome!

Final Burn Neo => FBN Development => Topic started by: CaptainCPS on February 02, 2010, 11:20:52 PM

Title: FBA DirectX WIP
Post by: CaptainCPS on February 02, 2010, 11:20:52 PM
Posting to let you know that I been doing research on DirectX again and I was finally able to fix the Vsync + Triple Buffer support on Windowed mode, this is for both: Direct3D7 Enhanced and Direct3D9 Experimental

Now Im gonna try to make Vsync work for the other 2 blitters ^^, if everything goes fine this should be in the next FBA release.

I have to say that the video looks a lot smoother using Vsync + Triple Buffer on windowed mode now  :smilie:.

SeeYaa!
 :biggrin:
Title: Re: FBA DirectX WIP
Post by: Huggybaby on February 02, 2010, 11:54:41 PM
Beautiful, these are the things I love to hear. Thanks for sticking with it CaptainCPS-X.
Title: Re: FBA DirectX WIP
Post by: CaptainCPS on February 03, 2010, 02:01:00 AM
At least for now the only thing I could do for both DirectDraw 7 blitters was to add Vsync support, but Triple Buffer was originally implemented for Fullscreen mode, and since the code structure is different from the D3D7 and D3D9 blitters I cant add Triple Buffer, at least with what I know now.

In the future if I get better understanding of how Triple Buffering works I will try to add support for those 2 old blitters (I don't think anyone uses them anyway LOL). So far I know that Triple Buffering has something to do with flipping of primary buffer and a back buffer but I still need to know more about it  :p.

I have been thinking that DX10 support in FBA would be great someday but so far I still don't know very much of DirectX so Im just dreaming LOL xD

SeeYaa!
 :biggrin:
Title: Woot! Full VSync support!
Post by: CaptainCPS on February 03, 2010, 07:42:33 PM
Full Support for VSync in FB Alpha!

Yeah!! After doing lot of research and testing different hard-coded modules to make DX Blitters wait for VSync I found out the proper way to make FBA wait for Vsync without compromising its trademark speed :D

Triple Buffering / Page Flipping doesn't even need to be turned on in windowed mode, the video is displayed 100% smooth (unless of course your video card can't handle Vsync  :p)

Oh, and ALL blitters now can use Vsync  :wink:

I will submit the updates as soon as possible to Barry so they can be added for the next FB Alpha release ^^

FB Alpha Rules! xD

EDIT: In current FBA version when you select Vsync or Triple buffer from the menu it doesn't apply the changes until the video is restarted, now in my updated code when you select the options in the menu the video is automatically restarted with the new options  :smilie:.

SeeYaa!
 :biggrin:

Title: Re: FBA DirectX WIP
Post by: Huggybaby on February 03, 2010, 08:33:49 PM
OMG, that is BAD ASS! Please release a new version ASAP! Thanks Captain!
This will make FBA one of the few apps that can actually do DirectX Triple Buffering natively, something which already exists for OpenGL apps.

And someone please fix the audio problems in The Simpsons. :)
Title: Re: FBA DirectX WIP
Post by: iq_132 on February 04, 2010, 12:55:38 AM
@Cap - Nice work buddy!!

And someone please fix the audio problems in The Simpsons. :)

What's wrong with The Simpsons?
Title: Re: FBA DirectX WIP
Post by: Huggybaby on February 04, 2010, 01:00:11 AM
The sound is clipped/distorted, and left and right are reversed. Works fine in mame.

To check left/right, start a game and when the rabbit skates across the TV screen you can tell.
Title: Re: FBA DirectX WIP
Post by: CaptainCPS on February 04, 2010, 03:06:16 PM
@Cap - Nice work buddy!!

ThanX man! ^^

SeeYaa!
 :biggrin:
Title: Re: FBA DirectX WIP
Post by: isamu on February 04, 2010, 08:23:05 PM
awesome awesome awesome Captain! That is very good news! Can't wait to try it out! I'm assuming the benefit of having v-sync enabled is to make the games look like they're running at a smooth, rock solid 60fps?
Title: Re: FBA DirectX WIP
Post by: CaptainCPS on February 05, 2010, 12:05:31 AM
awesome awesome awesome Captain! That is very good news! Can't wait to try it out! I'm assuming the benefit of having v-sync enabled is to make the games look like they're running at a smooth, rock solid 60fps?

To be specific, VSync wait for all the vertical scanlines to finish the 'painting' from the last page buffer and then continue with the next page buffer and so on. Without VSync the pages are painted on screen but they don't wait for the last vertical scanline to finish, so this results in what is better known as 'Flickering'. Even when we are running at full 60fps and not doing Vsync quality will not be the same, but with Vsync 60fps are really 60 complete vertically synchronized frames per second.

SeeYaa!
 :biggrin:
Title: Re: FBA DirectX WIP
Post by: isamu on February 05, 2010, 02:02:15 AM
To be specific, VSync wait for all the vertical scanlines to finish the 'painting' from the last page buffer and then continue with the next page buffer and so on. Without VSync the pages are painted on screen but they don't wait for the last vertical scanline to finish, so this results in what is better known as 'Flickering'. Even when we are running at full 60fps and not doing Vsync quality will not be the same, but with Vsync 60fps are really 60 complete vertically synchronized frames per second.

SeeYaa!
 :biggrin:

Ahh I see, cool :)