Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

C++ LoadBitmap


  • Please log in to reply
3 replies to this topic

#1 chx101

chx101

  • Members
  • 32 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:uSa
  • Local time:02:34 AM

Posted 30 August 2009 - 04:45 PM

Hie ,
I need some help on loading a bitmap as a Splash screen in C++. I am using wXDev-C++ v 7.

When i use LoadBitmap it works fine but doesn't load.
Any help or suggestion will be greatly appreciated.
Thanks. :thumbsup:

BC AdBot (Login to Remove)

 


#2 Romeo29

Romeo29

    Learning To Bleep


  • Members
  • 3,194 posts
  • OFFLINE
  •  
  • Gender:Not Telling
  • Location:127.0.0.1
  • Local time:02:34 AM

Posted 31 August 2009 - 01:21 PM

LoadBitmap just loads a bitmap resource into memory and return the handle.
If you want to load an image from a file, use LoadImage() instead.

To show splash screen, you need a window (a dialog window is good) on which you would display that image.
Then do BitBlt() to paint the loaded bitmap onto that window. The prcoess requires getting DC and releasng it.
You need a

For more information see MSDN : http://msdn.microsoft.com/en-us/library/dd...28VS.85%29.aspx
Also this article is good : http://www.winprog.org/tutorial/bitmaps.html

#3 chx101

chx101
  • Topic Starter

  • Members
  • 32 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:uSa
  • Local time:02:34 AM

Posted 01 September 2009 - 11:14 AM

So if i want to display a Splash screen i just set the window with no caption right ?
BTW thanks for those links, they are good.

#4 Romeo29

Romeo29

    Learning To Bleep


  • Members
  • 3,194 posts
  • OFFLINE
  •  
  • Gender:Not Telling
  • Location:127.0.0.1
  • Local time:02:34 AM

Posted 01 September 2009 - 02:40 PM

Yes, create a window with no caption, no border etc. Do BitBlt(). Then use SetTimer() counter or just use SleepEx() to set the number of seconds the splash screen would be displayed.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users