[][src]Trait opencv::hub_prelude::SparseMatConstIteratorTrait

pub trait SparseMatConstIteratorTrait {
    pub fn as_raw_SparseMatConstIterator(&self) -> *const c_void;
pub fn as_raw_mut_SparseMatConstIterator(&mut self) -> *mut c_void; pub fn m(&self) -> SparseMat { ... }
pub fn hashidx(&self) -> size_t { ... }
pub fn set_hashidx(&mut self, val: size_t) { ... }
pub fn ptr(&mut self) -> &mut u8 { ... }
pub fn set_ptr(&mut self, val: &mut u8) { ... }
pub fn node(&self) -> Result<SparseMat_Node> { ... }
pub fn seek_end(&mut self) -> Result<()> { ... } }

Read-Only Sparse Matrix Iterator.

Here is how to use the iterator to compute the sum of floating-point sparse matrix elements:

\code SparseMatConstIterator it = m.begin(), it_end = m.end(); double s = 0; CV_Assert( m.type() == CV_32F ); for( ; it != it_end; ++it ) s += it.value(); \endcode

Required methods

Loading content...

Provided methods

pub fn m(&self) -> SparseMat[src]

pub fn hashidx(&self) -> size_t[src]

pub fn set_hashidx(&mut self, val: size_t)[src]

pub fn ptr(&mut self) -> &mut u8[src]

pub fn set_ptr(&mut self, val: &mut u8)[src]

pub fn node(&self) -> Result<SparseMat_Node>[src]

returns the current node of the sparse matrix. it.node->idx is the current element index

pub fn seek_end(&mut self) -> Result<()>[src]

moves iterator to the element after the last element

Loading content...

Implementors

Loading content...