PMP(PSP Media Player)

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

some modifications here:

bin:
http://jonny.leffe.dnsalias.com/pmp_mod/rar/pmp_mod.rar

src:
http://jonny.leffe.dnsalias.com/pmp_mod ... cecode.rar

base src (from jockyw2001):
http://rapidshare.de/files/5913386/pmp- ... e.tgz.html


changes:

the color space conversion (PIX_FMT_YUV420P -> PIX_FMT_RGBA32) is now done in asm + me
(note: no check for PIX_FMT_YUV420P, some codecs could be broken with this)

some numbers (talking about **csc only** with 480x272 res - @333mhz):
ffmpeg original: ~52 fps
my c version: ~64 fps
my asm version: ~70 fps (lol it's my first mips code, maybe someone could enter here and at least get a better instructions reordering)
asm + me: ~135 fps :O

this traduces in + 4-5 fps for 480x272 mpeg4sp @900 kbps
(low bitrates/resolutions have more speedup - due to a less idct bottleneck)

(curious to see if a vfpu version can do better, is someone already working on this?)


experimenting on the idct now...



EDIT: various me code taken from here: http://forums.ps2dev.org/viewtopic.php?t=2652
Last edited by jonny on Mon Oct 31, 2005 1:19 am, edited 1 time in total.
jockyw2001
Posts: 339
Joined: Thu Sep 29, 2005 4:19 pm

Post by jockyw2001 »

Excellent work jonny! Looking fwd to see your idct code
I'm experimenting with the VFPU to do colorspace conversion and idct. Because of exciting socket stuff developments (thx pspet!) it's a bit delayed tho ...

/JockyW
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

thanks, i hope to get smooth playback soon (the video @480x272 is so nice :-) )
pspvideo9
Posts: 19
Joined: Tue Mar 15, 2005 12:32 pm

Post by pspvideo9 »

Great work jonny. We look forward to seeing your idct optimizations.

On another note, is anyone hearing odd audio distortions when using PMP? We never heard such distortions in the original JiniCho version, but in jockyw2001 and now jonny's version we're hearing some odd audio distortions when playing back video (with mp3 audio in the avi container).
AnonymousTipster
Posts: 197
Joined: Fri Jul 01, 2005 2:50 am

Post by AnonymousTipster »

Yes, I got that. I tried playing a DivX file of a TV show, and the first 10ish seconds of it, the sound was pitched incorrectly and quite bitty. After that, the sound went back to normal.
Also, what codecs does this support with .WMV?
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

i'm totally ignoring audio atm :)
(i like to do things in little steps ... )
AnonymousTipster
Posts: 197
Joined: Fri Jul 01, 2005 2:50 am

Post by AnonymousTipster »

But it wasn't like that in previous versions. If you know that you've changed something that may affect audio, then fine, but if not, something's changed for the worse.

I've found a couple of WMV codecs that sort of work. One works fine except has fuzzing at the top (like a VHS tape) another loads the first frame and first half second of sound, then bsods. And another (a low quality one) that is mostly gray squares, and the audio is scratchy (plus the usual squelchy sound you get from low kbs). This is merely for information, I don't expect anyone to rush off and make .WMV perfect, i'm sure everyone would prefer to see full quality DivX work first. It was just a bit of info for anyone interested.

Great work so far!
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

At the best of my knowledge, nothing had changed from the original version that could affect audio playback.
Maybe we are using different versions of the sdk that have this side effect.

About wmv... maybe i'm wrong but i don't think someone will go to make it run perfectly.
I think ffmpeg itself doesn't have full support for the latest wmv versions.
dnnsmanace
Posts: 15
Joined: Mon Oct 31, 2005 8:46 am

Post by dnnsmanace »

Xvid looks amazing at 480x272 and 600 avg bitrate. Now the audio messing up is another story. Great progress though!
cooleyandy
Posts: 41
Joined: Sat Jul 02, 2005 10:12 am

Post by cooleyandy »

The new version of PMP works wonders. Most of my mpeg music videos play without any skipping frames. I was skimming through the original code and saw that any audio that is below 44khz is resampled to 44khz. What about 48khz audio streams?
Something odd happens sometimes when I load an Xvid avi. I hear the audio and don't see the video. I'm sure libavcodec supports it because I tried out the SDL version and it works on that particular video, but not on this version.

