Log in

View Full Version : x264 and Sony PSP?


Pages : 1 2 3 4 5 [6] 7 8 9 10 11 12

Hyper Shinchan
4th July 2006, 10:02
What do you mean with "http streaming"? I'm not an expert, but I think that you mean progressive download... as long as I know it's not possible to stream over http, you have to use rtsp or something else.
Anyway it's an interesting software, but I canot use it unfortunaltely... you have to use 1.50 firmware, right? and I don't have a wi-fi connection with my PC....

JOCKYW
4th July 2006, 10:03
What do you mean with "http streaming"? I'm not an expert, but I think that you mean progressive download...
not progressive download, http streaming protocol

Sudds
8th July 2006, 16:33
Just would to say :thanks: to jonny and co for PMPMOD AVC.
Recently just downgraded my PSP, and its the best app going.
One question though, would it be possible to implement the PMP container into MeGUI?

rootkit
9th July 2006, 14:50
What differs from:

mencoder -ovc x264

and:

mencoder -ovc lavc -lavcopts vcodec=h264

?

yawoo
27th July 2006, 11:04
I have tried to use mencoder to encode to PSP/AVC format. The patched MP4 by atomchanger (psp video version) can be played by PSP (firmware 2.6) successfully. But when I seek after 90 seconds of the movie, or fast forward beynond 90 seconds. The playing video cannot be stopped, or cannot play properly.

I have tried additional encoding parameters, such as
bframes=1:frameref=1
bframes=0:frameref=2

The seeking problem is still existing.

mencoder.exe -dvd-device "e:" dvd://2 -chapter 1-22 -sid 2 -aid 128 -af volnorm -srate 48000 -vf-add scale=368:208,harddup -ofps 30000/1001 -oac faac -faacopts br=96:mpeg=4:object=1 -ovc x264 -ffourcc H264 -x264encopts bitrate=400:level_idc=13:bframes=0 -spuaa 18 -spualign 2 -o "c:\\DVD.2.1-22.x264.avi" 2> 2.txt

Ghim
27th July 2006, 20:18
I have updated my PSP firmware to 2.80 today (I know, I probably shouldn't have ;-)).
I have tested the video support with the updated version and I found the following:

- Videos can now be placed directly under the "VIDEO" directory of the Memory stick root. (I know, this is part of the official changelog but it's still worth mentioning).

- Videos in the "VIDEO" directory can have any naming you want !!! (no more MAQ*.mp4 naming required !!). However, the title of the video that appears on the PSP is now based on the file name and not on the information inside the file anymore and the thumbnail (.thm file) didn't work anymore in the "VIDEO" directory.

- Atomchanger is not required anymore !! I've been able to create valid files using only megui and avisynth. I've tested with 2 videos (25fps 320x240 with 48kHz sound and 25fps 368x208 with 44kHz sound) and they both worked fine.

- The PSP seems to do a check on the reported Profile/Level. I've found that "Main Profile - Level 2.1" and "Baseline Profile - Level 1.3" worked but I haven't had any success with anything else. By example, "Main Profile - Level 1.3", "Baseline Profile - Level 2.1" or "Main Profile - Unrestricted Level" didn't work.
EDIT: I've done some further testing and it seems some cases that didn't work were because of a problem in my x264 settings at the time of the test. Actually, for the Main Profile, any level set <= 2.1 seems to work. I've tried exactly the same settings (PD-PSP profile from megui) with level set a 1.3, 2, 2.1, 2.2 and Unrestricted. Files with level set at 1.3, 2 and 2.1 worked.

WARNING: These are only my personal findings and if someone could confirm them, it would be good. Since I haven't spent too much time testing, I may have missed some new things and the removed limits may not work in 100% case.

NOTE: I've only tested with files placed in the "VIDEO" directory. I don't know what happens with files in the old directories.

bond
27th July 2006, 20:27
would be a revolution if sony doesnt require hacking the mp4 files anymore :D

deets
27th July 2006, 21:08
no way!! this is fantastic news :D ill get testing :)

edit: oh the irony, im in the US now and dont have any 25fps stuff to test!

CruNcher
28th July 2006, 17:08
but still im sure they don't allow full UMD resolution ? or is it possible now ?, could you please check Ghim thx

Varium
28th July 2006, 18:28
I tried it but unfortunately it still doesnt work, you're pretty much stuck with the resolutions you use now.

Ghim
28th July 2006, 18:54
I've tried as well and, as Varium said it, we are still limited to the same resolutions as before.

Ghim
28th July 2006, 20:56
I've done some more testing and I've found another small "hidden" feature:

- Files with .m4v extension works. It seems that files can use either .mp4 or m4v extension.

This may not look very interesting, but the way I found it is much more interesting:

- I've downloaded a few Movie Trailers encoded for the iPod from QuickTime website. I've renamed them .mp4 and simply copied the files on my PSP and they played fine (correct audio/video synchronisation, correct aspect ratio, ...) !!! I then simply tried to keep the original .m4v extension and they worked as well.

Here are some examples I've tried to play on my PSP:
- "Ratatouille" Teaser, 320x132 AVC @ 23.976fps Video, 44100kHz AAC Audio
- "A Scanner Darkly" Trailer, 320x172 AVC @ 24.000fps Video, 44100kHz AAC Audio
You can get both trailers directly from QuickTime website.

It wouldn't surprise me if the compatibility with videos encoded for the iPod was the main reason Sony implemented these new features...
EDIT: Just a note explaining why Sony may have implemented these features: by supporting videos encoded for iPod (as well as removing the file name limits and adding video file saving from RSS... ) this allows the PSP to use most of the already existing video podcasts.

deets
28th July 2006, 22:17
interesting stuff ghim, im gonna keep messing about with stuff and update my site!

can any psp owners with a dual core cpu get files to play when they select more than one thread? i originally thought it might be my old cpu, p4 3.2HT that was the problem. Sadly, i get the same problem on my dual core centrino, which is a shame as i get much faster speeds with 2 threads.

if anyone could test their dual core setup with their psp, that would be great :)

