From e2f53bb71a77c1db3cb2aac0bc51bc51db7ae1bf Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Wed, 13 Aug 2014 17:56:47 +0000 Subject: [PATCH] image: fix bug introduced in Image::Lock2D(). --- src/image/image.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/image/image.cpp b/src/image/image.cpp index 0a97e91b..6350dc9e 100644 --- a/src/image/image.cpp +++ b/src/image/image.cpp @@ -199,6 +199,8 @@ template typename PixelType::type *Image::Lock() /* The Lock2D() method */ void *Image::Lock2DHelper(PixelFormat T) { + SetFormat(T); + return m_data->m_pixels[(int)T]->Data2D(); }