Page 1 of 1
Using the IPU...
Posted: Wed Sep 15, 2004 11:10 pm
by Shazz
Just a question, is there somebody here who has tried to use the IPU (Image Processing Unit) to replay a Mpeg2 movie ????
Should we use the IOP to access the IPU ? I really have a lack of knowledge concerning this IPU... If someone can fill (a little) the gap...
Thx
Posted: Thu Sep 16, 2004 4:26 am
by Guest
Well, the IPU is probably one of the rarest things for someone to touch.
The thing is, the IPU does not magically play back movies. To playback
a normal DVD type movie, requires several streams in and out of the IPU.
The sequence is something like this*
1. Stream in data via IOP to EE memory buffer
2. Stream out from EE memory buffer to IPU for IDCT
3. Stream output from IPU back to a second memory buffer
4. Use EE CORE MMI instructions to perform Motion Compensation
(this part of mpeg decoding is NOT done in hardware on the IPU)
5. Stream results of motion compensation back to IPU for Color Space Conversion
6. Stream CSC output from IPU back to memory, this is the final RGB image
7. Feed to the GS via GIF
There are variations on this. It might be possible to do SOME conversations via the MDEC on the IOP when reading from media, though the iop is resource limited. I don:t know if there is any use to using some of the preprocessing capabilities of VIF1 enroute to PATH2, and certainly if one wants to do anything extra they could send it into VU1 for additional post-processing then being kicked to the GIF.
But has anyone done this, homebrew ? I don:t think so...
Gorim
Posted: Fri Sep 17, 2004 8:51 pm
by Shazz
Thanks Gorim !
Yep I really thought it was more 'magic' than that ! Maybe porting a simple MpegI decoder could be easier for the moment... and just to have a kind of "splash" movie screen :D..
But thanks again, that's very interesting and for sure a day a way to look at...
Posted: Mon Sep 20, 2004 12:26 am
by Guest
FYI, I should cite that my flow summary comes from one of many such flow diagrams for the IPU, shown on the final page of the EE User's Manual. However, this manual can only be obtained from the Linux kit or from official PS2 developer kits, so if you have neither you are SOL with respective to seeing these.
The IPU isn't just used for MPEG2 video playback. (Can the IPU do audio also anyone ?). Another common use is simply decompressing jpegs of textures that often can even get further decompression post-processing at VIF1 enroute path2 to the GIF/GS for texture uploads. The idea is naturally to save memory space by decompressing textures before giving them to the GS.
Gorim
Posted: Mon Sep 20, 2004 12:30 am
by pixel
gorim wrote:Can the IPU do audio also anyone ?
AFAIK, no.
Posted: Mon Sep 20, 2004 2:35 am
by Shazz
Thanks for the information Gorim... good to know !
I'm sure there is plenty of applications for the IPU :D
And obviously decompressing jpeg on the fly can be great... I wonder if libjpg uses it of is just a conversion of the JPG lib for the EE....
Have to look....
Pixel, is the IPU does not provide audio capaibilities, how the IPU decoder and the SPU are synchronized for video replay ? by hand ?
just curious....
Posted: Sun Oct 03, 2004 7:00 pm
by zerocom
The IPU can do the following things:
- IDCT (for MPEG1/2 or JPEG)
- VLC decode
- FLC decode
- color conversion (YUV->RGB, RGB32->INDEX8)
The IPU can also do MPEG I-Frame decoding and converting to RGB in one step (for texture decompression)
To decode a full MPEG2 movie many things have to be done besides using the IPU, like parsing and motion compensation.
I made a mpeg1/2 decoding lib which fully uses the ipu some time ago....
Bye...
Posted: Tue Oct 05, 2004 1:55 am
by mrbrown
Erm, the IPU's IDCT doesn't support JPEG decompression.
Posted: Tue Oct 05, 2004 3:35 am
by zerocom
... you may right, but the idct itself should be the same as mpeg1/2, but you cannot use it as stand-alone. The IPU does always VLC-decode->IQ->IDCT....
Posted: Tue Oct 05, 2004 5:14 am
by mrbrown
I'm just trying to make it clear that there is no hardware JPEG decompression in the PS2, that's all.