Using GeoServer, I uploaded a netCDF file, got the temperature variable and mounted a color scale through the SLD.

This shows me a layer with the style I created.

That done, I'm presenting this layer in OpenLayers 3, but when applying a 'zoom in' everything is pixelated, without quality.

How can I fix the problem?

I noticed that in the GeoServer there is the bicubic interpolation option, but in doing so I can not pull the image on the map.

Below the excerpt of the relevant code:

var padrao = new ol.layer.Tile({
    source: new ol.source.OSM(),
    visible: true,
    name: 'padrao'

var temperatura = new ol.layer.Tile({
  extent: ext,
    visible: true,
  source: new ol.source.TileWMS({
    opacity: 0.5,
                url: "http://docker1.es.met.com.br/geoserver/wms",
                params: {'LAYERS' : 'somar:Temperatura',
                                 'TILED': true,
                serverType: 'geoserver',
                crossOrigin: 'canvas',
                projection: 'EPSG:4326',

        var view = new ol.View({
            center: [-6217890.205764902, -1710870.6048274133],
            zoom: 4,
            maxZoom: 7,
            minZoom: 4,
            extent: ext

//Instancia o mapa com as configurações
var map = new ol.Map({
    target: 'mapa',
    controls: ol.control.defaults().extend([
        new ol.control.ScaleLine(),
        new ol.control.ZoomSlider()
    renderer: 'canvas',
    layers: [padrao,temperatura],
    view: view,

I'm new with GeoServer and OpenLayers 3. Any direction of how to solve the problem will be of great help.


Are you sure GeoServer it's not simply showing the native raster data, and thus, generating big square blocks per pixel once you zoom in?

You can go into the WMS service panel and set the interpolation to "Bilinear", this will interpolate the data and give the illusion of a higher resolution. I would not recommend doing that with scientific data as it gives the false impression of a data quality that's not really there, but many like it.

  • exactly what I require, I'm actually using the bicubic interpolation, but I can not include that in the openlayers map, it's always behind the 'grid'. I showed it to the client and this interpolation minded. But how to include it on the map? calling the normal inclusion of wms it does not come in that format. – Hugo Ferreira Sep 26 '17 at 12:45
  • Sorry Hugo, I don't understand what you mean. You cannot set bicubic to be the default interpolation? Or the image that you get back is corrupted somehow? If you want to control interpolation within the request instead of server side, you can add these vendor parameters to your GetMap: docs.geoserver.org/latest/en/user/services/wms/… – Andrea Aime Sep 28 '17 at 8:57
  • Exactly this, I can configure the interpolation in Geoserver and view in the tool, but I can not consume it interpolated in Openlayer 3. Forgive my lack of experience. Can you give me a practical example of how to view this Geoserver bicubic interpolated layer in Openlayer 3. Thank you! – Hugo Ferreira Sep 29 '17 at 14:58
  • Sorry, I don't do client side :-) (as in, I work only on server side so I cannot whip up and example in a minute) – Andrea Aime Sep 30 '17 at 8:16
  • Anyway thank you! I have been with this problem for some time. I know how to configure the interpolation of the server side layer (Geoserver), but I do not know how to present this client side interpolation (Openlayer 3). Do you have any suggestions, forum to indicate? – Hugo Ferreira Oct 4 '17 at 14:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.