1
1
import {
2
2
S1GRDEOCloudLayer ,
3
3
CRS_EPSG3857 ,
4
+ CRS_EPSG4326 ,
4
5
BBox ,
5
6
MimeTypes ,
6
7
ApiType ,
@@ -23,6 +24,7 @@ if (!process.env.EOC_S1GRDIW_LAYER_ID) {
23
24
const instanceId = process . env . EOC_INSTANCE_ID ;
24
25
const layerId = process . env . EOC_S1GRDIW_LAYER_ID ;
25
26
const bbox = new BBox ( CRS_EPSG3857 , 1487158.82 , 5322463.15 , 1565430.34 , 5400734.67 ) ;
27
+ const bbox4326 = new BBox ( CRS_EPSG4326 , 13.359375 , 43.0688878 , 14.0625 , 43.5803908 ) ;
26
28
27
29
export default {
28
30
title : 'Sentinel 1 GRD IW - EOCloud' ,
@@ -144,7 +146,7 @@ export const getMapWMSEvalscript = () => {
144
146
return wrapperEl ;
145
147
} ;
146
148
147
- export const findTiles = ( ) => {
149
+ export const findTilesEPSG3857 = ( ) => {
148
150
const layer = new S1GRDEOCloudLayer (
149
151
instanceId ,
150
152
layerId ,
@@ -159,7 +161,7 @@ export const findTiles = () => {
159
161
const containerEl = document . createElement ( 'pre' ) ;
160
162
161
163
const wrapperEl = document . createElement ( 'div' ) ;
162
- wrapperEl . innerHTML = "<h2>findTiles</h2>" ;
164
+ wrapperEl . innerHTML = "<h2>findTiles - BBox in EPSG:3857 </h2>" ;
163
165
wrapperEl . insertAdjacentElement ( "beforeend" , containerEl ) ;
164
166
165
167
const perform = async ( ) => {
@@ -178,6 +180,40 @@ export const findTiles = () => {
178
180
return wrapperEl ;
179
181
} ;
180
182
183
+ export const findTilesEPSG4326 = ( ) => {
184
+ const layer = new S1GRDEOCloudLayer (
185
+ instanceId ,
186
+ layerId ,
187
+ null ,
188
+ null ,
189
+ null ,
190
+ null ,
191
+ AcquisitionMode . IW ,
192
+ Polarization . DV ,
193
+ OrbitDirection . ASCENDING ,
194
+ ) ;
195
+ const containerEl = document . createElement ( 'pre' ) ;
196
+
197
+ const wrapperEl = document . createElement ( 'div' ) ;
198
+ wrapperEl . innerHTML = "<h2>findTiles - BBox in EPSG:4326</h2>" ;
199
+ wrapperEl . insertAdjacentElement ( "beforeend" , containerEl ) ;
200
+
201
+ const perform = async ( ) => {
202
+ const data = await layer . findTiles (
203
+ bbox4326 ,
204
+ new Date ( Date . UTC ( 2020 , 1 - 1 , 1 , 0 , 0 , 0 ) ) ,
205
+ new Date ( Date . UTC ( 2020 , 1 - 1 , 15 , 23 , 59 , 59 ) ) ,
206
+ 5 ,
207
+ null ,
208
+ OrbitDirection . ASCENDING ,
209
+ ) ;
210
+ renderTilesList ( containerEl , data . tiles ) ;
211
+ } ;
212
+ perform ( ) . then ( ( ) => { } ) ;
213
+
214
+ return wrapperEl ;
215
+ } ;
216
+
181
217
function renderTilesList ( containerEl , list ) {
182
218
list . forEach ( tile => {
183
219
const ul = document . createElement ( 'ul' ) ;
0 commit comments