Struct opencv::core::SparseMatConstIterator
source · pub struct SparseMatConstIterator { /* private fields */ }
Expand description
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
Implementations§
source§impl SparseMatConstIterator
impl SparseMatConstIterator
sourcepub fn default() -> Result<SparseMatConstIterator>
pub fn default() -> Result<SparseMatConstIterator>
the default constructor
sourcepub fn new(_m: &SparseMat) -> Result<SparseMatConstIterator>
pub fn new(_m: &SparseMat) -> Result<SparseMatConstIterator>
the full constructor setting the iterator to the first sparse matrix element
sourcepub fn copy(it: &SparseMatConstIterator) -> Result<SparseMatConstIterator>
pub fn copy(it: &SparseMatConstIterator) -> Result<SparseMatConstIterator>
the copy constructor
Trait Implementations§
source§impl Boxed for SparseMatConstIterator
impl Boxed for SparseMatConstIterator
source§impl Debug for SparseMatConstIterator
impl Debug for SparseMatConstIterator
source§impl Drop for SparseMatConstIterator
impl Drop for SparseMatConstIterator
source§impl From<SparseMatIterator> for SparseMatConstIterator
impl From<SparseMatIterator> for SparseMatConstIterator
source§fn from(s: SparseMatIterator) -> Self
fn from(s: SparseMatIterator) -> Self
Converts to this type from the input type.
source§impl SparseMatConstIteratorTrait for SparseMatConstIterator
impl SparseMatConstIteratorTrait for SparseMatConstIterator
impl Send for SparseMatConstIterator
Auto Trait Implementations§
impl RefUnwindSafe for SparseMatConstIterator
impl !Sync for SparseMatConstIterator
impl Unpin for SparseMatConstIterator
impl UnwindSafe for SparseMatConstIterator
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more