Advertising (This ad goes away for registered users. You can Login or Register)

TN-V7 FF9 LAGS

Total_Noob's PSP Emulator Custom Firmware for the Vita. CEF can be downloaded here.
sountouchable
Posts: 6
Joined: Fri Nov 08, 2013 6:45 pm

TN-V7 FF9 LAGS

Post by sountouchable »

As title sias ff9 lags everytime i am in a battle i put disc load speed normal and it still lags you think its because of the patch i put on my game (FF9 UNLEASHED/Balance mod) or is there another solution to reduce lag
Advertising
Coldbird
Guru
Posts: 472
Joined: Sun Nov 14, 2010 12:33 am

Re: TN-V7 FF9 LAGS

Post by Coldbird »

Probably a audio wait loop issue.

POPS is originally a multithreaded emulator, with a separate thread for audio processing on the media engine, which emulates the PSX SPU (sound processing unit).

As we don't have access to the Media Engine secondary CPU on Vita it was necessary to remove the audio emulation thread from the emulator, rendering the PSX SPU dead.

Some games have code to wait until audio playback has been completed, in such games you will now (on Vita) suffer from lag as it will be waiting on something that is no longer there (SPU), essentially slowing the game down to the point where a timeout occurs and the game continues to run again, waiting for the next SPU event, and again timing out, rinse & repeat from here on out.

The PSX SPU also served a secondary purpose, namely multithreaded buffer copying.
Games that rely on this functionality are at this moment unsupported on Vita + CEF, as without the SPU emulator, there is no way to trigger SPU multithreaded memcpy's anymore.

Long story short, no its not your fault, its a Vita thing, learn to live with it or code a SPU emulator for POPS that doesn't rely on the Media Engine to do its hard lifting.

I tried porting the PEOPS sound plugin to Vita some time ago but was forced to postpone that work in progress in favor of reallife things (my job mostly).

When I get to resume it, it will probably get shipped as a plugin for TN-V7.

http://www.youtube.com/watch?v=sIgkU7hKU8c
Advertising
Last edited by Coldbird on Mon Feb 03, 2014 1:26 pm, edited 1 time in total.
Image
PSP N-1000 ✔ / 6.20 PRO NIGHTLY ✔ / PRO ONLINE ✔
abdou005
Posts: 431
Joined: Mon May 21, 2012 12:39 pm

Re: TN-V7 FF9 LAGS

Post by abdou005 »

Niceee :D. Thank's for sharing the video Coldbird :D ! it looks better than "no sound" even it glitch :D. Nicee Work :D !
IMPORTANT! English Speakers follow Koala "ps vita hacker progress" here --> https://www.facebook.com/koalavita
Koala PS Vita 3,01 HAck Video --> http://www.youtube.com/watch?v=z_Ahks9N6lg
Ps Vita 1,81 --> Urbanix EU Exploit TN-V8
reprep
Posts: 1074
Joined: Tue Dec 17, 2013 4:38 pm

Re: TN-V7 FF9 LAGS

Post by reprep »

Coldbird wrote:Probably a audio wait loop issue.

POPS is originally a multithreaded emulator, with a separate thread for audio processing on the media engine, which emulates the PSX SPU (sound processing unit).

As we don't have access to the Media Engine secondary CPU on Vita it was necessary to remove the audio emulation thread from the emulator, rendering the PSX SPU dead.

Some games have code to wait until audio playback has been completed, in such games you will now (on Vita) suffer from lag as it will be waiting on something that is no longer there (SPU), essentially slowing the game down to the point where a timeout occurs and the game continues to run again, waiting for the next SPU event, and again timing out, rinse & repeat from here on out.

The PSX SPU also served a secondary purpose, namely multithreaded buffer copying.
Games that rely on this functionality are at this moment unsupported on Vita + CEF, as without the SPU emulator, there is no way to trigger SPU multithreaded memcpy's anymore.

Long story short, no its not your fault, its a Vita thing, learn to live with it or code a SPU emulator for POPS that doesn't rely on the Media Engine to do its hard lifting.

I tried porting the PEOPS sound plugin to Vita some time ago but was forced to postpone that work in progress in favor of reallife things (my job mostly).

When I get to resume it, it will probably get shipped as a plugin for TN-V7.

http://www.youtube.com/watch?v=sIgkU7hKU8c
that is great to hear. hope Pete's sound plugin works well with Vita. it was functioning well in epsxe.

Just wondering, was there any official use of media engine for psp games? or is there any psp retail game which doesn't work perfect on vita because of vita's lack of media engine?

