472,794 Members | 3,644 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,794 software developers and data experts.

Editing a Bitmap, while keeping it's color-depth & colors ?

Hello All,

I would like to be able to edit a .BMP-file, while retaining it's
color-depth & colors.

Actually, I want to cut small pieces outof one .BMP, and store it into
another one. Jup, sort of a tile-editor :-)

Does anyone have a small sample (or pointer to one) of howto :
1) Load & save a device-independant bitmap (DIB).
2) Create a Device-independant bitmap that has the color-depth/colors of
another DIB
3) BitBlit from one to the other (although I think I allready have an idea
how to do this :-)

I've allready looked in my snippets-bag & used google, but I can't say I
grasp what has to be done ... :-\

Rudy Wieser

Jul 17 '05 #1
0 1583

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: Stimp | last post by:
Hi, I output a GIF file, loaded into a Bitmap, as follows: Dim imgMap As New Bitmap(System.Drawing.Image.FromFile(Server.MapPath("original.gif"))) Response.ContentType = "image/gif" ...
by: Steve | last post by:
I haven't used authentication/authorization in awhile. I'm having a hard time deciding how to display the edit column in a datagrid ONLY if a user with proper credentials is logged in. In other...
by: Crirus | last post by:
Strange behaviour: I havea bitmap that I draw and add to an array of bitmaps... Do I have to create a bitmap using New every time? I tried to draw the bitmap in a for loop alike this: Dim...
by: Lance | last post by:
I need to create a Drawing.Bitmap from an array of integer values. My current technique creates a bitmap that eventually becomes corrupt (i.e., the bitmap's pixels change to a different color...
by: Dennis | last post by:
I am trying to implement drawing on a bitmap and using bitblt to transfer it to the control graphics object in the paint event. It seems to draw on the bitmap ok but doesn't get transferred to the...
by: Sebastor | last post by:
Hi I create bitmap array : Graphics::TBitmap ***bitmap; bitmap = new Graphics::TBitmap**; for (int s=0;s<x;s++) { bitmap = new Graphics::TBitmap*;
by: Yoavo | last post by:
Hi, I am writing a COM class in c# which needs to implement an interface which one of its methods declared in the following way: public stdole.IPicture GetBitmap() { } I have a bitmap...
by: benfly08 | last post by:
Hi, guys. I have a program to draw bar/pie chart based on the data i hard coded in it. However, my image comes with "BLACK" background color. I don't know how to fix this. The code snippet is...
by: dino d. | last post by:
hi everyone- my subject pretty much says it all- is there a secure way to do this? the non-secure ways are, as i understand it, to populate a listbox with indices as names, or maybe use a hidden...
by: Nathan Sokalski | last post by:
I have created declared a Bitmap using the following statement: Dim bmp As New Bitmap(100, 100, PixelFormat.Format8bppIndexed) Because the SetPixel() method is disabled and a Graphics object...
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
by: Taofi | last post by:
I try to insert a new record but the error message says the number of query names and destination fields are not the same This are my field names ID, Budgeted, Actual, Status and Differences ...
by: DJRhino1175 | last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this - If...
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
by: DJRhino | last post by:
Private Sub CboDrawingID_BeforeUpdate(Cancel As Integer) If = 310029923 Or 310030138 Or 310030152 Or 310030346 Or 310030348 Or _ 310030356 Or 310030359 Or 310030362 Or...
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
by: Mushico | last post by:
How to calculate date of retirement from date of birth

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.