VC ++中的断言错误 [英] Assertion Error in VC++
本文介绍了VC ++中的断言错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在VC ++中的项目中收到断言错误(流!= NUll).我已经使用断点来指出导致错误的代码块.
I am getting an assertion error (stream!= NUll) in my Project in VC++. I have used breakpoints to pin point the block of code which causes the error.
SVisFileDescriptor filedescriptorT;
ZeroMemory(&filedescriptorT, sizeof(SVisFileDescriptor));
filedescriptorT.has_alpha_channel=CVisImageBase::IsAlphaWritten();
filedescriptorT.jpeg_quality=0;
filedescriptorT.filename=currentpath;
imageS.WriteFile(filedescriptorT);
该块基本上可以通过3种不同的功能进行复制,从本质上来说,这可以从连接的摄像机中节省1个图像.我不确定为什么会这样.但是我的直觉是某种程度上存在重叠,这就是为什么它保存1张图像(部分保存)而无法保存其他2张图像的原因
任何帮助将不胜感激.
谢谢,
Vivek
This block is basically replicated in 3 different functions which in essence save 1 image EACH from a camera connected. I am not sure why this is happening. But my hunch is there is an overlap in someway which is why it saves 1 image(well partly) and fails to save the other 2
Any help would be greatly appreciated.
Thanks,
Vivek
推荐答案
您是否要写入已关闭的文件?似乎是可能的原因(即文件输出流未初始化).
Are you trying to write to a file that''s closed? Seems like a likely cause (i.e. file output stream is not initialized).
这篇关于VC ++中的断言错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文