Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [color-science]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
1 answer
37 views

Why are YCbCr transforms defined in terms of gamma-corrected RGB?

I've learned a lot about digital color recently, and I've had the opportunity to implement several transforms in shaders, including converting between different RGB systems and converting into YCbCr ...
colinmarc's user avatar
  • 151
2 votes
0 answers
38 views

Is color saturation really related to light intensity?

In this article on Wikipedia, under saturation, it's written that "The purest (most saturated) color is achieved by using just one wavelength at a high intensity, such as in laser light. If the ...
xasthor's user avatar
  • 121
0 votes
0 answers
29 views

Normal blend mode math

I have one question. How to calculate source color after blending operation. For example. I have 1 - Background color (r-115, g-94, b-67, a-1) 2 - Foreground color above background color, which ...
Alisher's user avatar
0 votes
1 answer
71 views

Does CMYK values provide more colors than RGB?

We know that in the RGB system we have three primary colors and each of them has a value from $0$ to $255$ (or $256$ values in total). So all possible colors are $256^{3}=16777216$. But in the CMYK ...
Snack Exchange's user avatar
0 votes
1 answer
25 views

Is there a way to automatically optimize imags based on predefined marker on image?

Color correction is tricky. It's always a lot of work to make everything look same. I have multiple products (clothing) to take a picture of. One is 100% red, other 100% Orange. Some are multicolor ...
Grzegorz's user avatar
  • 103
0 votes
2 answers
230 views

Why are the HSL and HSV color models not considered "perceptually uniform"?

The HSL/HSV color spaces are not considered "perceptually uniform" despsite being widely used. Is there a detailed reason for this?
user avatar
1 vote
0 answers
96 views

What is the best way to display complex number "images"?

I may be getting some details wrong (e.g. colour space vs. colour model), so please bear with me: I want to represent "images" consisting of complex numbers i.e. for each "pixel" ...
Chillpadde's user avatar
0 votes
1 answer
110 views

How to visualize color synthesis in HSL diagram

before considering the HSL color space, let's consider the CIE chromaticity diagram to understand what I'm looking for: Unless I am mistaken, I read it that way: Given two points A, B, any color in ...
Kinka-Byo's user avatar
  • 103
2 votes
0 answers
25 views

What CMFs (aka Spectral Functions) did Microsoft and HP use to develop sRGB standardized in: IEC 61966-2-1:1999?

CIE 1931 2° probably served as a basis, but which version? Published in 1999, the final specification can not have referred to CIE 2006, but cvrl.org lists several others: CIE 1931 2°, CIE 1931 2° ...
Ben McKenneby's user avatar
1 vote
1 answer
96 views

Is spectral response curve and spectral power distribution the same thing?

I'm reading section 5.2 of pbrt 3rd edition and came across the part where they explain the concept of RGB colors. When we display an RGB color on a display, the spectrum that is actually displayed ...
Peter's user avatar
  • 113
2 votes
0 answers
109 views

Why do materials have both an ambient color and a diffuse color?

One of the first things I learned about computer graphics lighting (and light in general) is that when a ray of light hits a surface, the surface absorbs certain colors and the light retains the rest. ...
MothRemovalInProgress's user avatar
2 votes
2 answers
1k views

What wavelengths(dominant) the primary RGB colors are supposed to be in sRGB color space in nanometers?

The Context I am exploring the idea of making a DIY spectrometer(and colorimeter) for testing various material samples for interior visualization. It's sort of a hobby project for my curiosity and ...
Martynas Žiemys's user avatar
3 votes
2 answers
604 views

How to determine RGB values given a display spectral response curve?

I am reading Physically Based Rendering section 2.2.2 on RGB color. I am trying to understand how, given a display spectral response curves for rgb intensities, we can choose the intensities so that ...
Elad Maimoni's user avatar
3 votes
2 answers
277 views

Determining input color space primaries from spectrum data

If I have an output device, for which I have a known spectrum data for each of it's primaries, I should be able to calculate the CIEXYZ of its primaries using using the integral equations together ...
JonnyRobbie's user avatar
1 vote
2 answers
67 views

splitting hue & saturating and leaving value behind

In an HSV model, the Hue is the color model. So when we split the image or remove H, should we get an image without rgb colors? Similarly, saturation is the gray shade. I read that images become more ...
Jbd's user avatar
  • 113
