Intel® Integrated Performance Primitives
Community support and discussions relating to developing high-performance vision, signal, security, and storage applications.
Announcements
The Intel sign-in experience is changing in February to support enhanced security controls. If you sign in, click here for more information.

Extracting snapshot of video render

lholden
Beginner
214 Views
Is there a way to grab a complete frame of data from a UMC video render? I'd like to be able to takea snapshot at any time so that I have a complete raw buffer (in whatever colour space it is recorded in), convert this to a JPEG encoding and save the data to disk. The video render may not always be displayed, however I'll need to be able to extract JPEG images at any time.
I am using IPPsample media 5.0.0.17 and IPP 5.0.023. The application is compiled with Visual C++ .NET.
0 Kudos
4 Replies
Vladimir_Dudnik
Employee
214 Views

Hi, there is recommendation from our expert:

You can use

VideoDecoder::PreviewLastFrame(ColorConversionParams *lpParams);

Regards,
Vladimir

lholden
Beginner
214 Views
The method ReviewLastFrame isn't a method of VideoDecoder (at least not in the UMC version I have). A string search of the entire source tree doesn't find ReviewLastFrame. Can you please name the includefile it is defined in.
The closest I can find is
MPEG2VideoDecoderBase::RetrieveLastFrame( MediaData *data)

This method is protected.I am using a H263VideoDecoder so I wouldn't have any access to this method anyway.
The VideoRender class has a ShowLastFrame, but this doesn't offer any way of extracting data from the from the render.
napoleon9th
Beginner
214 Views
the smilie wasn't meant to be there. It's

VideoDecoder : : PreviewLastFrame ( ColorConversionParams *lpParams );
;)
lholden
Beginner
214 Views

Imust have a bad version of the UMC, there is no PreviewLastFrame in VideoDecoder (or anywhere in the source tree). The public methods listed for VideoDecoder are:

Code:

class VideoDecoder : public BaseCodec
{
    DYNAMIC_CAST_DECL(VideoDecoder, BaseCodec)
public:
    VideoDecoder(void)
    virtual ~VideoDecoder(void){}
    virtual Status Init(BaseCodecParams *init) = 0;
    virtual Status GetFrame(MediaData *in, MediaData *out) = 0;
    virtual Status GetInfo(BaseCodecParams *info);
    virtual Status Close() = 0;
    virtual Status Reset() = 0;
    virtual Status ResetSkipCount() = 0;
    virtual Status  SkipVideoFrame(int) = 0;
    virtual vm_var32 GetSkipedFrame() = 0;
    virtual Status  SetParams(BaseCodecParams* params);
}

And for BaseCodec

Code:

class BaseCodec
{
    DYNAMIC_CAST_DECL_BASE(BaseCodec)
public:
    virtual ~BaseCodec(void){};
    virtual Status Init(BaseCodecParams *init) = 0;
    virtual Status GetFrame(MediaData *in, MediaData *out) = 0;
    virtual Status GetInfo(BaseCodecParams *info) = 0;
    virtual Status Close(void) = 0;
    virtual Status Reset(void) = 0;
    virtual Status SetParams(BaseCodecParams *params)
};



I've re-downloaded the filew_ipp-sample-media_p_5.0.017.zip, extracted it and used a Windows find in file search to look for "PreviewLastFrame". The search was empty. Can I get the name of the file the method is defined in? (or even declared in?)



Reply