Solved

loading a bitmap in OWL

Posted on 2000-04-28
1
178 Views
Last Modified: 2013-12-26
How do you go about loading a bitmap located on the hard drive, and displaying it on the screen?
0
Comment
Question by:onnix
1 Comment
 
LVL 14

Accepted Solution

by:
AlexVirochovsky earned 15 total points
ID: 2764226
..
#include <owl/dibitmap.h>
...
void YouClass::Paint(TDC& dc, bool, TRect& rect)
{
  TDiBitmap *dib = new TDiBitmap("mybitmap.bmp");
  TMemoryDC memoryDC(dc);  
  memoryDC.SelectObject(*dib);
  dc.BitBlt(rect, memoryDC, TPoint(0,0));
  delete dib;
}

I hope, it helps. Alex

BTW: 15PTS???
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
css help 3 135
Specific format 21 207
Question on web subscription for apps 3 114
Animated .jpg? 13 97
Most of the sites are being standardized with W3C Web Standards. W3C provides lot of web standard services to the web. They have the web specification, process and documentation for all the web standards. You can apply HTML, CSS and Accessibility st…
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

861 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