mapbox / mapnik-vector-tile

Mapnik implemention of Mapbox Vector Tile specification
BSD 3-Clause "New" or "Revised" License
553 stars 117 forks source link

Missing demultiplication in visitor_raster_processor #170

Closed springmeyer closed 8 years ago

springmeyer commented 8 years ago

We work in premultiplied pixels when scaling images into vector tiles, but never demultiply (https://github.com/mapbox/mapnik-vector-tile/blob/5797fca49d0c79ff3cd51498ce100820f6a24b63/src/vector_tile_processor.ipp#L147). This means that colors will be incorrect. This may have been forgotten because we planned to switch image encoders to handle premultiplied status automatically, but never got to it https://github.com/mapnik/mapnik/issues/2923

springmeyer commented 8 years ago

https://github.com/mapnik/node-mapnik/commit/b7f3b9b72707c058a3bcca591e260d5a8d86dfac covers this a bit. Next step is to port a testcase to mapnik-vt.