How to draw quality images in C++
In my C++ to C# test post I mention that the test is not fair yet because the C# app draws much better images than the C++ app.
Here is the code that does the drawing:
Code:
HBITMAP hOldMemBmp= (HBITMAP)::SelectObject(imageDC, hBmp);
a::hOldBmp= (HBITMAP)::SelectObject(a::hdcMem, hMemBmp);
::StretchBlt(a::hdcMem, 0, 0, wndRect.right-wndRect.left,
wndRect.bottom-wndRect.top, imageDC, 0, 0, BmpW, BmpH, SRCCOPY);
::BitBlt(a::hdcMem, drawLocation->left, drawLocation->top, drawLocation->right - drawLocation->left,
drawLocation->bottom - drawLocation->top, imageDC, 0, 0, SRCCOPY);
::BitBlt(hDC, invalLocation->left, invalLocation->top,
invalLocation->right-invalLocation->left,
invalLocation->bottom-invalLocation->top, a::hdcMem, invalLocation->left, invalLocation->top, SRCCOPY);
I read about using SetStretchMode(HALFTONE); but it doesn't work on win98.
How would I draw/stretch an image as nice as C# does another way?