This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM8127_IPNC如何从本地YUV文件显示图像

Hi,

目前在用 DM8127_IPNC_RDK3.8。

我看目前的usecase的应用chain都是从camerLink --> ......--> displayLink,其源都是cameraLink,请问源可以不是cameraLink吗,如何从本地一YUV图像文件 (xxx.yuv )显示图像呢?是否有学习的usecase?

  • 你好;

           源数据可以不是cameralink,可以通过A8端传过来的yuv数据,可以通过ipcframe 通道传入;

           可以参考ipnc_rdk/ipnc_mcfw/mcfw/src_linux/mcfw_api/usecases/multich_encode_decode.c;

           看一下 FRAME IN(VPSSM3) ---> swms ----> display 部分处理的程序。

  • A8与M3-VPSS之间的ipcframe应该是怎样的呢?我找到在multich_capturedisplay.c这个例子中,打开宏YUV_FRAMES_TO_A8,在ti_mcfw_ipcframes.c有App_ipcFramesSendRecvFxn,

    是否就是通过VIDEO_FRAMEBUF_LIST_S这个结构体,Vdis_putFullVideoFrames到ipcFramesInVpss(M3VPSS)这个link?我要做的是否就是把文件xxx.yuv(仅含一帧)填充到VIDEO_FRAMEBUF_LIST_S这个结构体呢?不知道我的理解与思路是否正确?

  • Harry 说:
    是否就是通过VIDEO_FRAMEBUF_LIST_S这个结构体,Vdis_putFullVideoFrames到ipcFramesInVpss(M3VPSS)这个link?我要做的是否就是把文件xxx.yuv(仅含一帧)填充到VIDEO_FRAMEBUF_LIST_S这个结构体呢?不知道我的理解与思路是否正确?

    是的,在A8端的ipcframe 数据接口 就是在这个位置处理的

  • ternence hsu,

        你好!

        非常感谢你的帮助与解答!印象中有好几次都是你给我解决的,再次表示感谢!

    VIDEO_FRAMEBUF_LIST_S结构体定义如下:

    typedef struct {

        UInt32 numFrames;
        /**< Number of valid frame's in frames[]. MUST be <= VIDEO_FRAMEBUF_MAX */

        VIDEO_FRAMEBUF_S frames[VIDEO_FRAMEBUF_MAX];
        /**< Video frame information list */

    } VIDEO_FRAMEBUF_LIST_S;

    其中VIDEO_FRAMEBUF_S定义又如下:

    typedef struct {

       Ptr addr[VIDEO_MAX_FIELDS][VIDEO_MAX_PLANES];
       /**< virtual address of vid frame buffer pointers */

        Ptr phyAddr[VIDEO_MAX_FIELDS][VIDEO_MAX_PLANES];
        /**< virtual address of vid frame buffer pointers */

       VCAP_CHN channelNum;
       /**< Coding type */

       UInt32 timeStamp;
       /**< Capture or Display time stamp */

       UInt32 fid;
        /**< Field indentifier (TOP/BOTTOM/FRAME) */

       UInt32 frameWidth;
       /**< Width of the frame */

       UInt32 frameHeight;
       /**< Height of the frame */

       UInt32 framePitch[VIDEO_MAX_PLANES];
        /**< Pitch of the frame */

       Ptr linkPrivate;
       /**< Link private info. Application should preserve this value and not overwrite it */

    } VIDEO_FRAMEBUF_S;

    请问,如果我有一个xxx.yuv文件,可以通过fread读取文件内容,那接下来该怎么去填充这个结构体的各个变量呢?物理地址、虚拟地址之间是不是要什么转换的(又改具体怎么转换呢?)

    大神,还望明示,谢谢了!