Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
N
node-bigstream
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bs
node-bigstream
Commits
3a93de96
Commit
3a93de96
authored
Oct 25, 2019
by
Kamron Aroonrua
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rainradar fixed
parent
2427e7d9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
digitizer.js
plugins/dt/igrid/dt-radar-digitizer/digitizer.js
+5
-5
No files found.
plugins/dt/igrid/dt-radar-digitizer/digitizer.js
View file @
3a93de96
...
...
@@ -6,9 +6,9 @@ function avg_point(prm,cb)
var
bg
=
prm
.
bg
;
var
fg
=
prm
.
fg
;
var
dpoint
=
prm
.
point
;
var
radius
=
prm
.
radius
||
10
;
var
bg_threshold
=
prm
.
bg_threshold
||
20
;
var
mapping_threshold
=
prm
.
mapping_threshold
||
128
;
var
radius
=
Number
(
prm
.
radius
)
||
10
;
var
bg_threshold
=
Number
(
prm
.
bg_threshold
)
||
20
;
var
mapping_threshold
=
Number
(
prm
.
mapping_threshold
)
||
128
;
var
table
=
prm
.
table
||
[];
async
.
waterfall
([
...
...
@@ -128,7 +128,7 @@ function mapping(map_table,color)
if
(
itm
.
color
&&
itm
.
value
){
var
d
=
distance
(
itm
.
color
,
color
)
if
(
d
<
out
.
distance
){
out
.
value
=
itm
.
value
;
out
.
value
=
Number
(
itm
.
value
)
;
out
.
distance
=
d
;
}
}
...
...
@@ -162,7 +162,7 @@ function weight(x, y, cx, cy,radius) {
function
distance
(
a
,
b
)
{
sum
=
0
;
sum
=
Math
.
pow
(
a
[
0
]
-
b
[
0
],
2
)
+
Math
.
pow
(
a
[
1
]
-
b
[
1
],
2
)
+
Math
.
pow
(
a
[
2
]
-
b
[
2
]
,
2
)
sum
=
Math
.
pow
(
Number
(
a
[
0
])
-
Number
(
b
[
0
]),
2
)
+
Math
.
pow
(
Number
(
a
[
1
])
-
Number
(
b
[
1
]),
2
)
+
Math
.
pow
(
Number
(
a
[
2
])
-
Number
(
b
[
2
])
,
2
)
return
Math
.
sqrt
(
sum
)
}
...
...
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