M
M
Mikhail Smirnov2016-06-15 09:46:47
JavaScript
Mikhail Smirnov, 2016-06-15 09:46:47

How to get the coordinates of the scope?

How to find out the coordinates of the visible area when zooming the map or moving around it in order to load objects that fall into this area?

That is, 4 points of the map rectangle are needed.

Version 2.1.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
L
Lynn "Coffee Man", 2016-06-15
@fortoster83

The Maps API has very good documentation. Try to read.
https://tech.yandex.ru/maps/doc/jsapi/2.1/ref/ref...
https://tech.yandex.ru/maps/doc/jsapi/2.1/ref/ref...

N
Nicholas, 2016-06-15
@healqq

To get map coordinates, you should use the Map.getBounds method : https://tech.yandex.ru/maps/doc/jsapi/2.1/ref/refe...
If you do not have a lot of objects (it is possible to download the minimum information about all objects per request) map - maybe you should think about objectManager( dock ). There is clustering and a convenient event binding out of the box.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question