943,548 Members | Top Members by Rank

Ad:
  • C# Discussion Thread
  • Unsolved
  • Views: 7548
  • C# RSS
Apr 7th, 2006
0

32 bit depth image

Expand Post »
hi
i finished writing c# algorithm that is applied on a '24 bit depth' bitmap image that i called from file, and it was success; but when i apply the algorithm on a 32 bit depth image a break while running occur which is : " Value does not fall within the expected range".

what i have to do in order to apply my code on this type of image "32bit".
i think i have to do something after the 'image.fromfile', to make it acceptable by the rest of the code.
plz reply me your suggestion!
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
manar is offline Offline
14 posts
since Dec 2005
Apr 7th, 2006
0

Re: 32 bit depth image

note:
when i add the bold statement, the result shown is a black image!, what i have to do??

Quote ...
private void button2_Click(object sender, System.EventArgs e)
{

Image b = Image.FromFile(@"C:\project\test1.bmp" );

Bitmap source =(Bitmap)b;
source = new Bitmap(320, 240, System.Drawing.Imaging.PixelFormat.Format24bppRgb); Gray(source);
SobelEdgeDetector s= new SobelEdgeDetector();
Bitmap k = s.Apply(source);
g.DrawImage(k,5 ,5 );
k.Save(@"C:\project\rr.bmp");
}
Reputation Points: 10
Solved Threads: 0
Newbie Poster
manar is offline Offline
14 posts
since Dec 2005
Apr 8th, 2006
0

Re: 32 bit depth image

re hi
any suggestion to convert the bitmap from 32 bit depth pixel to 24 bit (removing alpha)??
reply if you have an idea :o
Reputation Points: 10
Solved Threads: 0
Newbie Poster
manar is offline Offline
14 posts
since Dec 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C# Forum Timeline: counting files on a drive
Next Thread in C# Forum Timeline: overflow or under flow in arithmetic operation





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC