diff --git a/source/Irrlicht/CImage.cpp b/source/Irrlicht/CImage.cpp index 18fc92bd..fcbeacf3 100644 --- a/source/Irrlicht/CImage.cpp +++ b/source/Irrlicht/CImage.cpp @@ -298,8 +298,6 @@ void CImage::copyToScalingBoxFilter(IImage* target, s32 bias, bool blend) const f32 sourceXStep = (f32) Size.Width / (f32) destSize.Width; const f32 sourceYStep = (f32) Size.Height / (f32) destSize.Height; - target->getData(); - s32 fx = core::ceil32( sourceXStep ); s32 fy = core::ceil32( sourceYStep ); f32 sx; diff --git a/source/Irrlicht/COpenGLDriver.cpp b/source/Irrlicht/COpenGLDriver.cpp index 511c88cb..40f68b46 100644 --- a/source/Irrlicht/COpenGLDriver.cpp +++ b/source/Irrlicht/COpenGLDriver.cpp @@ -3794,22 +3794,7 @@ IImage* COpenGLDriver::createScreenShot(video::ECOLOR_FORMAT format, video::E_RE pixels = static_cast(newImage->getData()); if (pixels) { - GLenum tgt=GL_FRONT; - switch (target) - { - case video::ERT_FRAME_BUFFER: - break; - case video::ERT_STEREO_LEFT_BUFFER: - tgt=GL_FRONT_LEFT; - break; - case video::ERT_STEREO_RIGHT_BUFFER: - tgt=GL_FRONT_RIGHT; - break; - default: - tgt=GL_AUX0+(target-video::ERT_AUX_BUFFER0); - break; - } - glReadBuffer(tgt); + glReadBuffer(GL_FRONT); glReadPixels(0, 0, ScreenSize.Width, ScreenSize.Height, fmt, type, pixels); testGLError(__LINE__); glReadBuffer(GL_BACK);