Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
a7660331a
tesseract
提交
1cf098dc
T
tesseract
项目概览
a7660331a
/
tesseract
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
tesseract
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
1cf098dc
编写于
6月 03, 2017
作者:
S
Stefan Weil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
opencl: Remove unused code
Signed-off-by:
N
Stefan Weil
<
sw@weilnetz.de
>
上级
34bdf997
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
0 addition
and
46 deletion
+0
-46
opencl/openclwrapper.cpp
opencl/openclwrapper.cpp
+0
-46
未找到文件。
opencl/openclwrapper.cpp
浏览文件 @
1cf098dc
...
...
@@ -58,27 +58,6 @@ static const l_uint32 rmask32[] = {
0x01ffffff
,
0x03ffffff
,
0x07ffffff
,
0x0fffffff
,
0x1fffffff
,
0x3fffffff
,
0x7fffffff
,
0xffffffff
};
struct
tiff_transform
{
int
vflip
;
/* if non-zero, image needs a vertical fip */
int
hflip
;
/* if non-zero, image needs a horizontal flip */
int
rotate
;
/* -1 -> counterclockwise 90-degree rotation,
0 -> no rotation
1 -> clockwise 90-degree rotation */
};
static
struct
tiff_transform
tiff_orientation_transforms
[]
=
{
{
0
,
0
,
0
},
{
0
,
1
,
0
},
{
1
,
1
,
0
},
{
1
,
0
,
0
},
{
0
,
1
,
-
1
},
{
0
,
0
,
1
},
{
0
,
1
,
1
},
{
0
,
0
,
-
1
}
};
static
const
l_int32
MAX_PAGES_IN_TIFF_FILE
=
3000
;
static
cl_mem
pixsCLBuffer
,
pixdCLBuffer
,
pixdCLIntermediate
;
//Morph operations buffers
static
cl_mem
pixThBuffer
;
//output from thresholdtopix calculation
static
cl_int
clStatus
;
...
...
@@ -727,31 +706,6 @@ Pix *mapOutputCLBuffer(KernelEnv rEnv, cl_mem clbuffer, Pix *pixd, Pix *pixs,
return
pixd
;
}
static
cl_mem
allocateIntBuffer
(
KernelEnv
rEnv
,
const
l_uint32
*
_pValues
,
size_t
nElements
,
cl_int
*
pStatus
,
bool
sync
=
false
)
{
cl_mem
xValues
=
clCreateBuffer
(
rEnv
.
mpkContext
,
(
cl_mem_flags
)(
CL_MEM_READ_WRITE
),
nElements
*
sizeof
(
l_int32
),
nullptr
,
pStatus
);
if
(
_pValues
!=
nullptr
)
{
l_int32
*
pValues
=
(
l_int32
*
)
clEnqueueMapBuffer
(
rEnv
.
mpkCmdQueue
,
xValues
,
CL_TRUE
,
CL_MAP_WRITE
,
0
,
nElements
*
sizeof
(
l_int32
),
0
,
nullptr
,
nullptr
,
nullptr
);
memcpy
(
pValues
,
_pValues
,
nElements
*
sizeof
(
l_int32
));
clEnqueueUnmapMemObject
(
rEnv
.
mpkCmdQueue
,
xValues
,
pValues
,
0
,
nullptr
,
nullptr
);
if
(
sync
)
clFinish
(
rEnv
.
mpkCmdQueue
);
}
return
xValues
;
}
void
OpenclDevice
::
releaseMorphCLBuffers
()
{
if
(
pixdCLIntermediate
!=
nullptr
)
clReleaseMemObject
(
pixdCLIntermediate
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录