adrianmak
29th July 2006, 02:00
How about PMP-AVC ?
There is a guy, developed a PMP (portable media player) for psp which can play .pmp video. The advatanges of PMP is the video can use full psp resolution 480x272

how to I create such .pmp files ?

CruNcher
29th July 2006, 03:22
480x272 is not full PSP resolution Display Yes but not full content resolution Studio UMD's are encoded @ DVD Resolution with 1500 kbps, the guy who develops PMP is long time Doom9 Member Jonny hmm you could use XviD4PSP or Mediacoder for easy encoding :)

Ghim
29th July 2006, 09:34
interesting stuff ghim, im gonna keep messing about with stuff and update my site!

can any psp owners with a dual core cpu get files to play when they select more than one thread? i originally thought it might be my old cpu, p4 3.2HT that was the problem. Sadly, i get the same problem on my dual core centrino, which is a shame as i get much faster speeds with 2 threads.

if anyone could test their dual core setup with their psp, that would be great :)

You don't need a dual core CPU to try the multithread encoding. I've encoded a few files using 2 threads (on my single core CPU) and the PSP can't decode those files.

Files encoded with multiple thread are quite different from files encoded using a single thread (multiple slices per frame if I'm not mistaken).
I know quite a few cases where such files are not supported so it does surprise me that the PSP decoder doesn't support them either.

Ghim
29th July 2006, 11:23
As I mentioned in a previous post, the new 2.80 firmware performs a check on the H.264 Level reported in the H.264 bitstream. For Main Profile, all levels > 2.1 are rejected.

This new limitation is not a problem for reading newly encoded videos or videos that were aready using a correct level.

However, I've just found out that the PSP videos that can be downloaded from "Google Video" website reports a level of 5.1 and are rejected by the PSP.

NOTE: I've only tried with videos in the "VIDEO" directory of the root. I haven't used the old file naming (old directories and file naming) since I've updated to 2.80 so I don't know if videos using the old naming are affected by these changes.

qyqgpower
30th July 2006, 03:36
old directories work as same as previous version, so no strict level limitation there

AnimeTheme
2nd August 2006, 19:27
I have some AVC files encoded by myself which work under the MP_ROOT folder. I have installed 2.80, and now when I put them under the "VIDEO" folder, they don't play anymore. I guess the H.264 level reported by my AVC files is unsupported by PSP under the "VIDEO" folder... as mentioned by Ghim.

Is there any way to edit the header of an AVC file to change the reported H.264 level....? I want to make my old AVC files work under the "VIDEO" folder, since I want to include them in my RSS Channel... and they have to be in the "VIDEO" folder.

conkeroo
5th August 2006, 10:13
Hello all,
Just wondering if anyone else has the same problem.
Ive updated to v2.80 and have encoded some PAL video (am in Ireland) but although it plays ok, the video is kind of jerky.
Its as if it plays ok for 20 frames of the 25 but the last 5 frames kind of speed up.
Some im thinking, is it the psp hardware actually decodes the video framerate, as in its in built, but the firmware merely tries to correct the hardware on a software level. Anybody have any thoughts??

Ghim
5th August 2006, 15:04
Is there any way to edit the header of an AVC file to change the reported H.264 level....? I want to make my old AVC files work under the "VIDEO" folder, since I want to include them in my RSS Channel... and they have to be in the "VIDEO" folder.

I've read the H.264 standard and it should be possible to do. However, I don't know any tool available at the moment to do it.

Ive updated to v2.80 and have encoded some PAL video (am in Ireland) but although it plays ok, the video is kind of jerky.
Its as if it plays ok for 20 frames of the 25 but the last 5 frames kind of speed up.

Most of the videos I'm encoding are PAL as well but I've never had such a problem. I've encoded quite a few fast and slow motion videos and the videos are all playing smoothly.

What software and settings do you use to create your videos ?

conkeroo
7th August 2006, 11:16
How you doin Ghim.
Im using psp video 9. Ive changed the settings to the correct framerate so it should be ok.
Maybe its just the software because it seems most people dont particularly like it. I just recently got the psp so ive only used this software cos it seems the easiest to use. What software would you recommend?
Cheers.

Sudds
7th August 2006, 11:24
MeGUI and X264, you,ll get brilliant results with it, i used to use PSPvideo9 but once i got MeGUI i never went back.:p

Ghim
7th August 2006, 18:02
I'm the same as Sudds... Once I got MeGUI + x264, I never went back to PSPVideo9...

At first, MeGUI + x264 can look a bit hard to use (compared to PSPVideo9)...
But if you really take some time to understand it and to set it up, you will get great results !

Sudds
7th August 2006, 18:18
I currently now use Xvid4PSP as am encoding PMP,s, but oddly enough MeGUI and X264 encodes look better (not res wise) most if all the ghosting have been cut out as well as the halo you get from red colours.
If only the PMP container was added to MeGUI, along with Jonnys modified version of x264, you would be making truly remarkable encodes.

foxyshadis
7th August 2006, 20:26
I'd like a little more information on this:

1. What is PMP exactly, and how does it compare to MP4? Or is it based on another container?
2. What can you mux from to get PMP? MP4? Raw? With what tools?
3. What modifications were made to x264? MeGUI will never package an x264 that breaks something, but if it's just a PMP output module, you could probably send to sharktooth for inclusion in his builds.

Sudds
7th August 2006, 20:54
Am surprised Foxy your not in the know of this :confused: Jonny of this very site along with others created this app.
PMP format was devloped by Jonny.
The PMPMOD AVC Muxer accepts .AVI .X264 and RAW as inputs, Audio is encoded to MP3 44100HKz.
More info can be found here mate http://jonny.leffe.dnsalias.com/pmp_mod_avc/index.htm

foxyshadis
7th August 2006, 23:25
Well, I have no PSP so I never paid attention, but now that I'm working on MeGUI I am. :p Thanks for the link, that's the kind of thing I had a hard time finding.

Sudds
7th August 2006, 23:31
No problem at all Foxy, if MeGUI ever did include the PMP container...it would just be excellent, i mean the encodes i got before i downgraded my 2.60 to 1.50 where fantastic, but to be able to use MeGUI , X264 and 480x272 RES in a PMP container...i,am drooling at the thought of it!

AnimeTheme
8th August 2006, 14:35
I've read the H.264 standard and it should be possible to do. However, I don't know any tool available at the moment to do it.

I have finally figured out a way to modify the AVC level so that PSP can recognize it under the "VIDEO" folder :D

After some searchings on the Interent, I know that the AVC profile/level information is stored in something called "profile-level-id", a 3-byte header which stores the information in the format of

profile(1 byte):constraint flags(1 byte):level(1 byte)

I don't know much about "constraint flags", but it appears to be usually "00". So for a AVC Main Profile Level 5.1 file (encoded with x264), the "profile-level-id" should be

4D0033

What you need to do is search for this hex value and replace them with

4D0015

which changes the level from 5.1 to 2.1.

I tried this on some of my previously encoded (x264) AVC videos, as well as a few Google AVC vidoes, and after the changes, they all played in "Video" folder on PSP.

Note that this header is either at the beginning or at the end of the AVC file, and it appears TWICE nearby (I change both).

CruNcher
8th August 2006, 15:58
its not hard to integrate into Megui you can do it by yourselves by useing profiles and the custom command in Megui very easy stuff but you have to keep the x264 patched all the time and with the rapid development of x264 the patch becomes fast invalid and needs to be reworked also pengvado doesn't like what it does with the stream he allready said in its current state he wont bring it in the rep.

Ghim
8th August 2006, 17:52
I forgot to mention something:
With 2.80, it is not only possible to put videos in the "VIDEO" folder but also in any sub-folder of "VIDEO" !

AnimeTheme
8th August 2006, 21:28
I forgot to mention something:
With 2.80, it is not only possible to put videos in the "VIDEO" folder but also in any sub-folder of "VIDEO" !

Thats exactly what this folder is for in fact... since all the RSS videos are put inside subfolders :P

conkeroo
9th August 2006, 21:29
Would anyone have an idea the best place to start to try and understand megui and x264.
Ive been researching the last couple of days and still no better off!! :sly:

Sudds
9th August 2006, 21:43
Try this link mate: http://www.bontragerphotography.com/psp/index.php

foxyshadis
10th August 2006, 02:13
http://www.project357.com/MeGUIwiki/index.php?title=Main_Page

conkeroo
10th August 2006, 12:18
Thanks Sudds, foxyshadis. Very helpful. :thanks:

Shadowfax3000
10th August 2006, 21:19
I have read this entire thread, tried numerous settings on my own, and have finally given up hope of doing this without help. Every video I create with x264 that is listed correctly in the PSP displays the message "This video cannot be played." when I try to play it.

1. In firmware 2.80, I make a folder called "VIDEO" in:
a.) the root of the memory stick?
b.) the MP_ROOT directory of the memory stick?
c.) or the PSP directory of the memory stick?

