I'm trying to implement my map using OL-Cesium / CesiumJS.
var layer2 = new ol.layer.Tile({
source: new ol.source.TileWMS({
url: 'https://demo.boundlessgeo.com/geoserver/wms',
params: {
'LAYERS': 'opengeo:countries'
}
})
});
var map = new ol.Map({
layers: [
layer2
],
target: 'world-map',
view: new ol.View({
center: [-99.816397,43.2843246],
zoom: 4,
projection: 'EPSG:4326'
})
});
var ol3d = new olcs.OLCesium({map: map});
var scene = ol3d.getCesiumScene();
ol3d.setEnabled(true);
This is working well and I can see my map as a globe. But when I change the layer to my local OpenStreetMap Geoserver ...
var osm = new ol.layer.Tile({
source: new ol.source.TileWMS({
url: 'http://my.local.osm/geoserver/wms',
params: {
'LAYERS': 'osm:worldlayer',
},
})
});
... I can see only a white globe. Inspecting the "network traffic" in my browser I can see all tiles are comming fine.
This is one of the tile URL in my local geosever (from the browser traffic inspector) :
http://my.local.osm/geoserver/osmope/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&FORMAT=image%2Fpng&TRANSPARENT=true&LAYERS=osm%3Aworldlayer&WIDTH=256&HEIGHT=256&CRS=EPSG%3A4326&STYLES=&BBOX=39.375%2C-123.75%2C45%2C-118.125
and this is one of the tiles URL from working Boundless demo geoserver
https://demo.boundlessgeo.com/geoserver/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&FORMAT=image%2Fpng&TRANSPARENT=true&LAYERS=opengeo%3Acountries&WIDTH=256&HEIGHT=256&CRS=EPSG%3A4326&STYLES=&BBOX=22.5%2C-135%2C45%2C-112.5
Both cases I can see the image thumbnail in the browser network inspector and the HTTP result is 200. The error (is not a CORS error):
An error occurred in "mf": Failed to obtain image tile X: 4 Y: 2 Level: 3. Cesium.js:459:3692
I'm using OL-Cesium v1.37
from GitHub
There is no proxy between me and my OSM geoserver. There is a proxy between me and Internet.
Cesium.js at 459
but the minified code is a nightmare to follow.