From e679d971008999579734e941fad6ba89cfcc77c6 Mon Sep 17 00:00:00 2001 From: hoangviet1985 Date: Sun, 22 Nov 2015 14:32:18 -0500 Subject: [PATCH] remove redundant code --- modules/core/src/convert.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/core/src/convert.cpp b/modules/core/src/convert.cpp index 1e9d832f33..fbbea5e1b1 100644 --- a/modules/core/src/convert.cpp +++ b/modules/core/src/convert.cpp @@ -924,11 +924,10 @@ void cv::split(InputArray _m, OutputArrayOfArrays _mv) CV_Assert( !_mv.fixedType() || _mv.empty() || _mv.type() == m.depth() ); - Size size = m.size(); int depth = m.depth(), cn = m.channels(); _mv.create(cn, 1, depth); for (int i = 0; i < cn; ++i) - _mv.create(size, depth, i); + _mv.create(m.dims, m.size.p, depth, i); std::vector dst; _mv.getMatVector(dst);