Aproximayly 1/3 volume of a cube is at this picture from wikipedia . For example, If Y = 0 or Y = 1.0 (255 of 255), than Cb and Cr can be only exact 0 (only one discrete from 256).
So does YCbCr JPEG have approximately 2^(3x8)/3 = 5.6M colors?
Or approximately 60% x 2^(3x8)/3 = 10M colors from this https://stackoverflow.com/a/30105358/21548659 ?
Also coefficients KR+KG+KB=1 are used for converting YCbCr to RGB. Does each one dicrete of Cb or Cr change one of the R or G od B by one discrete? How many colors will remain after the transformation from 3x8bits YCbCr to 3x8bits RGB display (that is common conditions)?
The YCbCR colorspace as used in most JPEG file formats allows for 2^24=16,777,216 different colors.
The RGB color space that most JPEG files are converted from/to allows the same number of different colors.
However, the colors that can be represented in the two different color spaces is different so the practicable number of colors that can be represented in JPEG is less.
I have not done the exercise of counting but the way to do it would be convert all the possible YCbCR colors to RGB and count the number of colors that have an RGB value less than zero or greater than 255.
Then convert all the possible RGB values to YCbCR and make the same count.
Subtract those two counts from 2^24.