afaik it was used for psx emulation, umd, video decoding. was there any other official use of it?
tinostar91
Posts: 270
Joined: Fri Nov 30, 2012 6:42 pm
Location: Slovakia

Re: TN-V7 FF9 LAGS

Post by tinostar91 »

reprep wrote:hope Pete's sound plugin works well with Vita. it was functioning well in epsxe.
No, it doesn't and it never will. That plugin needs much more processing power and RAM to work with than ePSP has, it lacks proper optimalization and if you'd try to run it in ePSP you will fail just because it won't be even recognized as plugin, just as random file.
reprep
Posts: 1074
Joined: Tue Dec 17, 2013 4:38 pm

Re: TN-V7 FF9 LAGS

Post by reprep »

tinostar91 wrote:
reprep wrote:hope Pete's sound plugin works well with Vita. it was functioning well in epsxe.
No, it doesn't and it never will. That plugin needs much more processing power and RAM to work with than ePSP has, it lacks proper optimalization and if you'd try to run it in ePSP you will fail just because it won't be even recognized as plugin, just as random file.
i didn't mean just a copy paste. of course i know a epsxe plugin and a tn-v plugin is different.

it was in ColdBird's post "PEOPS sound plugin". that plugin is Pete's sound plugin. http://www.pbernert.com/html/spu.htm

just look at the youtube video Coldbird posted to see it works or not.
dboyz
Posts: 676
Joined: Sat Jun 09, 2012 6:33 am
Location: Russia, volgograd

Re: TN-V7 FF9 LAGS

Post by dboyz »

IMO, coldbird was trying to port Pete's sound plugin for eCFW
we forgive but we never forget
tinostar91
Posts: 270
Joined: Fri Nov 30, 2012 6:42 pm
Location: Slovakia

Re: TN-V7 FF9 LAGS

Post by tinostar91 »

reprep wrote:
tinostar91 wrote:
reprep wrote:hope Pete's sound plugin works well with Vita. it was functioning well in epsxe.
No, it doesn't and it never will. That plugin needs much more processing power and RAM to work with than ePSP has, it lacks proper optimalization and if you'd try to run it in ePSP you will fail just because it won't be even recognized as plugin, just as random file.
i didn't mean just a copy paste. of course i know a epsxe plugin and a tn-v plugin is different.
it was in ColdBird's post "PEOPS sound plugin". that plugin is Pete's sound plugin. http://www.pbernert.com/html/spu.htm
just look at the youtube video Coldbird posted to see it works or not.
Sorry, got kinda confused when you mixed ePSXe into this
sountouchable
Posts: 6
Joined: Fri Nov 08, 2013 6:45 pm

Re: TN-V7 FF9 LAGS

Post by sountouchable »

first off thanks for the reply coldbird good to know i wasnt the problem it was the vita second thing is if you ever finish/release that sound plugin would it fix the lag problem atleast hypothetically
Coldbird
Guru
Posts: 472
Joined: Sun Nov 14, 2010 12:33 am

Re: TN-V7 FF9 LAGS

Post by Coldbird »

Haha, of course you can't load the original PEOPS plugin into Vita or PSP, it doesn't work that way.

How I did it was by reverse engineering parts of POPS and figuring out how it handles SPU calls, figuring out how the SPU emulator thread on the Media Engine worked, and where it gets started, etc.

After that all I had to do was program some hooks into the right spots, reverse engineer 2 functions (SPU hw register read & write) and then use those hooks + hw register r/w functions to hook the POPS virtual SPU to the PEOPS plugin.

On the PEOPS plugin side all I needed to do was exchange the audio sample playback backend function calls to use those of the PSP... oh and I had to add the PSP game audio module to the POPS runlevel.

That is about it.

As for processing power and RAM use... we got plenty of that on Vita thanks to TNs horrific work in unlocking that 18MB extra RAM range.

Due to this we can easily fit PEOPS in there (it has a memory footprint of about 3MB), and the CPU use of PEOPS is beyond minimal... it hardly has any influence on the actual PSX gameplay at all, thats how low the CPU footprint is.

This is one of the reasons why I picked PEOPS as porting target in the first place.

Also, the reason why sound is missing in that video isn't because its bugged or something (it is bugged at this time, but thats not the problem here), it simply is because at that point in time I didn't add a CDDA sector injector for PEOPS yet, so all games are missing CDDA audio at this point.
Image
PSP N-1000 ✔ / 6.20 PRO NIGHTLY ✔ / PRO ONLINE ✔
Locked

Return to “TN CEF”