Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8268865
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T06:02:13+00:00 2026-06-08T06:02:13+00:00

Im doing a normalization for my image and i’ve already gotten done the RGB

  • 0

Im doing a normalization for my image and i’ve already gotten done the RGB values for the image. can anyone help me with the RGB normalization for the c# codes like maybe some starters on how to write out the normalization code. thanks!


private void normalization_Click(object sender, EventArgs e)
{
// for (int x = 0; x < pictureBox1.Width; x++)
{

           // for (int y = 0; y < pictureBox1.Height; y++)
            {


                try
                {
                    Bitmap img = new Bitmap(pictureBox1.Image);
                    Color c;
                    for (int i = 0; i < img.Width; i++)
                    {
                        for (int j = 0; j < img.Height; j++)
                        {
                            c = img.GetPixel(i, j);
                            int r = Convert.ToInt16(c.R);
                            int g = Convert.ToInt16(c.G);
                            int b = Convert.ToInt16(c.B);

                            d = r / (r + g + b);
                            h = g / (r + g + b);
                            f = b / (r + g + b);

                            img.SetPixel(i, j, Color.FromArgb(d, h, f));

                            Color pixelColor = img.GetPixel(i, j);
                            float normalizedPixel = (d + h + f);
                            Color normalizedPixelColor = System.Drawing.ColorConverter.(normalizedPixel);
                            img.SetPixel(x, y, normalizedPixelColor);

                        }
                    }

                }
                catch (Exception ex) { }

Hi. I’ve done the formulaes and all for normalization. The problem that I am facing now is that I’m having trouble getting the values of the RGB pixels out of the listbox and normalizing it with the formulae and then putting the pixels back into picturebox/image. Above is the code that i’ve tried to do to put the normalized RGB pixels back into the picturebox. Can I ask for some help with this because it still doesn’t normalize my image. Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T06:02:15+00:00Added an answer on June 8, 2026 at 6:02 am

    Have a look at AForge.NET if you do not mind having a dependency in your project. As a bonus you’ll have plenty of other algorithms at your availability without the need for you to re-invent the for loop…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm currently doing some normalization along the lines of: J = Integrate[Psi[x, 0]^2, {x,
Doing something like this: from zipfile import ZipFile #open zip file zipfile = ZipFile('Photo.zip')
Doing a project in win32 in c++, attempting to double buffer the image being
Doing some archiving/deleting of some uncommonly used databases on an Oracle server. Has anyone
I would like to know about how NULL values affect query performance in SQL
Doing an expression I get an error, can someone show me the correct syntax
When doing something like this: <div style=float: left;>Left Div</div> <div style=float: right;>Right Div</div> I
I'm doing a simple normalization on a vector (weights), trying to make use of
I'm doing some research on ranking algorithms, and would like to, given a sorted
Doing some debugging in windbg, and I'd like to be able to go through

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.