- DIP - Computer Vision and Graphics
- DIP - Optical Character Recognition
- DIP - JPEG compression
- DIP - Introduction to Color Spaces
- DIP - High Pass vs Low Pass Filters
- DIP - Convolution theorm
- DIP - Fourier series and Transform
- DIP - Frequency Domain Analysis
- DIP - Laplacian Operator
- DIP - Krisch Compass Mask
- DIP - Robinson Compass Mask
- DIP - Sobel operator
- DIP - Prewitt Operator
- DIP - Concept of Edge Detection
- DIP - Concept of Blurring
- DIP - Concept of Masks
- DIP - Concept of convolution
- DIP - Gray Level Transformations
- DIP - Histogram Equalization
- DIP - Introduction to Probability
- DIP - Histogram Stretching
- DIP - Histogram Sliding
- DIP - Image Transformations
- DIP - Brightness and Contrast
- DIP - Histograms Introduction
- DIP - Concept of Dithering
- DIP - ISO Preference curves
- DIP - Concept of Quantization
- DIP - Gray Level Resolution
- DIP - Pixels Dots and Lines per inch
- DIP - Spatial Resolution
- DIP - Zooming methods
- DIP - Concept of Zooming
- DIP - Pixel Resolution
- DIP - Concept of Sampling
- DIP - Grayscale to RGB Conversion
- DIP - Color Codes Conversion
- DIP - Types of Images
- DIP - Concept of Bits Per Pixel
- DIP - Perspective Transformation
- DIP - Concept of Pixel
- DIP - Camera Mechanism
- DIP - Image Formation on Camera
- DIP - Concept of Dimensions
- DIP - Applications and Usage
- DIP - History of Photography
- DIP - Signal and System Introduction
- DIP - Image Processing Introduction
- DIP - Home
DIP Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Brightness and Contrast
Brightness
Brightness is a relative term. It depends on your visual perception. Since brightness is a relative term, so brightness can be defined as the amount of energy output by a source of pght relative to the source we are comparing it to. In some cases we can easily say that the image is bright, and in some cases, its not easy to perceive.
For example
Just have a look at both of these images, and compare which one is brighter.
We can easily see, that the image on the right side is brighter as compared to the image on the left.
But if the image on the right is made more darker then the first one, then we can say that the image on the left is more brighter then the left.
How to make an image brighter.
Brightness can be simply increased or decreased by simple addition or subtraction, to the image matrix.
Consider this black image of 5 rows and 5 columns
Since we already know, that each image has a matrix at its behind that contains the pixel values. This image matrix is given below.
0 | 0 | 0 | 0 | 0 |
0 | 0 | 0 | 0 | 0 |
0 | 0 | 0 | 0 | 0 |
0 | 0 | 0 | 0 | 0 |
0 | 0 | 0 | 0 | 0 |
Since the whole matrix is filled with zero, and the image is very much darker.
Now we will compare it with another same black image to see this image got brighter or not.
Still, both images look the same. To make the second one brighter we just need to add the value 1 to each element in the matrix representing it.
What we will do is, that we will simply add a value of 1 to each of the matrix value of image 1. After adding the image 1 would something pke this.
Now we will again compare it with image 2, and see any difference.
We see, that still we cannot tell which image is brighter as both images looks the same.
Now what we will do, is that we will add 50 to each of the matrix value of the image 1 and see what the image has become.
The output is given below.
Now again, we will compare it with image 2.
Now you can see that the image 1 is spghtly brighter then the image 2. We go on, and add another 45 value to its matrix of image 1, and this time we compare again both images.
Now when you compare it, you can see that this image1 is clearly brighter then the image 2.
Even it is brighter then the old image1. At this point the matrix of the image1 contains 100 at each index as first add 5, then 50, then 45. So 5 + 50 + 45 = 100.
Contrast
Contrast can be simply explained as the difference between maximum and minimum pixel intensity in an image.
For example.
Consider the final image1 in brightness.
The matrix of this image is:
100 | 100 | 100 | 100 | 100 |
100 | 100 | 100 | 100 | 100 |
100 | 100 | 100 | 100 | 100 |
100 | 100 | 100 | 100 | 100 |
100 | 100 | 100 | 100 | 100 |
The maximum value in this matrix is 100.
The minimum value in this matrix is 100.
Contrast = maximum pixel intensity(subtracted by) minimum pixel intensity
= 100 (subtracted by) 100
= 0
0 means that this image has 0 contrast.
Advertisements