Click here to Skip to main content
15,888,579 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi all

My program extracting features from a colored image
but my code extract specified range (R,G,B) of a color
i have a problem when i test the program in a real time
the problem about Brightness
the brightness of the time of capturing the image
change colors so it be out of my code range of color
I need a help about how i get over this problem by a pre-processing

Note : if i make the range long more unwanted colors will extracted
Posted
Updated 16-May-12 7:52am
v2
Comments
Sergey Alexandrovich Kryukov 16-May-12 13:58pm    
The problem is not clear. Any code?
--SA

You probably need to convert your image into another color space, like HSL or HSB for example. So your can treat brightness as a component of the vector.
Start from this article, it contains a complete c# code.
To understand color spaces read this, or google for it.
 
Share this answer
 
v4
Comments
AmrKhalid 16-May-12 17:48pm    
Thank you For Answer Zoltán Zörgő

I Used The Brightness filter in AForge
It is very useful



private void button1_Click(object sender, EventArgs e)
{
ApplyFilter(new BrightnessCorrection() , image1);
}


private void ApplyFilter(IFilter filter , Bitmap x)
{

x = filter.Apply(x);
// display filtered image
pictureBox2.Image = x;
}
Thank you For Answer Zoltán Zörgő

I Used The Brightness filter in AForge
It is very useful


C#
private void button1_Click(object sender, EventArgs e)
        {
          ApplyFilter(new BrightnessCorrection() , image1);
        }


private void ApplyFilter(IFilter filter , Bitmap x)
        {
            
            x = filter.Apply(x);
            // display filtered image
            pictureBox2.Image = x;
        }
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900