[−][src]Struct opencv::core::_OutputArray
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]
pub fn as_raw__OutputArray(&self) -> *const c_void
[src]
pub fn as_raw_mut__OutputArray(&mut self) -> *mut c_void
[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]
pub unsafe fn from_raw(ptr: *mut c_void) -> Self
[src]
pub fn into_raw(self) -> *mut c_void
[src]
pub fn as_raw(&self) -> *const c_void
[src]
pub fn as_raw_mut(&mut self) -> *mut c_void
[src]
impl Drop for _OutputArray
[src]
impl Send for _OutputArray
[src]
impl _InputArrayTrait for _OutputArray
[src]
pub fn as_raw__InputArray(&self) -> *const c_void
[src]
pub fn as_raw_mut__InputArray(&mut self) -> *mut c_void
[src]
pub fn get_mat(&self, idx: i32) -> Result<Mat>
[src]
pub fn get_mat_(&self, idx: i32) -> Result<Mat>
[src]
pub fn get_umat(&self, idx: i32) -> Result<UMat>
[src]
pub fn get_mat_vector(&self, mv: &mut Vector<Mat>) -> Result<()>
[src]
pub fn get_umat_vector(&self, umv: &mut Vector<UMat>) -> Result<()>
[src]
pub fn get_gpu_mat_vector(&self, gpumv: &mut Vector<GpuMat>) -> Result<()>
[src]
pub fn get_gpu_mat(&self) -> Result<GpuMat>
[src]
pub fn get_o_gl_buffer(&self) -> Result<Buffer>
[src]
pub fn get_flags(&self) -> Result<i32>
[src]
pub fn get_obj(&self) -> Result<*mut c_void>
[src]
pub fn get_sz(&self) -> Result<Size>
[src]
pub fn kind(&self) -> Result<_InputArray_KindFlag>
[src]
pub fn dims(&self, i: i32) -> Result<i32>
[src]
pub fn cols(&self, i: i32) -> Result<i32>
[src]
pub fn rows(&self, i: i32) -> Result<i32>
[src]
pub fn size(&self, i: i32) -> Result<Size>
[src]
pub fn sizend(&self, sz: &mut i32, i: i32) -> Result<i32>
[src]
pub fn same_size(&self, arr: &dyn ToInputArray) -> Result<bool>
[src]
pub fn total(&self, i: i32) -> Result<size_t>
[src]
pub fn typ(&self, i: i32) -> Result<i32>
[src]
pub fn depth(&self, i: i32) -> Result<i32>
[src]
pub fn channels(&self, i: i32) -> Result<i32>
[src]
pub fn is_continuous(&self, i: i32) -> Result<bool>
[src]
pub fn is_submatrix(&self, i: i32) -> Result<bool>
[src]
pub fn empty(&self) -> Result<bool>
[src]
pub fn copy_to(&self, arr: &mut dyn ToOutputArray) -> Result<()>
[src]
pub fn copy_to_masked(
&self,
arr: &mut dyn ToOutputArray,
mask: &dyn ToInputArray
) -> Result<()>
[src]
&self,
arr: &mut dyn ToOutputArray,
mask: &dyn ToInputArray
) -> Result<()>
pub fn offset(&self, i: i32) -> Result<size_t>
[src]
pub fn step(&self, i: i32) -> Result<size_t>
[src]
pub fn is_mat(&self) -> Result<bool>
[src]
pub fn is_umat(&self) -> Result<bool>
[src]
pub fn is_mat_vector(&self) -> Result<bool>
[src]
pub fn is_umat_vector(&self) -> Result<bool>
[src]
pub fn is_matx(&self) -> Result<bool>
[src]
pub fn is_vector(&self) -> Result<bool>
[src]
pub fn is_gpu_mat(&self) -> Result<bool>
[src]
pub fn is_gpu_mat_vector(&self) -> Result<bool>
[src]
impl _OutputArrayTrait for _OutputArray
[src]
pub fn as_raw__OutputArray(&self) -> *const c_void
[src]
pub fn as_raw_mut__OutputArray(&mut self) -> *mut c_void
[src]
pub fn fixed_size(&self) -> Result<bool>
[src]
pub fn fixed_type(&self) -> Result<bool>
[src]
pub fn needed(&self) -> Result<bool>
[src]
pub fn get_mat_ref(&self, i: i32) -> Result<Mat>
[src]
pub fn get_umat_ref(&self, i: i32) -> Result<UMat>
[src]
pub fn get_gpu_mat_ref(&self) -> Result<GpuMat>
[src]
pub fn get_gpu_mat_vec_ref(&self) -> Result<Vector<GpuMat>>
[src]
pub fn get_o_gl_buffer_ref(&self) -> Result<Buffer>
[src]
pub fn get_host_mem_ref(&self) -> Result<HostMem>
[src]
pub fn create_size(
&self,
sz: Size,
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
[src]
&self,
sz: Size,
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
pub fn create(
&self,
rows: i32,
cols: i32,
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
[src]
&self,
rows: i32,
cols: i32,
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
pub fn create_nd(
&self,
size: &[i32],
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
[src]
&self,
size: &[i32],
typ: i32,
i: i32,
allow_transposed: bool,
fixed_depth_mask: _OutputArray_DepthMask
) -> Result<()>
pub unsafe fn create_same_size(
&self,
arr: &dyn ToInputArray,
mtype: i32
) -> Result<()>
[src]
&self,
arr: &dyn ToInputArray,
mtype: i32
) -> Result<()>
pub fn release(&self) -> Result<()>
[src]
pub fn clear(&self) -> Result<()>
[src]
pub fn set_to(
&self,
value: &dyn ToInputArray,
mask: &dyn ToInputArray
) -> Result<()>
[src]
&self,
value: &dyn ToInputArray,
mask: &dyn ToInputArray
) -> Result<()>
pub fn assign(&self, u: &UMat) -> Result<()>
[src]
pub fn assign_1(&self, m: &Mat) -> Result<()>
[src]
pub fn assign_2(&self, v: &Vector<UMat>) -> Result<()>
[src]
pub fn assign_3(&self, v: &Vector<Mat>) -> Result<()>
[src]
pub fn move_(&self, u: &mut UMat) -> Result<()>
[src]
pub fn move__1(&self, m: &mut Mat) -> Result<()>
[src]
Auto Trait Implementations
impl RefUnwindSafe for _OutputArray
[src]
impl !Sync for _OutputArray
[src]
impl Unpin for _OutputArray
[src]
impl UnwindSafe for _OutputArray
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,