2869
- 收藏
- 点赞
- 分享
- 举报
VDEC解码后在VPSS获取YUV图像出现乱码
本帖最后由 qn1539685212 于 2020-6-8 16:46 编辑
static int dzYuvToBgr(VIDEO_FRAME_INFO_S srcFrameInfo){
int s32Ret;
IVE_CSC_CTRL_S pstCscCtrl;
IVE_IMAGE_S pstSrc;
IVE_DST_IMAGE_S pstDst;
HI_CHAR *BgrData;
HI_CHAR *BgrData1;
HI_BOOL bInstant;
static int i = 0;
char filename[] = "lsbmp.yuv";
char filename1[32] = "";
int count;
printf("u32Width = %d,Height = %d,stride = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[0]);
printf("u32Width = %d,Height = %d,stride1 = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[1]);
printf("u32Width = %d,Height = %d,stride2 = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[2]);
i++;
if(i > 10){
i = 0;
}
sprintf(filename1,"./%d%s",i,filename);
printf("%s\n",filename1);
printf("+++++++++++3+++++++\n");
FILE *file = fopen(filename1, "wb");
if (!file)
{
printf("Could not write file\n");
return;
}
sample_yuv_8bit_dump(&srcFrameInfo.stVFrame,file);
fclose(file);
HI_MPI_SYS_Munmap(BgrData,(1920 * 1080) * 3/2);
}
打印消息如下:
u32Width = 1920,Height = 1080,stride = 1920
u32Width = 1920,Height = 1080,stride1 = 1920
u32Width = 1920,Height = 1080,stride2 = 1920
./2lsbmp.yuv
+++++++++++3+++++++
saving......Y......U......V......done 114!
static int dzYuvToBgr(VIDEO_FRAME_INFO_S srcFrameInfo){
int s32Ret;
IVE_CSC_CTRL_S pstCscCtrl;
IVE_IMAGE_S pstSrc;
IVE_DST_IMAGE_S pstDst;
HI_CHAR *BgrData;
HI_CHAR *BgrData1;
HI_BOOL bInstant;
static int i = 0;
char filename[] = "lsbmp.yuv";
char filename1[32] = "";
int count;
printf("u32Width = %d,Height = %d,stride = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[0]);
printf("u32Width = %d,Height = %d,stride1 = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[1]);
printf("u32Width = %d,Height = %d,stride2 = %d\n",srcFrameInfo.stVFrame.u32Width,srcFrameInfo.stVFrame.u32Height,srcFrameInfo.stVFrame.u32Stride[2]);
i++;
if(i > 10){
i = 0;
}
sprintf(filename1,"./%d%s",i,filename);
printf("%s\n",filename1);
printf("+++++++++++3+++++++\n");
FILE *file = fopen(filename1, "wb");
if (!file)
{
printf("Could not write file\n");
return;
}
sample_yuv_8bit_dump(&srcFrameInfo.stVFrame,file);
fclose(file);
HI_MPI_SYS_Munmap(BgrData,(1920 * 1080) * 3/2);
}
打印消息如下:
u32Width = 1920,Height = 1080,stride = 1920
u32Width = 1920,Height = 1080,stride1 = 1920
u32Width = 1920,Height = 1080,stride2 = 1920
./2lsbmp.yuv
+++++++++++3+++++++
saving......Y......U......V......done 114!
我来回答
回答5个
时间排序
认可量排序
认可0
认可0
认可0
认可0
认可0
或将文件直接拖到这里
悬赏:
E币
网盘
* 网盘链接:
* 提取码:
悬赏:
E币
Markdown 语法
- 加粗**内容**
- 斜体*内容*
- 删除线~~内容~~
- 引用> 引用内容
- 代码`代码`
- 代码块```编程语言↵代码```
- 链接[链接标题](url)
- 无序列表- 内容
- 有序列表1. 内容
- 缩进内容
- 图片![alt](url)
相关问答
-
2021-01-14 11:46:44
-
2020-04-03 10:30:30
-
2020-01-13 16:19:44
-
2018-12-27 09:28:26
-
2021-01-13 13:40:57
-
2016-07-19 16:36:55
-
2019-11-25 18:36:13
-
2019-02-16 16:46:46
-
2016-11-06 23:18:26
-
2020-06-18 16:28:23
-
2017-08-14 14:32:18
-
2020-05-11 15:28:32
-
2020-03-07 16:16:03
-
2024-10-31 14:51:35
-
2017-06-21 17:05:51
-
2020-12-24 14:29:32
-
2018-06-15 16:29:14
-
2019-09-06 17:25:55
-
2019-07-08 09:21:28
无更多相似问答 去提问
点击登录
-- 积分
-- E币
提问
—
收益
—
被采纳
—
我要提问
切换马甲
上一页
下一页
悬赏问答
-
5Hi3516CV610 如何使用SD卡升级固件
-
5cat /dev/logmpp 报错 <3>[ vi] [func]:vi_send_frame_node [line]:99 [info]:vi pic queue is full!
-
50如何获取vpss chn的图像修改后发送至vo
-
5FPGA通过Bt1120传YUV422数据过来,vi接收不到数据——3516dv500
-
50SS928 运行PQtools 拼接 推到设备里有一半画面会异常
-
53536AV100的sample_vdec输出到CVBS显示
-
10海思板子mpp怎么在vi阶段改变视频数据尺寸
-
10HI3559AV100 多摄像头同步模式
-
9海思ss928单路摄像头vio中加入opencv处理并显示
-
10EB-RV1126-BC-191板子运行自己编码的程序
举报反馈
举报类型
- 内容涉黄/赌/毒
- 内容侵权/抄袭
- 政治相关
- 涉嫌广告
- 侮辱谩骂
- 其他
详细说明
提醒
你的问题还没有最佳答案,是否结题,结题后将扣除20%的悬赏金
取消
确认
提醒
你的问题还没有最佳答案,是否结题,结题后将根据回答情况扣除相应悬赏金(1回答=1E币)
取消
确认