Welcome!

Final Burn Neo => FBN Development => Topic started by: Barry Harris on April 27, 2012, 03:12:35 PM

Title: FB Alpha 0.2.97.25 Release
Post by: Barry Harris on April 27, 2012, 03:12:35 PM
http://www.barryharris.me.uk/article_view.php?id=187
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Ashura-X on April 27, 2012, 03:17:47 PM
Very nice news indeed !!!!

Thx for teh release )
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Hyllian on April 27, 2012, 04:42:07 PM
I'm curious about xBR performance.  :biggrin:

I have some optimizations in mind if necessary...
Title: Re: FB Alpha 0.2.97.25 Release
Post by: msbhvn on April 27, 2012, 06:04:19 PM
Thanks for the credit on the xBR addition. All that Ctrl+C and Ctrl+V was really hard work! :wink:

Hyllian, your standalone code works on 24-bit/32-bit PNGs, but there were so many revisions and I don't speak Portuguese, so I couldn't really make out what was needed for xBR to work in 32-bit colour. Having RGB to YUV conversion as a function rather than a look-up table might affect performance, but the look-up table is created every frame in the current code, so it might even out. Hq2/3/4x 16-bit has the YUV look-up table initialised separately, so that would be another optimisation for xBR in 16-bit. Do any FBA emulated games run in 24/32 bit colour?

You might be interested to learn I added the CPU xBR filters to Snes9x as well, and it was just as easy as FBA was! It's not as good for Snes9x because it can already use the shader version via Cg, but I have integrated graphics in my PC and it runs shaders at about 8 fps maximum, so I put the CPU versions in and got 60fps. :biggrin:

I just think it's the nature of these pixel scaling functions being self contained that makes them easy to add to emulators that already have a structure in place for other algorithms. All you have to do is look how the other scalers are accessed and copy it.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Hyllian on April 27, 2012, 06:55:47 PM
Another good optimization I just figured out. Those alpha blend macros, It's possible to put red and blue calc together.

Just define this macro:

Code: [Select]
#define RED_BLUE_MASK565 0xF81F
Create this variable:

Code: [Select]
static const unsigned short int pg_red_blue_mask = RED_BLUE_MASK565;
And redefine these macros:

Code: [Select]
#define ALPHA_BLEND_32_W(dst, src) \
dst = ( \
    (pg_red_blue_mask & ((dst & pg_red_blue_mask) + \
        ((((src & pg_red_blue_mask) - \
        (dst & pg_red_blue_mask))) >>3))) | \
    (pg_green_mask & ((dst & pg_green_mask) + \
        ((((src & pg_green_mask) - \
        (dst & pg_green_mask))) >>3))))



#define ALPHA_BLEND_64_W(dst, src) \
dst = ( \
    (pg_red_blue_mask & ((dst & pg_red_blue_mask) + \
        ((((src & pg_red_blue_mask) - \
        (dst & pg_red_blue_mask))) >>2))) | \
    (pg_green_mask & ((dst & pg_green_mask) + \
        ((((src & pg_green_mask) - \
        (dst & pg_green_mask))) >>2))))

#define ALPHA_BLEND_192_W(dst, src) \
dst = ( \
    (pg_red_blue_mask & ((dst & pg_red_blue_mask) + \
        ((((src & pg_red_blue_mask) - \
        (dst & pg_red_blue_mask)) * 3) >>2))) | \
    (pg_green_mask & ((dst & pg_green_mask) + \
        ((((src & pg_green_mask) - \
        (dst & pg_green_mask)) * 3) >>2))))

#define ALPHA_BLEND_224_W(dst, src) \
dst = ( \
    (pg_red_blue_mask & ((dst & pg_red_blue_mask) + \
        ((((src & pg_red_blue_mask) - \
        (dst & pg_red_blue_mask)) * 7) >>3))) | \
    (pg_green_mask & ((dst & pg_green_mask) + \
        ((((src & pg_green_mask) - \
        (dst & pg_green_mask)) * 7) >>3))))





And one more optimizations would be to move those "if (flavour==x)" out of those main "For" loops.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: kev on April 27, 2012, 06:56:40 PM
Do any FBA emulated games run in 24/32 bit colour?


I'm not sure if any run 24/32 bit colour but I know some of them are 12bit colour (and some possibly other non-PC colour depths) and look "wrong" when using 16bit colour but right on 32bit but it's hard to see unless you have them running side by side, or are mentally ill.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Hyllian on April 27, 2012, 07:37:15 PM
Hyllian, your standalone code works on 24-bit/32-bit PNGs, but there were so many revisions and I don't speak Portuguese, so I couldn't really make out what was needed for xBR to work in 32-bit colour.
I don't think 32-bit version is necessary for these emulators.