Anyway, great job on the new version :-)
Shapyi
Posts: 95
Joined: Mon Apr 25, 2005 9:31 am

Post by Shapyi »

jonny, thanks for the nice work! Great performance.

My only question is why doesn't the initial Korean release have audio problems like yours and the one jockyw2001 released?
S34N
Posts: 5
Joined: Thu Oct 27, 2005 5:42 pm

Post by S34N »

How do you convert a dixv or xvid movies resolution .... we need a guide because I tried in vdub and I get an error: no statsfile or something like that
dnnsmanace
Posts: 15
Joined: Mon Oct 31, 2005 8:46 am

Post by dnnsmanace »

Use any guide just use the xvid as source. in evs: avisource("blah.avi") bicubicresize(480,272)

or change height to keep ratio.
Then just do two passes on the avi at 600 bitrate.
dnnsmanace
Posts: 15
Joined: Mon Oct 31, 2005 8:46 am

Post by dnnsmanace »

cooleyandy wrote: Something odd happens sometimes when I load an Xvid avi. I hear the audio and don't see the video. I'm sure libavcodec supports it because I tried out the SDL version and it works on that particular video, but not on this version.

Anyway, great job on the new version :-)
I think resolutoin needs to be 480x272 or less...
Ranwanui
Posts: 7
Joined: Sat Oct 15, 2005 10:33 pm

Post by Ranwanui »

I can not download the PMPMod Src,
Somebody can give me a avaliable download Addr??

Thank you!!!
moonlight
Posts: 567
Joined: Wed Oct 26, 2005 7:46 pm

Post by moonlight »

