Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
html
/
MeteorologicalBureau
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
6803348d
authored
Feb 26, 2020
by
fengfan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
map
parent
f6a4dce2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
1 deletions
+27
-1
map/index-ff.html
+27
-1
map/index.html
+0
-0
No files found.
map/index-ff.html
View file @
6803348d
...
...
@@ -62,8 +62,32 @@
});
var
SatelliteDown
=
new
AMap
.
TileLayer
.
Satellite
({
rejectMapMask
:
true
,
// opacity:0.1,
zIndex
:
0
});
//定义中国东南西北端点
var
pNW
=
{
lat
:
59.1
,
lng
:
73.1
}
var
pNE
=
{
lat
:
59.1
,
lng
:
136.1
}
var
pSE
=
{
lat
:
3.1
,
lng
:
136.1
}
var
pSW
=
{
lat
:
3.1
,
lng
:
73.1
}
var
maskTileLayerBounds
=
new
AMap
.
Bounds
(
pSW
,
pNE
)
var
canvas
=
document
.
createElement
(
'canvas'
);
canvas
.
width
=
canvas
.
height
=
200
;
var
context
=
canvas
.
getContext
(
'2d'
)
context
.
fillStyle
=
'rgb(0,0,0)'
;
context
.
fillRect
(
0
,
0
,
200
,
200
);
var
CanvasLayer
=
new
AMap
.
CanvasLayer
({
rejectMapMask
:
true
,
opacity
:
0.9
,
zIndex
:
8
,
canvas
:
canvas
,
bounds
:
new
AMap
.
Bounds
(
[
pSW
.
lng
,
pSW
.
lat
],
[
pNE
.
lng
,
pNE
.
lat
]
),
zooms
:
[
3
,
18
],
});
// debugger
var
RoadNet
=
new
AMap
.
TileLayer
.
RoadNet
({
rejectMapMask
:
true
,
mapStyle
:
'amap://styles/'
+
styleId
...
...
@@ -90,7 +114,7 @@
result
.
districtList
[
0
].
center
.
lng
,
result
.
districtList
[
0
].
center
.
lat
],
//
mapStyle: 'amap://styles/' + styleId,
mapStyle
:
'amap://styles/'
+
styleId
,
disableSocket
:
true
,
viewMode
:
'3D'
,
showLabel
:
false
,
...
...
@@ -101,7 +125,9 @@
// layers: [road, ]//Satellite,
});
map
.
add
(
Satellite
);
map
.
add
(
CanvasLayer
);
map
.
add
(
SatelliteDown
);
map
.
getLayers
()[
0
].
setzIndex
(
1000
)
findsubarea
(
result
);
// map.getLayers()[0].setOpacity(0.5)
// var maskerIn = new AMap.Marker({
...
...
map/index.html
View file @
6803348d
This diff is collapsed.
Click to expand it.
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