Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
901e1e46
Commit
901e1e46
authored
Jun 03, 2016
by
Vladislav Sovrasov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update HAL samples
parent
e1ba4399
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
50 additions
and
32 deletions
+50
-32
CMakeLists.txt
samples/hal/c_hal/CMakeLists.txt
+13
-4
config.cmake
samples/hal/c_hal/config.cmake
+5
-5
impl.c
samples/hal/c_hal/impl.c
+7
-7
impl.h
samples/hal/c_hal/impl.h
+7
-7
CMakeLists.txt
samples/hal/slow_hal/CMakeLists.txt
+13
-4
config.cmake
samples/hal/slow_hal/config.cmake
+5
-5
No files found.
samples/hal/c_hal/CMakeLists.txt
View file @
901e1e46
cmake_minimum_required
(
VERSION 2.8.8 FATAL_ERROR
)
add_library
(
c_hal impl.c
)
set_target_properties
(
c_hal PROPERTIES POSITION_INDEPENDENT_CODE TRUE
)
set
(
PROJECT_NAME
"c_hal"
)
set
(
HAL_LIB_NAME
"c_hal"
)
add_library
(
${
HAL_LIB_NAME
}
impl.c
)
set_target_properties
(
${
HAL_LIB_NAME
}
PROPERTIES POSITION_INDEPENDENT_CODE TRUE
)
set
(
OPENCV_SRC_DIR
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/../../.."
)
target_include_directories
(
c_hal PUBLIC
${
CMAKE_CURRENT_SOURCE_DIR
}
${
OPENCV_SRC_DIR
}
/modules/core/include
)
target_include_directories
(
${
HAL_LIB_NAME
}
PUBLIC
${
CMAKE_CURRENT_SOURCE_DIR
}
${
OPENCV_SRC_DIR
}
/modules/core/include
)
set
(
OpenCV_HAL_FOUND TRUE
)
set
(
OpenCV_HAL_VERSION 0.0.1
)
set
(
OpenCV_HAL_LIBRARIES
${
CMAKE_CURRENT_BINARY_DIR
}
/lib
${
HAL_LIB_NAME
}
.a
)
set
(
OpenCV_HAL_HEADERS
"impl.h"
)
set
(
OpenCV_HAL_INCLUDE_DIRS
${
CMAKE_CURRENT_LIST_DIR
}
)
configure_file
(
"impl.h"
"
${
CMAKE_BINARY_DIR
}
/impl.h"
COPYONLY
)
configure_file
(
"config.cmake"
"
${
CMAKE_BINARY_DIR
}
/OpenCV_HALConfig.cmake"
COPYONLY
)
configure_file
(
"config.cmake"
"
${
CMAKE_BINARY_DIR
}
/OpenCV_HALConfig.cmake"
)
samples/hal/c_hal/config.cmake
View file @
901e1e46
set
(
OpenCV_HAL_FOUND
TRUE
)
set
(
OpenCV_HAL_VERSION
"0.0.1"
)
set
(
OpenCV_HAL_LIBRARIES
"
${
CMAKE_CURRENT_LIST_DIR
}
/libc_hal.a"
)
set
(
OpenCV_HAL_HEADERS
"impl.h"
)
set
(
OpenCV_HAL_INCLUDE_DIRS
"
${
CMAKE_CURRENT_LIST_DIR
}
"
)
set
(
OpenCV_HAL_FOUND
@OpenCV_HAL_FOUND@
)
set
(
OpenCV_HAL_VERSION
@OpenCV_HAL_VERSION@
)
set
(
OpenCV_HAL_LIBRARIES
@OpenCV_HAL_LIBRARIES@
)
set
(
OpenCV_HAL_HEADERS
@OpenCV_HAL_HEADERS@
)
set
(
OpenCV_HAL_INCLUDE_DIRS
@OpenCV_HAL_INCLUDE_DIRS@
)
samples/hal/c_hal/impl.c
View file @
901e1e46
...
...
@@ -300,37 +300,37 @@ int wrong_div64f(const double* src1, size_t sz1, const double* src2, size_t sz2,
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip8u
(
const
uchar
*
src
1
,
size_t
sz1
,
const
uchar
*
src
2
,
size_t
sz2
,
uchar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip8u
(
const
uchar
*
src2
,
size_t
sz2
,
uchar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip8s
(
const
schar
*
src
1
,
size_t
sz1
,
const
schar
*
src
2
,
size_t
sz2
,
schar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip8s
(
const
schar
*
src2
,
size_t
sz2
,
schar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip16u
(
const
ushort
*
src
1
,
size_t
sz1
,
const
ushort
*
src
2
,
size_t
sz2
,
ushort
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip16u
(
const
ushort
*
src2
,
size_t
sz2
,
ushort
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip16s
(
const
short
*
src
1
,
size_t
sz1
,
const
short
*
src
2
,
size_t
sz2
,
short
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip16s
(
const
short
*
src2
,
size_t
sz2
,
short
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip32s
(
const
int
*
src
1
,
size_t
sz1
,
const
int
*
src
2
,
size_t
sz2
,
int
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip32s
(
const
int
*
src2
,
size_t
sz2
,
int
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip32f
(
const
float
*
src
1
,
size_t
sz1
,
const
float
*
src
2
,
size_t
sz2
,
float
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip32f
(
const
float
*
src2
,
size_t
sz2
,
float
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
int
wrong_recip64f
(
const
double
*
src
1
,
size_t
sz1
,
const
double
*
src
2
,
size_t
sz2
,
double
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
int
wrong_recip64f
(
const
double
*
src2
,
size_t
sz2
,
double
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
)
{
return
CV_HAL_ERROR_UNKNOWN
;
// to test how OpenCV handles errors from external HAL
}
...
...
samples/hal/c_hal/impl.h
View file @
901e1e46
...
...
@@ -164,13 +164,13 @@ int wrong_div16s(const short* src1, size_t sz1, const short* src2, size_t sz2, s
int
wrong_div32s
(
const
int
*
src1
,
size_t
sz1
,
const
int
*
src2
,
size_t
sz2
,
int
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_div32f
(
const
float
*
src1
,
size_t
sz1
,
const
float
*
src2
,
size_t
sz2
,
float
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_div64f
(
const
double
*
src1
,
size_t
sz1
,
const
double
*
src2
,
size_t
sz2
,
double
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip8u
(
const
uchar
*
src
1
,
size_t
sz1
,
const
uchar
*
src
2
,
size_t
sz2
,
uchar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip8s
(
const
schar
*
src
1
,
size_t
sz1
,
const
schar
*
src
2
,
size_t
sz2
,
schar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip16u
(
const
ushort
*
src
1
,
size_t
sz1
,
const
ushort
*
src
2
,
size_t
sz2
,
ushort
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip16s
(
const
short
*
src
1
,
size_t
sz1
,
const
short
*
src
2
,
size_t
sz2
,
short
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip32s
(
const
int
*
src
1
,
size_t
sz1
,
const
int
*
src
2
,
size_t
sz2
,
int
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip32f
(
const
float
*
src
1
,
size_t
sz1
,
const
float
*
src
2
,
size_t
sz2
,
float
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip64f
(
const
double
*
src
1
,
size_t
sz1
,
const
double
*
src
2
,
size_t
sz2
,
double
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip8u
(
const
uchar
*
src2
,
size_t
sz2
,
uchar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip8s
(
const
schar
*
src2
,
size_t
sz2
,
schar
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip16u
(
const
ushort
*
src2
,
size_t
sz2
,
ushort
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip16s
(
const
short
*
src2
,
size_t
sz2
,
short
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip32s
(
const
int
*
src2
,
size_t
sz2
,
int
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip32f
(
const
float
*
src2
,
size_t
sz2
,
float
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
int
wrong_recip64f
(
const
double
*
src2
,
size_t
sz2
,
double
*
dst
,
size_t
sz
,
int
w
,
int
h
,
double
scale
);
#undef cv_hal_mul8u
#define cv_hal_mul8u wrong_mul8u
...
...
samples/hal/slow_hal/CMakeLists.txt
View file @
901e1e46
cmake_minimum_required
(
VERSION 2.8.8 FATAL_ERROR
)
add_library
(
slow_hal impl.cpp
)
set_target_properties
(
slow_hal PROPERTIES POSITION_INDEPENDENT_CODE TRUE
)
set
(
PROJECT_NAME
"slow_hal"
)
set
(
HAL_LIB_NAME
"slow_hal"
)
add_library
(
${
HAL_LIB_NAME
}
impl.cpp
)
set_target_properties
(
${
HAL_LIB_NAME
}
PROPERTIES POSITION_INDEPENDENT_CODE TRUE
)
set
(
OPENCV_SRC_DIR
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/../../.."
)
target_include_directories
(
slow_hal PUBLIC
${
CMAKE_CURRENT_SOURCE_DIR
}
${
OPENCV_SRC_DIR
}
/modules/core/include
)
target_include_directories
(
${
HAL_LIB_NAME
}
PUBLIC
${
CMAKE_CURRENT_SOURCE_DIR
}
${
OPENCV_SRC_DIR
}
/modules/core/include
)
set
(
OpenCV_HAL_FOUND TRUE
)
set
(
OpenCV_HAL_VERSION 0.0.1
)
set
(
OpenCV_HAL_LIBRARIES
${
CMAKE_CURRENT_BINARY_DIR
}
/lib
${
HAL_LIB_NAME
}
.a
)
set
(
OpenCV_HAL_HEADERS
"impl.hpp"
)
set
(
OpenCV_HAL_INCLUDE_DIRS
${
CMAKE_CURRENT_LIST_DIR
}
)
configure_file
(
"impl.hpp"
"
${
CMAKE_BINARY_DIR
}
/impl.hpp"
COPYONLY
)
configure_file
(
"config.cmake"
"
${
CMAKE_BINARY_DIR
}
/OpenCV_HALConfig.cmake"
COPYONLY
)
configure_file
(
"config.cmake"
"
${
CMAKE_BINARY_DIR
}
/OpenCV_HALConfig.cmake"
)
samples/hal/slow_hal/config.cmake
View file @
901e1e46
set
(
OpenCV_HAL_FOUND
TRUE
)
set
(
OpenCV_HAL_VERSION
"0.0.1"
)
set
(
OpenCV_HAL_LIBRARIES
"
${
CMAKE_CURRENT_LIST_DIR
}
/libslow_hal.a"
)
set
(
OpenCV_HAL_HEADERS
"impl.hpp"
)
set
(
OpenCV_HAL_INCLUDE_DIRS
"
${
CMAKE_CURRENT_LIST_DIR
}
"
)
set
(
OpenCV_HAL_FOUND
@OpenCV_HAL_FOUND@
)
set
(
OpenCV_HAL_VERSION
@OpenCV_HAL_VERSION@
)
set
(
OpenCV_HAL_LIBRARIES
@OpenCV_HAL_LIBRARIES@
)
set
(
OpenCV_HAL_HEADERS
@OpenCV_HAL_HEADERS@
)
set
(
OpenCV_HAL_INCLUDE_DIRS
@OpenCV_HAL_INCLUDE_DIRS@
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment