[x3d-public] Which color space for Background color interpolation
Andreas Plesch
andreasplesch at gmail.com
Mon Oct 12 15:17:05 PDT 2020
The Background specification in
https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/enveffects.html#Backgrounds
states that
"The sky colour is linearly interpolated between the specified
skyColor values." and
"The ground colour is linearly interpolated between the specified
groundColor values."
The ColorInterpolator specification in
https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/interp.html#ColorInterpolator
states that
"A linear interpolation using the value of set_fraction as input is
performed in HSV space."
The ColorInterpolator language is more precise in giving the space in
which linear interpolation should be performed.
I think there is a need to also become more precise for Background
color interpolation. The consistent approach would be to choose HSV
space there as well:
"The sky colour is linearly interpolated in HSV space between the
specified skyColor values." and
"The ground colour is linearly interpolated in HSV space between the
specified groundColor values."
HSV space probably also leads to more aesthetically pleasing backgrounds.
[x3dom currently performs all color interpolation in RGB space].
Do we need such a clarification ?
-Andreas
--
Andreas Plesch
Waltham, MA 02453
More information about the x3d-public
mailing list