日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 >

OpenCV的工具函数

發布時間:2024/7/23 36 豆豆
生活随笔 收集整理的這篇文章主要介紹了 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的工具函数的全部內容,希望文章能夠幫你解決所遇到的問題。

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