Answer the question
In order to leave comments, you need to log in
How to expand the panorama search radius - Yandex Maps API?
Hello! Tell me, is it possible to expand the panorama search area through the Yandex Maps api?
There is a call code by coordinates, if there is a panorama near this coordinate, then it is displayed, otherwise - an error. Apparently, panoramas are searched for within a radius of max. 50 meters.
For example, I have a marker on the Yandex map in the center of the park, the nearest distance to the road with a panorama is about 200 meters. The option with manually changing the coordinates is not suitable, since they are substituted via php from the database.
locateRequest.then(
function (panoramas) {
if (panoramas.length) {
// Создание на странице плеера панорам.
var player = new ymaps.panorama.Player('div_id', panoramas[0], {
// Опции панорамы.
// direction - направление взгляда.
direction: [0, -50]
});
} else {
console.log("В заданной точке нет панорам.");
}
}
);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question