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
3bafe646
Commit
3bafe646
authored
Sep 01, 2014
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3170 from ElenaGvozdeva:ocl_fix
parents
3e574cd2
31ac73c3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
3 deletions
+21
-3
ocl.hpp
modules/core/include/opencv2/core/ocl.hpp
+1
-0
copy.cpp
modules/core/src/copy.cpp
+2
-2
ocl.cpp
modules/core/src/ocl.cpp
+17
-0
imgwarp.cpp
modules/imgproc/src/imgwarp.cpp
+1
-1
No files found.
modules/core/include/opencv2/core/ocl.hpp
View file @
3bafe646
...
...
@@ -596,6 +596,7 @@ protected:
CV_EXPORTS
const
char
*
convertTypeStr
(
int
sdepth
,
int
ddepth
,
int
cn
,
char
*
buf
);
CV_EXPORTS
const
char
*
typeToStr
(
int
t
);
CV_EXPORTS
const
char
*
memopTypeToStr
(
int
t
);
CV_EXPORTS
const
char
*
vecopTypeToStr
(
int
t
);
CV_EXPORTS
String
kernelToStr
(
InputArray
_kernel
,
int
ddepth
=
-
1
,
const
char
*
name
=
NULL
);
CV_EXPORTS
void
getPlatfomsInfo
(
std
::
vector
<
PlatformInfo
>&
platform_info
);
...
...
modules/core/src/copy.cpp
View file @
3bafe646
...
...
@@ -640,8 +640,8 @@ static bool ocl_flip(InputArray _src, OutputArray _dst, int flipCode )
ocl
::
Kernel
k
(
kernelName
,
ocl
::
core
::
flip_oclsrc
,
format
(
"-D T=%s -D T1=%s -D cn=%d -D PIX_PER_WI_Y=%d -D kercn=%d"
,
kercn
!=
cn
?
ocl
::
typeToStr
(
CV_MAKE_TYPE
(
depth
,
kercn
))
:
ocl
::
mem
opTypeToStr
(
CV_MAKE_TYPE
(
depth
,
kercn
)),
kercn
!=
cn
?
ocl
::
typeToStr
(
depth
)
:
ocl
::
mem
opTypeToStr
(
depth
),
cn
,
pxPerWIy
,
kercn
));
kercn
!=
cn
?
ocl
::
typeToStr
(
CV_MAKE_TYPE
(
depth
,
kercn
))
:
ocl
::
vec
opTypeToStr
(
CV_MAKE_TYPE
(
depth
,
kercn
)),
kercn
!=
cn
?
ocl
::
typeToStr
(
depth
)
:
ocl
::
vec
opTypeToStr
(
depth
),
cn
,
pxPerWIy
,
kercn
));
if
(
k
.
empty
())
return
false
;
...
...
modules/core/src/ocl.cpp
View file @
3bafe646
...
...
@@ -4361,6 +4361,23 @@ const char* typeToStr(int type)
}
const
char
*
memopTypeToStr
(
int
type
)
{
static
const
char
*
tab
[]
=
{
"uchar"
,
"uchar2"
,
"uchar3"
,
"uchar4"
,
0
,
0
,
0
,
"uchar8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"uchar16"
,
"char"
,
"char2"
,
"char3"
,
"char4"
,
0
,
0
,
0
,
"char8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"char16"
,
"ushort"
,
"ushort2"
,
"ushort3"
,
"ushort4"
,
0
,
0
,
0
,
"ushort8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"ushort16"
,
"short"
,
"short2"
,
"short3"
,
"short4"
,
0
,
0
,
0
,
"short8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"short16"
,
"int"
,
"int2"
,
"int3"
,
"int4"
,
0
,
0
,
0
,
"int8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"int16"
,
"int"
,
"int2"
,
"int3"
,
"int4"
,
0
,
0
,
0
,
"int8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"int16"
,
"ulong"
,
"ulong2"
,
"ulong3"
,
"ulong4"
,
0
,
0
,
0
,
"ulong8"
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
"ulong16"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
,
"?"
};
int
cn
=
CV_MAT_CN
(
type
),
depth
=
CV_MAT_DEPTH
(
type
);
return
cn
>
16
?
"?"
:
tab
[
depth
*
16
+
cn
-
1
];
}
const
char
*
vecopTypeToStr
(
int
type
)
{
static
const
char
*
tab
[]
=
{
...
...
modules/imgproc/src/imgwarp.cpp
View file @
3bafe646
...
...
@@ -2180,7 +2180,7 @@ static bool ocl_resize( InputArray _src, OutputArray _dst, Size dsize,
{
k
.
create
(
"resizeNN"
,
ocl
::
imgproc
::
resize_oclsrc
,
format
(
"-D INTER_NEAREST -D T=%s -D T1=%s -D cn=%d"
,
ocl
::
memopTypeToStr
(
type
),
ocl
::
mem
opTypeToStr
(
depth
),
cn
));
ocl
::
vecopTypeToStr
(
type
),
ocl
::
vec
opTypeToStr
(
depth
),
cn
));
if
(
k
.
empty
())
return
false
;
...
...
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