skip to Main Content

Javascript – Getting a filtered list from float32array results

Using this piece of code: function displayPixelValue(event) { const filteredLayers = map.getAllLayers().filter(function (layer) { return layer.get('name'); }); for (let i=0; i<filteredLayers.length; i++) { let reliefPattern = "_mbpd_"; if (filteredLayers[i].get('name').match(reliefPattern)) { const reliefValue = filteredLayers[i].getData(event.pixel); console.log(reliefValue); } } } map.on(['pointermove'], displayPixelValue);…

VIEW QUESTION
Back To Top
Search