summaryrefslogtreecommitdiff
path: root/platform/default/headless_view.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/default/headless_view.cpp')
-rw-r--r--platform/default/headless_view.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/default/headless_view.cpp b/platform/default/headless_view.cpp
index 0587f5f380..fa83f65967 100644
--- a/platform/default/headless_view.cpp
+++ b/platform/default/headless_view.cpp
@@ -179,7 +179,7 @@ std::unique_ptr<StillImage> HeadlessView::readStillImage() {
auto image = std::make_unique<StillImage>();
image->width = w;
image->height = h;
- image->pixels = std::make_unique<uint32_t[]>(w * h);
+ image->pixels = std::make_unique<uint8_t[]>(w * h * 4);
MBGL_CHECK_ERROR(glReadPixels(0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, image->pixels.get()));