|
-
Mar 30th, 2000, 10:04 PM
#1
Thread Starter
Addicted Member
Does anyone know how to change Contrast / Brightness in .BMP file loaded into a picturebox ?
Or any site where I can learn it (I've searched it in VB Web Directory, VB Square, VB Api, this site and more) ?
Thanks in advance,
-
Mar 31st, 2000, 03:17 AM
#2
Hyperactive Member
dunno about the contrast, but brightness is quite easy:
just use the API GetPixel to get each pixel's colour and then convert it to RGB, then increase the RGB values by a bit, then SetPixel it back using the new values. that should work, i think 
to convert long to RGB:
take long colour (called COLOUR below) , and:
Red = Colour Mod 256
Color = (Colour - Red) / 256
Green = Colour Mod 256
Color = (Colour - Green) / 256
Blue = Colour
hope that helps 
buzzwords are the language of fools
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|