[core] Fix image type of Map::renderStill
It's a premultiplied image. This implies that we were misusing encodePNG in most cases, as we were passing premultiplied pixels which were then interpreted as unmultiplied. I changed encodePNG to accept premultipled pixels, and unpremultiply in the implementations.
This commit is contained in:
@@ -45,7 +45,7 @@ TEST(API, RenderWithoutStyle) {
|
||||
Map map(view, fileSource, MapMode::Still);
|
||||
|
||||
std::promise<std::exception_ptr> promise;
|
||||
map.renderStill([&promise](std::exception_ptr error, UnassociatedImage&&) {
|
||||
map.renderStill([&promise](std::exception_ptr error, PremultipliedImage&&) {
|
||||
promise.set_value(error);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user