Having RGB to YUV conversion as a function rather than a look-up table might affect performance, but the look-up table is created every frame in the current code, so it might even out. Hq2/3/4x 16-bit has the YUV look-up table initialised separately, so that would be another optimisation for xBR in 16-bit. Do any FBA emulated games run in 24/32 bit colour?
It's created just one time. There's a static var called 'initialized' which is set only one time.

Maybe the initialization can be optimized, indeed.

You might be interested to learn I added the CPU xBR filters to Snes9x as well, and it was just as easy as FBA was! It's not as good for Snes9x because it can already use the shader version via Cg, but I have integrated graphics in my PC and it runs shaders at about 8 fps maximum, so I put the CPU versions in and got 60fps. :biggrin:
It's great. Are you planning to add your contribution to the snes9x dev team?
Title: Re: FB Alpha 0.2.97.25 Release
Post by: neocvera on April 27, 2012, 09:52:43 PM
Cool update. The PGM audio has significantly improved. The new filters are pretty neat to see in action. It took me a few tweaks and adjustments here and there but I was finally able to play full-screen and see them in action. For the most part, it seems as colors are more vibrant and overall look is smooth but not blurry. I did find a few anomalies in games where a "mesh" style graphic was going on (Samurai Shodown 2 - Galfordo/Hanzo arms) the way the filter interprets the graphic is a bit strange. Games like that also where there is zooming in and out (small and large sprites) looks a bit strange when it goes small (a lot of detail is lost). Still found myself playing longer instead of simply testing out games. Thank you.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Hyllian on April 27, 2012, 10:35:32 PM
Thanks for the credit on the xBR addition. All that Ctrl+C and Ctrl+V was really hard work! :wink:

Here's a new cpu filter that maybe you wanna try on FBA for the next version:  DDT3x (http://pastebin.com/2mEruYBM)

I've already released it for Kega Fusion. -->  DDT3x plugin for kega (http://cdn.anonfiles.com/1335579831465.zip)

Some screenshots (http://imgur.com/a/tTIwY) running with snes9x-next.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: lantus on April 27, 2012, 10:45:26 PM
Cool update. The PGM audio has significantly improved.

you're welcome =)
Title: Re: FB Alpha 0.2.97.25 Release
Post by: money_114 on April 28, 2012, 12:54:19 AM
new Chinese(Simplified) pack
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Porcelain on April 28, 2012, 01:02:55 AM
Thanks for release.

Here's Japanese.flt of FB Alpha v0.2.97.25:
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Barry Harris on April 28, 2012, 03:13:20 AM
Thanks guys, I added the translations to the site.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: zebrastripes on April 28, 2012, 03:52:29 AM
Thankyou so much for adding the xBR filter. FYI, I'm using it through DirectX9 Alt (DirectX Graphics 9) as Enhanced (Direct3D 7) blitter was very slow.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: msbhvn on April 28, 2012, 07:19:11 AM
Here's a new cpu filter that maybe you wanna try on FBA for the next version:  DDT3x (http://pastebin.com/2mEruYBM)

I've already released it for Kega Fusion. -->  DDT3x plugin for kega (http://cdn.anonfiles.com/1335579831465.zip)

Some screenshots (http://imgur.com/a/tTIwY) running with snes9x-next.

Here you go! And I actually worked out how to use diff properly this time! :biggrin:

I had to rename a couple of variables because they were clashing with 2xPM, but otherwise there were no big problems. DDT3x looks like bicubic, but without the softening effect. It's pretty good, but I prefer xBR.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Hyllian on April 28, 2012, 07:28:49 AM
Here you go! And I actually worked out how to use diff properly this time! :biggrin:

I had to rename a couple of variables because they were clashing with 2xPM, but otherwise there were no big problems. DDT3x looks like bicubic, but without the softening effect. It's pretty good, but I prefer xBR.
Wow, that was fast! Congrats!
Title: Re: FB Alpha 0.2.97.25 Release
Post by: DsNo on April 28, 2012, 09:35:14 PM
Update UI language for 0.2.97.25
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Benjamin Siskoo on May 01, 2012, 04:47:40 AM
Here the french language pack.

Have a nice day and keep up the good work.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Barry Harris on May 02, 2012, 02:54:56 PM
Thanks guys.
Title: Re: FB Alpha 0.2.97.25 Release
Post by: Fred/FRONT on May 09, 2012, 02:58:47 AM
Concerning : Neo Geo development - Neo Geo 3D !

Hello guys !

Can you update  FBA with this new homebrew please ...? : 'Neo-geo 3D,  This Tech. Demo (very Cool) developped  by Arnaud CARRE /Leonard-Oxygene (FRANCE)

http://www.pouet.net/prod.php?which=59253   'Oxygene - NeoGeo 3D !' : ROM + AVI
have FUN !   YM Musics ... Cool  :)

Bye

Fred/FRONT !