[][src]Struct opencv::core::_OutputArray

pub struct _OutputArray { /* fields omitted */ }

This type is very similar to InputArray except that it is used for input/output and output function parameters.

Just like with InputArray, OpenCV users should not care about OutputArray, they just pass Mat, vector<T> etc. to the functions. The same limitation as for InputArray: Do not explicitly create OutputArray instances applies here too.

If you want to make your function polymorphic (i.e. accept different arrays as output parameters), it is also not very difficult. Take the sample above as the reference. Note that _OutputArray::create() needs to be called before _OutputArray::getMat(). This way you guarantee that the output array is properly allocated.

Optional output parameters. If you do not need certain output array to be computed and returned to you, pass cv::noArray(), just like you would in the case of optional input array. At the implementation level, use _OutputArray::needed() to check if certain output array needs to be computed or not.

There are several synonyms for OutputArray that are used to assist automatic Python/Java/... wrapper generators:

   typedef OutputArray OutputArrayOfArrays;
   typedef OutputArray InputOutputArray;
   typedef OutputArray InputOutputArrayOfArrays;

Implementations

impl _OutputArray[src]

impl _OutputArray[src]

pub fn default() -> Result<_OutputArray>[src]

/////////////////////////////////////////////////////////////////////////////////////

pub fn new(_flags: i32, _obj: *mut c_void) -> Result<_OutputArray>[src]

pub fn from_mat_mut(m: &mut Mat) -> Result<_OutputArray>[src]

pub fn from_mat_vec_mut(vec: &mut Vector<Mat>) -> Result<_OutputArray>[src]

pub fn from_gpumat_mut(d_mat: &mut GpuMat) -> Result<_OutputArray>[src]

pub fn from_gpumat_vec_mut(d_mat: &mut Vector<GpuMat>) -> Result<_OutputArray>[src]

pub fn new_1(buf: &mut Buffer) -> Result<_OutputArray>[src]

pub fn from_hostmem_mut(cuda_mem: &mut HostMem) -> Result<_OutputArray>[src]

pub fn from_umat_mut(m: &mut UMat) -> Result<_OutputArray>[src]

pub fn from_umat_vec_mut(vec: &mut Vector<UMat>) -> Result<_OutputArray>[src]

pub fn from_mat(m: &Mat) -> Result<_OutputArray>[src]

pub fn from_mat_vec(vec: &Vector<Mat>) -> Result<_OutputArray>[src]

pub fn from_gpumat(d_mat: &GpuMat) -> Result<_OutputArray>[src]

pub fn new_2(buf: &Buffer) -> Result<_OutputArray>[src]

pub fn from_hostmem(cuda_mem: &HostMem) -> Result<_OutputArray>[src]

pub fn from_umat(m: &UMat) -> Result<_OutputArray>[src]

pub fn from_umat_vec(vec: &Vector<UMat>) -> Result<_OutputArray>[src]

Trait Implementations

impl Boxed for _OutputArray[src]

impl Drop for _OutputArray[src]

impl Send for _OutputArray[src]

impl _InputArrayTrait for _OutputArray[src]

impl _OutputArrayTrait for _OutputArray[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.