Solved

Resize bitmap on the screen

Posted on 2001-08-07
4
264 Views
Last Modified: 2013-11-20
I need to display the bitmap (or whatever but I think bmp is easiest) in the window and resize it (not cut edges but resize whole image) to fit window size. I don't want to use graphic libaries I think there must be somewhere support for this either in MFC or Platform SDK. Class name, method name would be enough.

Thank you.
0
Comment
Question by:Pegasi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 1

Author Comment

by:Pegasi
ID: 6362460
Just read what I wrote :) Clarification: I don't need whole window resizing thing. Just bitmap itself.
0
 
LVL 5

Expert Comment

by:FengYuan
ID: 6362686
Use either StretchBlt or StretchDIBits. For example,

StretchBlt(x, y, width*scale, height*scale,
           hSrcDC, width, height, SRCCOPY);
0
 
LVL 5

Accepted Solution

by:
FengYuan earned 100 total points
ID: 6362688
StretchBlt(x, y, width*scale, height*scale,
          hSrcDC, 0, 0, width, height, SRCCOPY);

www.fengyuan.com
0
 
LVL 1

Author Comment

by:Pegasi
ID: 6362702
Thank you, looks right what I need :)
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question