Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blurriness in rendering raster tiles #7771

Closed
aliir74 opened this issue Jan 14, 2019 · 10 comments
Closed

Blurriness in rendering raster tiles #7771

aliir74 opened this issue Jan 14, 2019 · 10 comments

Comments

@aliir74
Copy link

aliir74 commented Jan 14, 2019

mapbox-gl-js version: 0.52.0

Question

Hi all, I use mapbox gl js for rendering raster tiles but tiles in a browser after rendering have blurriness but main tile images are clear

I added tilesize to my style but my problem still exists.

"sources": {
    "high_update": {
        "type": "raster",
        "tileSize": 256,
        "tiles": [
            "http://192.168.101.16:8000/images/{z}/{x}/{y}.png"
        ],
        "minzoom": 3,
        "maxzoom": 16
    }
},
"layers": [
    {
        "id": "simple-tiles",
        "type": "raster",
        "source": "high_update",
        "minzoom": 0,
        "maxzoom": 22
    }
]

my tile image:

my rendered map:

Sorry for asking in github instead of stackoverflow. The stackoverflow show me this error You need at least 10 reputation to post images.

Links to related documentation

raster sources

@peterqliu
Copy link
Contributor

@aliir74 two things come to mind:

@aliir74
Copy link
Author

aliir74 commented Jan 15, 2019

Hi @peterqliu

  • Is there any way to mapbox-gl-js load tiles earlier than we have now? Now mapbox-gl-js render z4 tiles from z3.5 to z4.5. Could we set is to z3 to z4 for less blurriness
  • In non-fractional zoom level also I have some blurriness, Disabling map rotation can help me for solving this problem?

Thanks for your fast reply :)

@aliir74
Copy link
Author

aliir74 commented Jan 15, 2019

I find my problem is in mobile view mode. In a browser with a wide view didn't any blurry tile. but in mobile view everything gets blurry.

Wide view in Chrome:

Mobile view in Chrome:

In mobile browser:

@peterqliu
Copy link
Contributor

@aliir74 not sure what you mean by wide vs mobile view, but if it has to do with different displays, it might be because you're forcing tileSize: 256 when the default is 512. This will be blurry on retina-like screens

@aliir74
Copy link
Author

aliir74 commented Jan 16, 2019

@peterqliu I mean when you see map on mobile things gets blurry but in desktop everything is ok.

I'm trying to generate rasters in 512x512 size to see the result.

@aliir74
Copy link
Author

aliir74 commented Jan 16, 2019

The problem didn't solve by change tilesize to 512x512

@aliir74
Copy link
Author

aliir74 commented Jan 20, 2019

@peterqliu Do you have any idea why this blurry thing happen in mobile size?

@asheemmamoowala
Copy link
Contributor

@aliir74 Can you test the v0.53.0 beta to see if it resolves the bluriness ?

@aliir74
Copy link
Author

aliir74 commented Feb 3, 2019

@asheemmamoowala I increase the ratio in my picture and blurriness is gone. seems mobile screens have more resolution display.

@aliir74 aliir74 closed this as completed Feb 3, 2019
@bart-1990
Copy link

bart-1990 commented Apr 19, 2019

I'm also experiencing bluriness in tiles, especially at the .5 zoom level.

The weird thing is that I don't experience this using mapbox styles, so I was wondering what the tile server might be doing different than the one I'm fetching my tiles from.

First image, zoom level = 1.5
Second image, zoom level = 1.5019

1-5

1-5019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants