metartc / metaRTC

A cross-platform webRTC SDK
Apache License 2.0
837 stars 214 forks source link

libmetartccore5 开启#define Yang_Rtp_I_Withmeta 1 后编译报错 #34

Closed MisterYan closed 1 year ago

MisterYan commented 1 year ago

问题描述: 在yang_config.h 头文件设置#define Yang_Rtp_I_Withmeta 1 后编译libmetartccore5 库报错如下: metaRTC/libmetartccore5/src/yangrtc/YangPlayTrack.c:166:23: error: ‘YangRtcContext’ {aka ‘struct <anonymous>’} has no member named ‘avcontext’ 166 | if(context->avcontext->avinfo->video.videoDecHwType==Yang_Hw_Soft){

解决办法: 查看 YangRtcContext 结构体确实没有avcontext成员,将 `#if Yang_Rtp_I_Withmeta if(context->avcontext->avinfo->video.videoDecHwType==Yang_Hw_Soft){ videoFrame->frametype =YANG_Frametype_I; goto sendevideo; }

endif`

修改为 `#if Yang_Rtp_I_Withmeta if(context->avinfo->video.videoDecHwType==Yang_Hw_Soft){ videoFrame->frametype =YANG_Frametype_I; goto sendevideo; }

endif`

解决报错问题,顺利编译通过 #

yangrtc commented 1 year ago

新版本已经修正此问题