Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.

MPEG-4 decoder - very very imortant

ahmadkq
Beginner
393 Views

Sir,

I am using the MPEG-4 decoder in a Directshow filter. Some times, the incoming buffer doesnt have enough data to decode a frame or it may have many frames. So I have to do a loop to deliver all the frames that available in the sample. How can I know if the data is enough to be decoded? Suppose that I have a buffer that contains 2 frames and half, I will decode the first one, then the second, and then when I trying to decode the 3'rd, I failed (It may be from

mp4_DecodeVideoObjectPlanefunction or mp4_Parsefunction), in this case I have to wait for next buffer to append the data, so I can decode the 3'rd frame and so on and so forth. I handle this by keeping the state of the mp4_Info structure before trying todecode any frame, when there is anerror, Icopy the old mp4_Info status to my mp4_Info member variable to use it in the next time (for the 3'rd frame). The problem is that some result frames are corrupted. Do you have any idea to help me.

Thanks,

0 Kudos
2 Replies
r3d
Beginner
393 Views
Hi f_c:
Sorry for asking this but.. How do you get the starting codes you are talking about?. Is there any UMC method?
Thanks!
0 Kudos
ahmadkq
Beginner
393 Views

Hi f_c,

What if i have one frame data, in this case i will not find the next frame markers so i will wait to receive another data. Is this the only way?

0 Kudos
Reply