1 vote
1 answer
161 views

Raytracer help - Background color writing over some colors?

I'm implementing Peter Shirley's "Raytracer in a Weekend: The next week" and I'm having some trouble with rendering a scene with a light. I'm not sure if the issue is the background color or ...
Jackie 's user avatar
4 votes
3 answers
4k views

Why is there a difference between the CIE XYZ colour gamut vs CIE RGB?

Yet another question about colour space... In my research on CIE XYZ system, I found that it is based on the CIE RGB colour matching experiments, and that because the RGB system needed occasional ...
FShrike's user avatar
  • 205
0 votes
2 answers
105 views

What is the relation between colour spaces and what is actually displayed on our screens?

I am not entirely sure that this is the right stack exchange, but I couldn't find any other suitable one - please redirect me if necessary. There exists mathematically defined colour spaces which help ...
FShrike's user avatar
  • 205
1 vote
0 answers
47 views

How to get "Equal" (saturation, brightness) Red and Green Colours in a Web-based Application?

I am looking for a red and a green hue that are equally discernable against a gray background on any PC monitor, using HTML/CSS-based application. There are many possible solutions to balance these ...
Kiki Kawai's user avatar
2 votes
0 answers
241 views

Calculating Luminance From Y'CbCr

I have a video feed generating a stream of of Y'CbCr frames (specifically 8-bit component Y'CbCr 4:2:0, luma range of 16-235, chroma range of 16-240) from which I'd like to calculate relative ...
Tricky's user avatar
  • 121
2 votes
3 answers
742 views

Strange stripes on the gradient

On the picture below you can see mathematically perfect smooth transition from black to white. But I noticed that on all gradient picture I see strange strips and the color transition doesn't feel ...
David's user avatar
  • 43
6 votes
1 answer
5k views

How do I calculate average hue, since the numbers loop around?

If I calculate the average (mean) hue of a set of colours naively, I will get silly answers sometimes. For example, in HSB/HSL, the average of hue=10 (slightly orange red) and hue=350 (slightly blue ...
spraff's user avatar
  • 289
1 vote
1 answer
60 views

Determine paint color from a photo

I ran into this problem while trying to find the paint color of the doors in my house: is it in principe possible to automatically determine the paint color from a photo? Different types of colour ...
dndr's user avatar
  • 113
2 votes
1 answer
684 views

YUV to HSV to RGB issues

As per this resource, there is an easy way to convert from YCbCr to HSV. Saturation is sqrt(Cb^2 + Cr^2). Now here is my issue. If I take pure red (1,0,0), green(0,1,0), and blue(0,0,1) colors, ...
Deepak Sharma's user avatar
3 votes
1 answer
559 views

Can someone explain this formula for parse RGB to HSL?

Im trying to complain the algorithm to calculate the HSL value form a RGB color. I understand the algorithm for the Hue, but im lost with the Lightness and saturation. Someone can explain why? There ...
TheRedosan's user avatar
4 votes
1 answer
188 views

Generating and Combining Spectral Colors

I have two somewhat related questions to ask: What is the most accurate way to get the colors of a spectrum, without having to go deep into physics and simulating the universe? ;) Right now, I'm ...
Daniel Kareh's user avatar
3 votes
2 answers
107 views

Accurately printed CIE diagram

This is more just for curiosity rather than actually wanting to get one, but is there a place where I could buy a printed version of the CIE xy colour space diagram which accurately recreates all of ...
Chuck's user avatar
  • 296
6 votes
1 answer
242 views

What determines the color gamut of a display?

I’m not sure if I’m posting this question in the right area but, I’m wondering what determines the color gamut of a display? Is or hardware down to the RGB filter built into a display like a monitor ...
ohmmy's user avatar
  • 163
17 votes
5 answers
7k views

Why do red, green, and blue make up all the colors?

Why do red, green, and blue combinations can make up all the visible colors?
Hedayat Mahdipour's user avatar
4 votes
1 answer
249 views

Does a constant reflection over the light spectrum lead to grayscale value?

I'm currently fighting with the spectrum->RGB color conversions, my algorithm seems to make an error somewhere, e.g. I get values >1 for some spectral responses. Now there is a way to calculate an ...
Tare's user avatar
  • 1,566
13 votes
1 answer
36k views

"Light intensity" of an RGB value