The video plays great, but the audio has glitches (at lest the 700 kbps 480*272 file that i've tried).

Could the media engine be used to handle the audio while the video is handled by the main processor?
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

strange my initial link work, anyway ...
http://rapidshare.de/files/6994743/pmp_ ... e.rar.html
JiniCho
Posts: 18
Joined: Wed Sep 14, 2005 11:03 am

try this

Post by JiniCho »

If you having trouble with sound glitches, try to change the priority of video_thread as 0x15 like below.

in my case it fixed the sound problem.

is->video_tid = sceKernelCreateThread("Video thread", video_thread, 0x15, 0x10000, THREAD_ATTR_USER, 0);

also this

static int av_sync_type = AV_SYNC_VIDEO_MASTER;

to

static int av_sync_type = AV_SYNC_AUDIO_MASTER;
someone
Idiot
Posts: 71
Joined: Tue Sep 13, 2005 9:03 pm

Re: try this

Post by someone »

JiniCho wrote:If you having trouble with sound glitches, try to change the priority of video_thread as 0x15 like below.

in my case it fixed the sound problem.

is->video_tid = sceKernelCreateThread("Video thread", video_thread, 0x15, 0x10000, THREAD_ATTR_USER, 0);

also this

static int av_sync_type = AV_SYNC_VIDEO_MASTER;

to

static int av_sync_type = AV_SYNC_AUDIO_MASTER;
Could you please post/upload a binary compiled with your changes? I'm not able to do it myself, but I would like to see if this solves my audio glitches!
Thanks in advance.
jonny
Posts: 351
Joined: Thu Sep 22, 2005 5:46 pm
Contact:

Post by jonny »

digihoe
Posts: 108
Joined: Sat May 14, 2005 7:40 pm

Post by digihoe »

I have tried some diffrent codec media MPEG1 1700kbps, MPEG2 2000kbps, MPEG4 XviD single pass profile Simple @ L1 600kbps, MPEG4 XviD single pass profile Simple @ L2 900kbps, MPEG4 XviD single pass profile AS @ L2 600kbps and MPEG4 XviD single pass profile AS @ L2 600kbps...

The video that I get best flow is with MPEG1 1700kbps that one is fluent and A/V sync is OK. Mod1 tested this was...

One more thing if the hight pixel is higher then 272 then the upper part of the video will get alot of pixel artifacts, and bluescreen crash the PSP with some error code...

Has anyone found any special codec or setting that is best for 480*272 video with higher bitrate?

Also what is this idct bottleneck?

Can't wait for the streaming version to come out now when DHCP has been figured out, will be sweet!

Nice work everybody, keep it up...

Best regards!
DigitalFoundry
Posts: 47
Joined: Thu Jan 20, 2005 4:35 am

Post by DigitalFoundry »

Digihoe - I just tried both MPEG1 and MPEG2 as per your settings. I re-encoded an episode of Desperate Housewives, using AviSynth to resize the video to 480x272 and Cinemacraft to produce the MPEGs.

Playback still looked very jerky to me - just my visual perception of course, but I'd say that maybe 50% of the frames were dropped at 333MHz? I too am experiencing audio distortion. EDIT: but not so much on the new binary!!

However, picture quality at 480x272 is phenomenal and native resolution playback is tantalising for the future. Kind of makes you wonder what could have been had Sony gone for a true multimedia player and not crippled the inbuilt MPEG4 playback.

Best of luck with the project guys -this is the homebrew tool that I'm following with the most interest :)
Ranwanui
Posts: 7
Joined: Sat Oct 15, 2005 10:33 pm

Post by Ranwanui »

jonny wrote:strange my initial link work, anyway ...
http://rapidshare.de/files/6994743/pmp_ ... e.rar.html
Thank you
pvaiyapu
Posts: 1
Joined: Wed Nov 02, 2005 2:38 am

WMV format supported

Post by pvaiyapu »

Is there anyone who could find out how to play WMV files in PSP?

this will definitely be a breakthrough in this technology

is this is possible somehow pls reply
AnonymousTipster
Posts: 197
Joined: Fri Jul 01, 2005 2:50 am

Post by AnonymousTipster »

.WMV playing is possible but doesn't work that well. I've tried using various codecs, and I think that Windows Media Video 8 High Quality for Broadband worked, but I'm not sure. It was a little jerky and had scratchy marks at the top, but actually played, which is better than most codecs I tried.
Durante
Posts: 65
Joined: Sun Oct 02, 2005 6:07 am
Location: Austria

Post by Durante »

Sorry for the flamebait-ish reply, but why would anyone actually want to use wmv? Especially now that h.264 is available?

Anyway, great work everyone involved, I'm looking forward to playing full screen h.264 vids at 24 fps ;)
AnonymousTipster
Posts: 197
Joined: Fri Jul 01, 2005 2:50 am

Post by AnonymousTipster »

Durante wrote:but why would anyone actually want to use wmv?
If it gets fast enough (i'm talking 100+), then I may have a special use for it in a project.
I'm particularly looking forward to full, fast DivX support, that will the the best.
DigitalFoundry
Posts: 47
Joined: Thu Jan 20, 2005 4:35 am

Post by DigitalFoundry »

Durante wrote:Sorry for the flamebait-ish reply, but why would anyone actually want to use wmv? Especially now that h.264 is available?

Anyway, great work everyone involved, I'm looking forward to playing full screen h.264 vids at 24 fps ;)
The PMP player looks to be running video decoding in software and there is no access to the chip that handles the MPEG4/AVC decoding in the PSP thus far. I'd say that to handle AVC decoding, PMP would need to have access to this hardware. Software AVC decoding is most likely somewhat beyond a 333MHz CPU.
Durante
Posts: 65
Joined: Sun Oct 02, 2005 6:07 am
Location: Austria

Post by Durante »

DigitalFoundry wrote:The PMP player looks to be running video decoding in software and there is no access to the chip that handles the MPEG4/AVC decoding in the PSP thus far. I'd say that to handle AVC decoding, PMP would need to have access to this hardware. Software AVC decoding is most likely somewhat beyond a 333MHz CPU.
Hmm, I don't agree. Remeber, we're talking about 480*272 here, not some HD (or even NTSC!) resolution. Also, the PSP is not just the main cpu, there is also the ME (already used by jonny's colour space conversion code) and the VFPU which could provide great IPC, though it would require some non-trivial coding to be sure.

Anyway, I'm not saying that it will happen, or that it will be soon, I just want to contest the statement that it's impossible for homebrew to decode full-screen AVC at 24fps, using all the computational resources currently documented.
Ranwanui
Posts: 7
Joined: Sat Oct 15, 2005 10:33 pm

Post by Ranwanui »

When I played a Dvix movie(4:3--it's height is 272),
only audio can be output, but video cannot show,
it is a bug???
Post Reply