Solved

Saving of 16/24-bit bitmap

Posted on 1998-09-12
1
467 Views
Last Modified: 2013-11-20
I do not get managed to save a 16/24-bit bitmap. There are no problems with 8-bit images but despite of all documentation I have read I was not able to save a 16/24-bit bitmap. I already know the Visual C++ article concerning this topic but somehow it does not work. Can anyone simply send a working sample of how to save a 16 or 24-bit bitmap ? I would be very thankful since I have tried to solve this problem for almost two weeks now.
0
Comment
Question by:ClausLeonhardt
1 Comment
 
LVL 3

Accepted Solution

by:
brosenb0 earned 70 total points
Comment Utility
What you need to do is create a Device Independent Bitmap (DIB) from your Bitmap and then save this to a file.  This way custom palette information is saved with the bitmap image.  Examples of how to create and save a DIB may be found at www.codeguru.com/bitmap.

In particular look at the the article by Jorge Lodos about the Encapsulated DIB API.  This class contains all the code necessary to load and save DIBS, create the DIB's palette and paint the DIB.  It can easily be extended to allow the DIB to be loaded from a resource contained within the application.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
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.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

743 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now