|
OpenCV 4.5.3(日本語機械翻訳)
|
Class with reference counting wrapping special memory type allocation functions from CUDA. [詳解]
#include <cuda.hpp>
公開型 |
|
| enum | AllocType { PAGE_LOCKED = 1 , SHARED = 2 , WRITE_COMBINED = 4 } |
公開メンバ関数 |
|
| CV_WRAP | HostMem (HostMem::AllocType alloc_type=HostMem::AllocType::PAGE_LOCKED) |
| HostMem (const HostMem &m) | |
| CV_WRAP | HostMem (int rows, int cols, int type, HostMem::AllocType alloc_type=HostMem::AllocType::PAGE_LOCKED) |
| CV_WRAP | HostMem (Size size, int type, HostMem::AllocType alloc_type=HostMem::AllocType::PAGE_LOCKED) |
| CV_WRAP | HostMem (InputArray arr, HostMem::AllocType alloc_type=HostMem::AllocType::PAGE_LOCKED) |
| ホストメモリからデータをコピーして作成します。 |
|
| HostMem & | operator= (const HostMem &m) |
| CV_WRAP void | swap (HostMem &b) |
| 他のスマートポインタと交換する |
|
| CV_WRAP HostMem | clone () const |
| 行列のディープコピーを返す、つまり、データがコピーされる |
|
| CV_WRAP void | create (int rows, int cols, int type) |
| 行列が既に指定されたサイズとタイプを持っていない限り、新しい行列データを割り当てます。 |
|
| void | create (Size size, int type) |
| CV_WRAP HostMem | reshape (int cn, int rows=0) const |
| void | release () |
| 必要であれば,参照カウンタをデクリメントし,メモリを解放します. |
|
| CV_WRAP Mat | createMatHeader () const |
| データの参照カウントを無効にして,行列のヘッダを返します.HostMemデータを返します. |
|
| GpuMat | createGpuMatHeader () const |
| CPUのメモリをGPUのアドレス空間にマッピングし、ヘッダを作成します。cuda::GpuMatヘッダを参照カウントせずに作成します。[【詳解】(英語]
|
|
| CV_WRAP bool | isContinuous () const |
| CV_WRAP size_t | elemSize () const |
| CV_WRAP size_t | elemSize1 () const |
| CV_WRAP int | type () const |
| CV_WRAP int | depth () const |
| CV_WRAP int | channels () const |
| CV_WRAP size_t | step1 () const |
| CV_WRAP Size | size () const |
| CV_WRAP bool | empty () const |
静的公開メンバ関数 |
|
| static MatAllocator * | getAllocator (HostMem::AllocType alloc_type=HostMem::AllocType::PAGE_LOCKED) |
公開変数類 |
|
| int | flags |
| int | rows |
| int | cols |
| CV_PROP size_t | step |
| uchar * | data |
| int * | refcount |
| uchar * | datastart |
| const uchar * | dataend |
| AllocType | alloc_type |
CUDAの特殊なメモリタイプの割り当て関数をラッピングした参照カウントのクラスです。
インターフェースも Mat に似ていますが,メモリタイプのパラメータが追加されています.
| GpuMat cv::cuda::HostMem::createGpuMatHeader | ( | ) | const |
CPUのメモリをGPUのアドレス空間にマッピングし、ヘッダを作成します。cuda::GpuMatヘッダを参照カウントせずに作成します。
これは、メモリがSHAREDフラグで割り当てられていて、かつハードウェアでサポートされている場合にのみ行うことができます。ノートパソコンでは、ビデオメモリとCPUメモリを共有していることが多いので、アドレス空間をマッピングすることで、余分なコピーを省くことができます。
| CV_WRAP HostMem cv::cuda::HostMem::reshape | ( | int | cn, |
| int |
rows
=
0 |
||
| ) | const |
は、同じデータに対して、異なる内容の代替HostMem同じデータに対して、チャンネル数や行数を変えた別のヘッダーを作成する。