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

歡迎訪問 生活随笔!

生活随笔

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

编程问答

OpenCV的工具函数

發布時間:2024/7/23 编程问答 29 豆豆
生活随笔 收集整理的這篇文章主要介紹了 OpenCV的工具函数 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

OpenCV3也提供了一些經常用于計算機視覺的實用功能,列舉如下:

功能描述
cv::alignPtr()

Align pointer to given number of bytes

對齊指針到指定字節數

cv::alignSize()

Align buffer size to given number of bytes

將緩存區大小與給定的字節數對齊

cv::allocate()

Allocate a C-style array of objects

分配一個C風格的數組對象

cvCeil()Round float number x to nearest integer not smaller than x近似一個浮點數x到不小于x的最近的整數(向上取整)
cv::cubeRoot()

Compute the cube root of a number

計算一個數的立方根

cv::CV_Assert()

Throw an exception if a given condition is not true

如果給定條件為假,則拋出異常

CV_Error()

Macro to build a cv::Exception (from a fixed string) and throw it

構造cv::Exception(從固定的字符串)并拋出異常的一個宏

CV_Error_()

Macro to build a cv::Exception (from a formatted string) and throw it

構造cv::Exception(從格式化的字符串)并拋出異常的一個宏

cv::deallocate()

Deallocate a C-style array of objects

釋放一個C風格的數組對象

cv::error()

Indicate an error and throw an exception

指示錯誤并拋出異常

cv::fastAtan2()

Calculate two-dimensional angle of a vector in degrees

向量的二維角度的計算,取值范圍 [ 0.0, 360.0 )

cv::fastFree()

Deallocate a memory buffer

釋放一個內存緩存區

cv::fastMalloc()

Allocate an aligned memory buffer

分配一個對齊的內存緩存區

cvFloor()

Round float number x to nearest integer not larger than x

近似一個浮點數x到不大于x的最近的整數(向下取整)

cv::format()

Create an STL string using sprintf-like formatting

以sprintf類似格式創建一個STL字符串

cv::getCPUTickCount()

Get tick count from internal CPU timer

從內部CPU計時器獲得tick計數

cv::getNumThreads()

Count number of threads currently used by OpenCV

獲得當前OpenCV使用的線程數

cv::getOptimalDFTSize()

Compute the best size for an array that you plan to pass to cv::DFT()

計算要傳遞給cv::DFT()的數組的最適宜大小

cv::getThreadNum()

Get index of the current thread

獲得當前線程的索引

cv::getTickCount()

Get tick count from system

獲得系統的tick計數

cv::getTickFrequency()

Get number or ticks per second (see cv::getTickCount())

獲得每秒的tick計數

cvIsInf()

Check if a floating-point number x is infinity

判斷一個浮點數x是否無窮

cvIsNaN()

Check if a floating-point number x is “Not a Number”

判斷一個浮點數x是否不是一個數

cvRound()

Round float number x to the nearest integer

近似一個浮點數x到最近的整數(四舍五入)

cv::setNumThreads()

Set number of threads used by OpenCV

設定OpenCV使用的線程數

cv::setUseOptimized()

Enables or disables the use of optimized code (SSE2, etc.)

開啟或關閉優化代碼 (SSE2, etc.)

cv::useOptimized()

Indicates status of optimized code enabling?

指示代碼優化的啟用

總結

以上是生活随笔為你收集整理的OpenCV的工具函数的全部內容,希望文章能夠幫你解決所遇到的問題。

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