日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

编译cvaux错误的原因

發(fā)布時間:2023/12/10 编程问答 41 豆豆
生活随笔 收集整理的這篇文章主要介紹了 编译cvaux错误的原因 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
平臺vc6.0; 在debug模式下編譯cvaux時會提示三個錯誤: error C2039: 'foreground_regions' : is not a member of 'CvFGDStatModel'

error C2039: 'foreground_regions' : is not a member of 'CvFGDStatModel'

error C2039: 'foreground_regions' : is not a member of 'CvGaussBGModel' 在網上搜到的解決方法都是這樣寫的: 在cvaux.h文件中, 搜索關鍵字foreground_regions,

CvMemStorage* storage; /*storage for 揻oreground_regions?/ \
CvSeq* foreground_regions /*foreground object contours*/

改為如下形式:

CvMemStorage* storage; /*storage for foreground_regions*/ \
CvSeq* foreground_regions /*foreground object contours*/ 具體原因解釋如下:首先foreground_regions 定義在這個宏里面: #define CV_BG_STAT_MODEL_FIELDS()?????????????????????????????????????????????????? \
??? int???????????? type; /*type of BG model*/????????????????????????????????????? \
??? CvReleaseBGStatModel release;?????????????????????????????????????????????????? \
??? CvUpdateBGStatModel update;???????????????????????????????????????????????????? \
??? IplImage*?????? background;?? /*8UC3 reference background image*/?????????????? \
??? IplImage*?????? foreground;?? /*8UC1 foreground image*/???????????????????????? \
??? IplImage**????? layers;?????? /*8UC3 reference background image, can be null */ \
??? int???????????? layer_count;? /* can be zero */???????????????????????????????? \
??? CvMemStorage*?? storage;????? /*storage for 揻oreground_regions?*/????????????? \
??? CvSeq*????????? foreground_regions /*foreground object contours*/ “\”在這里代表續(xù)行的意思。并且注意前面定義的變量后面都有“;”號,而foreground_regions沒有,因為它是這個定義的最后一項,因為宏定義末尾是不加‘;’號的。 另外要注意的是,千萬不要在修改最后兩行時寫成這個樣子:??? CvMemStorage*?? storage;????? /*storage for 揻oreground_regions?*/????????????? \
??? CvSeq*????????? foreground_regions /*foreground object contours*/ 即不能放入空行,因為這樣一來foreground_regions就不屬于宏定義中的一份了。而'CvFGDStatModel''CvGaussBGModel'中均包含了改宏,所以錯誤會照舊的。偶剛開始就犯了這個錯誤,還以為是各位高手犯錯誤了呢。呵呵

轉載于:https://www.cnblogs.com/oskycar/archive/2009/08/30/1556920.html

總結

以上是生活随笔為你收集整理的编译cvaux错误的原因的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。