EDIT: I'm not fully clear on terminology here, what I previously understood to be called "brightness" seems poorly defined. I think I am asking about radiant intensity, that is, the measurable ...
jsh's user avatar
  • 133
3 votes
1 answer
143 views

Why are RGB tertiary colors so similar to RGB primary colors?

I was suprised to learn that RGB tertiary colors are much more similar to RGB primary then secondary colors. I was expecting they will be halfway between them and look more like this: Rather then ...
user6187's user avatar
6 votes
3 answers
2k views

Display that supports full CIE xyY color space

Right now, all current monitors use three (or four) primary colors to create their color, which could never allow them to produce all colors that can be seen by the human eye; in fact, their colors ...
d9584's user avatar
  • 61
9 votes
2 answers
444 views

What is the most physically accurate representation of color possible in computer graphics?

I am looking for theoretical and implemented models to represent color in software that strives for physical accuracy. I know that "color only exists in the mind" and that it sort of does not make ...
Mr. Developerdude's user avatar
4 votes
1 answer
266 views

What is the purpose of this cube in color quantization?

So, I go to install GMIC for Gimp via the package manager and landed myself upon the demo program. I have discovered things such as Hough transform and color quantization. So, I get the number of ...
Alexis Evelyn's user avatar
5 votes
2 answers
683 views

Calculate an equally bright grey to a linear RGB colour

I'm trying to get a grey linear-RGB-triple that is equally bright as another (colorful) RGB-triple. I have to admit, that there is great confusion for me with all the color stuff, even though I read a ...
PeteParly's user avatar
4 votes
1 answer
248 views

Pixel density / color channel depth ratio for dithered gradients

Dithering increases percieved color depth by adding a "noise" to an image on transform from high color depth (e.g. 32-bit floating point) to lower color depth (e.g. 8-bit integer). A prerequisite is ...
Andreas's user avatar
  • 359
8 votes
1 answer
2k views

How much precision (half, float, double, etc) is enough for a Color class?

While doing some reading on how real-time applications handle color under OpneGL, I noticed that some examples implemented Color as a collection of 4 floats, while ...
AndrewSteer's user avatar
9 votes
1 answer
308 views

Applying correct light physics to gaussian blur formulas for glow

I am trying to make a glow shader using separable gaussian blurring. I have recently been inspired by the short youtube video "computer color is broken" and I have messed with it with color ...
J.Doe's user avatar
  • 1,445
3 votes
2 answers
168 views

Matching an HSV color with a blended color

This is hard to explain but I am going to try, then I will explain it as pure mathematics. Look at this image. So basically this is a moving line, each frame a new segment is added and the previous ...
J.Doe's user avatar
  • 1,445
1 vote
2 answers
2k views

Change particular color in an image

Suppose i have a image and I want to convert the portion of image that is red to blue(or any other color). One way to do this is extract red part of image using HSV or other color values and convert ...
Sandiip's user avatar
  • 173
8 votes
1 answer
1k views

How are we supposed to fix brightness with square roots?

I recently watched this video that talked from a physics perspective how most of the ways we deal with color on the computer is incorrect because brightness is on a logarithmic not linear scale. ...
J.Doe's user avatar
  • 1,445
2 votes
1 answer
1k views

Spectral path tracing - image color/brightness incorrect

I implemented a spectral path tracing using physically base BRDF models such as Oren-Nayar,Specular Reflection and Transmission, Lambertian. All calculation in the path tracer uses standard illuminant ...
Fabrizio Duroni's user avatar
10 votes
2 answers
1k views

How is spectral rendering handled?

Is all spectral rendering handled as simulation? Are there technique more tailored to 'consumer' rendering, such as for real-time or even just 'realistic looking without solving full physical ...
New Alexandria's user avatar
12 votes
2 answers
3k views

What would be the correct way to calculate saturation in this case?

I'm trying to make a HSV representation of the xyY color space. To calculate hue from an $(x, y)$ color, I use the angle between that color and red (wavelength 745) on the xy chromacity diagram, with ...
abcd5555's user avatar
  • 123
8 votes
2 answers
422 views

Why is the CMYK space four sided in chromaticity charts

In chromaticity charts the CMYK color space is usually four-sided. I've lately had to read quite a few charts and it suddenly dawned to me that I don't really understand why. It has just not been ...
joojaa's user avatar
  • 8,437