POV-Ray : Newsgroups : povray.general : Help: Working with color-wheels Server Time
29 Jul 2024 12:26:23 EDT (-0400)
  Help: Working with color-wheels (Message 1 to 3 of 3)  
From: B  Gimeno
Subject: Help: Working with color-wheels
Date: 20 Aug 2011 18:25:01
Message: <web.4e5030ffabda0cd016f97d4b0@news.povray.org>
Hi folks,
How can we calculate the complementary color of a given color?

I'm trying to write a macro for calculate the analogous and complementary colors
for a given value, something like what you get on this page:

http://www.yafla.com/yaflaColor/ColorRGBHSL.aspx

but for the moment I'm blank as working with color wheels in pov-ray rgb
vectors.

Here are a staple in Spanish to review the theory of colors, the images show the
relationships between complementary colors.
http://brizkomania.blogspot.com/2011/01/repaso-basico-la-teoria-del-color.html

Thanks in advance, the pov-ray links to color wheels rusted time ago

B. Gimeno
Sorry for my syntactic errors automatic translated.


Post a reply to this message

From: Alain
Subject: Re: Help: Working with color-wheels
Date: 20 Aug 2011 19:04:04
Message: <4e503d64$1@news.povray.org>

> Hi folks,
> How can we calculate the complementary color of a given color?
>
> I'm trying to write a macro for calculate the analogous and complementary colors
> for a given value, something like what you get on this page:
>
> http://www.yafla.com/yaflaColor/ColorRGBHSL.aspx
>
> but for the moment I'm blank as working with color wheels in pov-ray rgb
> vectors.
>
> Here are a staple in Spanish to review the theory of colors, the images show the
> relationships between complementary colors.
> http://brizkomania.blogspot.com/2011/01/repaso-basico-la-teoria-del-color.html
>
> Thanks in advance, the pov-ray links to color wheels rusted time ago
>
> B. Gimeno
> Sorry for my syntactic errors automatic translated.
>
>
>
>
>

In the colors.inc file, there is a macro to convert from RGB to HSV. The 
hue returned is in degree going from 0 to 360.
Convert your colour from RGB to HSV, add 180 to the hue and convert back 
to RGB and you're done. The saturation and brightness will stay the same.


Alain


Post a reply to this message

From: B  Gimeno
Subject: Re: Help: Working with color-wheels
Date: 21 Aug 2011 03:20:00
Message: <web.4e50b163c5a5b2fe93655c1e0@news.povray.org>
>
> In the colors.inc file, there is a macro to convert from RGB to HSV. The
> hue returned is in degree going from 0 to 360.
> Convert your colour from RGB to HSV, add 180 to the hue and convert back
> to RGB and you're done. The saturation and brightness will stay the same.
>
>
> Alain

Thank you very much for your help. My eyes, harmed by random combinations of
colors pink + lime green thanks you too.

B. Gimeno


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.