     shadeData[offset + 3] &#x3D; elevationData[offset + 3];
    }
  }

  return {data: shadeData, width: width, height: height};
}

var elevation &#x3D; new ol.source.XYZ({
  url: &#x27;https://{a-d}.tiles.mapbox.com/v3/aj.sf-dem/{z}/{x}/{y}.png&#x27;,
  crossOrigin: &#x27;anonymous&#x27;,
  transition: 0
});

var raster &#x3D; new ol.source.Raster({
  sources: [elevation],
  operationType: &#x27;image&#x27;,
  operation: shade
});

var map &#x3D; new ol.Map({
  target: &#x27;map&#x27;,
  layers: [
    new