• Kazuki Matsuda's avatar
    Implimentation "cv::Mat::forEach" · fa292c3d
    Kazuki Matsuda authored
    I propose forEach method for cv::Mat and cv::Mat_.
    This is solution for the overhead of MatIterator_<_Tp>.
    
    I runs a test that micro opecode runs all over the pixel of cv::Mat_<cv::Point3_<uint8_t>>.
    And this implementation 40% faster than the simple pointer, 80% faster than iterator.
    With OpenMP, 70% faster than simple pointer, 95% faster than iterator (Core i7 920).
    
    Above all, code is more readable.
    
    My test code is here.
        https://gist.github.com/kazuki-ma/8285876
    
    Thanks.
    fa292c3d
Name
Last commit
Last update
..
ocl Loading commit data...
test_arithm.cpp Loading commit data...
test_countnonzero.cpp Loading commit data...
test_ds.cpp Loading commit data...
test_dxt.cpp Loading commit data...
test_eigen.cpp Loading commit data...
test_io.cpp Loading commit data...
test_ippasync.cpp Loading commit data...
test_main.cpp Loading commit data...
test_mat.cpp Loading commit data...
test_math.cpp Loading commit data...
test_misc.cpp Loading commit data...
test_operations.cpp Loading commit data...
test_precomp.hpp Loading commit data...
test_ptr.cpp Loading commit data...
test_rand.cpp Loading commit data...
test_rotatedrect.cpp Loading commit data...
test_umat.cpp Loading commit data...