Skip to content

How to apply Gray-Scale filter? #25

Answered by Ank1taS
H1manshu21 asked this question in Q&A
Discussion options

You must be logged in to vote

By applying the Grayscale effect the original image will convert to a black and white image.

In GrayScale effect all channels (red, green, blue) of a pixel have a specific value that, results in gray and according to this value, various shades of gray a pixel can have. Higher values mean lighter shades (closer to white) and lower values mean darker shades (closer to black).

There are different algorithms for Grayscale, however here is an illustration of Average algorithm
In the average algorithm, in a Grayscale image, each pixel's red, green and blue channel contains the same value i.e the average of the 3 channels of the original image.

Example of Original Image vs Grayscale Image

Pseud…

Replies: 2 comments 6 replies

Comment options

You must be logged in to vote
4 replies
@SHembram18
Comment options

@H1manshu21
Comment options

H1manshu21 May 16, 2022
Maintainer Author

@Ank1taS
Comment options

@H1manshu21
Comment options

H1manshu21 May 18, 2022
Maintainer Author

Comment options

You must be logged in to vote
2 replies
@H1manshu21
Comment options

H1manshu21 May 18, 2022
Maintainer Author

@SHembram18
Comment options

Answer selected by H1manshu21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
documentation Improvements or additions to documentation enhancement New feature or request help wanted Extra attention is needed question Further information is requested Important
4 participants