固件类型:官方提供的固件
固件文件名称:AIO-RV1126-JD4-BE-45_Linux_v2.2.5b_220324.img
固件下载地址:百度网盘 请输入提取码
Log日志:log.zip
使用ffrtsp拉流时,发现拉到第5626帧时程序就卡住不走了,没有任何报错。同时也发现推流从一开始就失败了,没有推出。请问是怎么回事?
sdk我使用了.repo/repo/repo sync -c --no-tags 确保是最新的,也切换到了firefly分支。
测试程序是直接编译sdk中的ffrtsp_demo_test.cc,只加了调试打印,其它没有做任何改动了。修改代码如下:
int FFRTSP_Send(u_int8_t *framebuff, unsigned framesize, bool *quit, int cur_chn)
{
static int my_packet_cnt = 0;
my_packet_cnt++;
printf("Got one frame from rtsp [%d]\n", my_packet_cnt);
if (ffrtsp_push[cur_chn].fp == NULL)
return -1;
#ifdef SAVE_FILE
char save_file_path[30] = "test_rtsp_";
char str[10] = {0};
sprintf(str, "%d", cur_chn);
strcat(save_file_path, str);
FILE *fp = fopen(save_file_path, "a+b");
fwrite(framebuff, framesize, 1, fp);
fclose(fp);
fp = NULL;
#else
printf("Write framebuff to ffrtsp_push!\n");
fwrite(framebuff, framesize, 1, ffrtsp_push[cur_chn].fp);
#endif
}
执行程序:./ffrtsp_demo_test rtsp://192.168.3.231:8554/stream后,打印会在
“Got one frame from rtsp [5626]”
卡死,同时也没有一句“Write framebuff to ffrtsp_push!”的信息,证明在判断if (ffrtsp_push[cur_chn].fp == NULL)一句时回调函数就退出了。
ffrtsp库走不通,我后面改用ROCKCHIP_RTSP_LIB的官方库,走VI(usb摄像头)——RKNN(yolov5)——VENC——RTSP推流是一点问题也没有的~~~
我在翻查论坛帖子里面也发现有人反映使用你们的ffrtsp库不出流,证明这个问题不是我个例,希望官方技术支持能回复,谢谢。
tchip_askquestions
log.zip (10.7 KB)