Commit 467f9364 authored by Andrey Pavlenko's avatar Andrey Pavlenko

Adding optimized Mat Allocator

parent f05259f2
...@@ -210,7 +210,9 @@ macro(define_opencv_module name) ...@@ -210,7 +210,9 @@ macro(define_opencv_module name)
endif() endif()
# Dependencies of this target: # Dependencies of this target:
add_dependencies(${the_target} ${ARGN}) if(ARGN)
add_dependencies(${the_target} ${ARGN})
endif()
install(TARGETS ${the_target} install(TARGETS ${the_target}
RUNTIME DESTINATION bin COMPONENT main RUNTIME DESTINATION bin COMPONENT main
......
...@@ -203,6 +203,9 @@ void Mat::create(int d, const int* _sizes, int _type) ...@@ -203,6 +203,9 @@ void Mat::create(int d, const int* _sizes, int _type)
if( total() > 0 ) if( total() > 0 )
{ {
#ifdef HAVE_TGPU
if( !allocator ) allocator = tegra::getAllocator(d, _sizes, _type);
#endif
if( !allocator ) if( !allocator )
{ {
size_t total = alignSize(step.p[0]*size.p[0], (int)sizeof(*refcount)); size_t total = alignSize(step.p[0]*size.p[0], (int)sizeof(*refcount));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment