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

MPEG1 Encoder Example

janlund1967
Beginner
302 Views

Hi.

Doessomeone have a MPEG1 encoder example in its simplest form?

(ie. no dectection of anything, hardcoded framesize, hardcoded frame rate etc)

Basically, i want to stuff a series of Ipp8u* 's (coming from a framegrabber) into a MPEG-1 file.

Something like this (pseudo C - i am a Delphi programmer :o) :

MyMP1Encoder->Init("C:Test.mpg");

For (x=0; x

{ MyMP1Encoder->AddFrame(MyNewFrame); }

MyMP1Encoder->DeInit;

Howshould i implement the Init, AddFrame and DeInit methods ?

Thanks

Jan

0 Kudos
2 Replies
Vladimir_Dudnik
Employee
302 Views

Hi, why do you need in MPEG1? Probably you can also use MPEG2? If so, please take a look on IPP media sample, which contains video_ec_con application to demonstrate how to implement MPEG encoders with IPP and UMC

Regards,
Vladimir

0 Kudos
Vladimir_Dudnik
Employee
302 Views

There is also comments from our MPEG expert

First, we dont support mpeg1 encoding, but do mpeg2. There is no significant difference.

To do encoding a simplest way it is needed to create an encoder object MPEG2VideoEncoder, then create VideoEncoderParams, set there width, height, frame and bit rate.

Then call encoder->Init(params).

After that create VideoData for input and MediaData for output. Than in loop read uncompressed YUV video to VideoData, call encoder->GetFrame, and store MediaData.

Deletre created objects. That is all.

umc_video_enc_con can be used as an example and for more information. Documentation to UMC and components is available as well.

Regards,
Vladimir

0 Kudos
Reply