video analysis2.0拆分,ffmpeg封装go接口库
zhangmeng
2019-10-09 de6e563245cdfabc5bd3890d05b7e54bdbf16eb4
csrc/wrapper.cpp
@@ -435,15 +435,11 @@
    }Conv;
    
    void *CreateConvertor(const int srcW, const int srcH, const int srcFormat,
                          const int dstW, const int dstH, const int flag){
        AVPixelFormat pix_fmt = AV_PIX_FMT_BGR24;
        // just resize
        if (flag == 0){
            pix_fmt = (AVPixelFormat)srcFormat;
        }
                          const int dstW, const int dstH, const int dstFormat, const int flag){
        auto bridge = new cvbridge(
                srcW, srcH, srcFormat,
                dstW, dstH, pix_fmt, flag);
                dstW, dstH, dstFormat, flag);
        if (!bridge) return NULL;
        Conv *c = (Conv*)malloc(sizeof(Conv));