2. A file name like "Invader Zim.mp4" is allowed in that folder, right?

3. What is the maximum total bitrate (video + audio) allowed for an x264 created video on the PSP with firmware 2.80?

*3. Could someone please post their entire PD-PSP profile that has been CONFIRMED to work in firmware 2.80?

Thank you guys sooo much!

*Extremely important, because the latest PD-PSP profile has a few settings set that are confimed not to work on the PSP. God knows what other settings are incorrect.

Varium
10th August 2006, 21:30
I have read this entire thread, tried numerous settings on my own, and have finally given up hope of doing this without help. Every video I create with x264 that is listed correctly in the PSP displays the message "This video cannot be played." when I try to play it.

1. In firmware 2.80, I make a folder called "VIDEO" in:
a.) the root of the memory stick?
b.) the MP_ROOT directory of the memory stick?
c.) or the PSP directory of the memory stick?

2. A file name like "Invader Zim.mp4" is allowed in that folder, right?

3. What is the maximum total bitrate (video + audio) allowed for an x264 created video on the PSP with firmware 2.80?

*3. Could someone please post their entire PD-PSP profile that has been CONFIRMED to work in firmware 2.80?

Thank you guys sooo much!

*Extremely important, because the latest PD-PSP profile has a few settings set that are confimed not to work on the PSP. God knows what other settings are incorrect.

