Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
ReelCounter
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit c3ea698d
由
SK
编写于
2019-04-23 09:07:25 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
只获取一个圆BUG
1 个父辈
ca84d094
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
3 行增加
和
3 行删除
AccImage/ImageUtil.cs
AccImage/SplitItem.cs
AccImage/ImageUtil.cs
查看文件 @
c3ea698
...
@@ -434,9 +434,9 @@ namespace Acc.Img
...
@@ -434,9 +434,9 @@ namespace Acc.Img
int
blobCount
=
0
;
int
blobCount
=
0
;
CvBlobs
resultBlobs
=
new
CvBlobs
();
CvBlobs
resultBlobs
=
new
CvBlobs
();
int
threshIndex
=
(
startIndex
+
endIndex
)
/
2
;
int
threshIndex
=
(
startIndex
+
endIndex
)
/
2
;
Console
.
WriteLine
(
"Avg Thresh: "
+
threshIndex
+
" blobArea ="
+
blobArea
);
double
theArea
=
blobArea
*
0.8
;
double
theArea
=
blobArea
*
0.8
;
if
(
theArea
<
1
)
theArea
=
1
;
if
(
theArea
<
1
)
theArea
=
1
;
Console
.
WriteLine
(
"Avg Thresh: "
+
threshIndex
);
for
(
int
index
=
startIndex
;
index
<
endIndex
;
index
++)
for
(
int
index
=
startIndex
;
index
<
endIndex
;
index
++)
{
{
Mat
tempThreshMat
=
new
Mat
();
Mat
tempThreshMat
=
new
Mat
();
...
@@ -750,7 +750,7 @@ namespace Acc.Img
...
@@ -750,7 +750,7 @@ namespace Acc.Img
{
{
item
.
calOneItem
(
oneBlobRadius
);
item
.
calOneItem
(
oneBlobRadius
);
}
}
if
(
item
.
isEnd
||
hasPixToHandle
)
if
(
item
.
isEnd
||
!
hasPixToHandle
)
{
{
break
;
break
;
}
}
...
...
AccImage/SplitItem.cs
查看文件 @
c3ea698
...
@@ -31,7 +31,7 @@ namespace AccImage
...
@@ -31,7 +31,7 @@ namespace AccImage
{
{
//与平均半径差值在10%以内,认为OK
//与平均半径差值在10%以内,认为OK
double
diff
=
avgRadius
-
currentMaxRadius
;
double
diff
=
avgRadius
-
currentMaxRadius
;
if
(
diff
/
avgRadius
<=
0.
5
)
if
(
diff
/
avgRadius
<=
0.
4
)
{
{
isValid
=
true
;
isValid
=
true
;
}
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论