To answer your questions:
1.)
a)Yes, you do create the VIDEO folder in the root of your memory stick

2.) That filename should be allowed, yes.
3.) Videos in the VIDEO folder must be no more than Level 2.1@Main profile or the PSP will not play them. I don't think there is an audio bitrate limitation, however.

Here are the x264 two profiles I use along with two nero aac profiles:
http://rapidshare.de/files/28932286/My_Working_Profiles.zip.html

If this doesn't help i'm sure someone else can help you out.

Ghim
10th August 2006, 22:01
According to Sony's official specifications for the VIDEO folder, the maximum video bitrate is 768kbps and the maximum audio bitrate is 128kbps (I haven't tested however so I don't know if higher bitrates are rejected or not).

If you can read Japanese, here is the link describing the exact features:
http://www.jp.playstation.com/psp/pdf/RSSChannel-J_2.80.pdf (The Appendix is the most interesting part for the supported Video and Audio)

For my x264 profile, I use the PD-PSP with only 3 modifications compared to the default version:
- level set to 2.1 (instead of Unrestricted)
- B-frames set to 1
- Number of Reference Frames set to 1

Varium
10th August 2006, 22:22
I did a quick test now using x264 ABR 768 Kb/s & nero aac at q=1 (~400+ Kb/s), and it played fine on my psp, so i guess there isn't an audio bitrate limitation.

Shadowfax3000
11th August 2006, 00:13
To answer your questions:
Here are the x264 two profiles I use along with two nero aac profiles:
http://rapidshare.de/files/28932286/My_Working_Profiles.zip.html


The zip file seems to be corrupt. The audio profiles extract fine, but the video profiles do not.

For my x264 profile, I use the PD-PSP with only 3 modifications compared to the default version:
- level set to 2.1 (instead of Unrestricted)
- B-frames set to 1
- Number of Reference Frames set to 1


I closed MeGUI completely, downloaded the profiles from http://mirror05.x264.nl/Sharktooth/?dir=./MeGUI/profiles, overwrited the PD-PSP profile to get back to the defaults, changed to level 2.1, B-frames to 1, reference frames to 1, Bitrate to 384, and VBV Maximum Bitrate to 768.

Here is my AVISynth script:

DGDecode_mpeg2source("blah blah blah.d2v",info=3)
ColorMatrix(hints=true)
tfm().tdecimate(mode=1,hybrid=3)
Crop(6,0,-6,0)
Undot()
LanczosResize(320,240)

Here are my Nero Digital AAC settings:
_ Force Decoding via DirectShow
Output Channels: Keep Original Channels
X Increase Volume Automatically
X Improve Accuracy using 32bit & Float computations
_ Delay Correction
X Constant Bitrate @ 128kbit/s
AAC Profile: AAC-LC
_ Create hint track (for streaming server)

I hit AutoEncode, select Average Bitrate to 384 kbit/s, click Queue, then start the queue. The video ends up being 320x240 at 23.98fps with 48000Hz Stereo.

"This video cannot be played."

Varium
11th August 2006, 00:30
..This might be a dumb question, but how many audio channels have you encoded? (ie Stereo, 4 Channel etc..)

Shadowfax3000
11th August 2006, 03:39
..This might be a dumb question, but how many audio channels have you encoded? (ie Stereo, 4 Channel etc..)

The source AC3 is stereo. To make sure, I selected "Downmix multichannel to Stereo." Still the same error message.

Ghim
11th August 2006, 07:11
The source AC3 is stereo. To make sure, I selected "Downmix multichannel to Stereo." Still the same error message.

I don't see a problem with your settings. Can you post a small video (1 or 2 minutes of video) you have encoded so that we can see what is wrong ?

Clown shoes
11th August 2006, 17:38
Umm, just a thought but how many threads is your Megui set to use? If your machine is dual processor/multi core/hyperthreaded the encode will not work. You must set Megui to use only one thread. Good luck mate.

Shadowfax3000
11th August 2006, 22:48
I don't see a problem with your settings. Can you post a small video (1 or 2 minutes of video) you have encoded so that we can see what is wrong ?

This includes my video and audio profiles as well as a sample clip:
http://moose.he.net/~mtlmrch/test.zip


Umm, just a thought but how many threads is your Megui set to use? If your machine is dual processor/multi core/hyperthreaded the encode will not work. You must set Megui to use only one thread. Good luck mate.

I have a hyperthreaded processor (Pentium 4 2.4GHz Northwood) and have only been using 1 thread in my settings.

Golgot13
12th August 2006, 01:22
Hi everybody,

(Clown shoes no news about HD DVD...)
I have a PSP and a LocationFree Box. The last firmware, 2.8, of PSP
can play AVC but with some restrictions.

I test lot of options, there is a big restriction no more than one "Slice".
The resolution is locked at 320x240 :mad:
The bitrate can be ABR, VBR and CBR ( up to 4000Kbps !!! :eek: ).
PSP support all bitrate between 50kbps to 4000kbps

All Google video for PSP are encoded by x264 with VLC program !!!!!
And the manual hex patch (4D0033 replace by 4D0015) work fine on PSP :p


Nobody know how I can read the LocationFree video stream
with other player than Sony software player on PSP or on PC
(LocationFree Box is a realtime hardware video stream
in Xvid, ???, -> I see TV channel from my home DVB receiver on my PSP
in my home or in my work via web connection with Wifi :D ).


Golgot13

deets
12th August 2006, 03:18
This includes my video and audio profiles as well as a sample clip:
http://moose.he.net/~mtlmrch/test.zip




I have a hyperthreaded processor (Pentium 4 2.4GHz Northwood) and have only been using 1 thread in my settings.


does megui have "automatically set number of threads" ticked in settings? if so, it will over ride your selection of 1 thread and will make the video not work.

Shadowfax3000
12th August 2006, 03:36
does megui have "automatically set number of threads" ticked in settings? if so, it will over ride your selection of 1 thread and will make the video not work.

WOW! I suppose someone had to make that mistake some time. Plays fine now. Thanks everyone for their help!