Sign in to follow this  
BoltBait

Plugin Concept: Complementary Colors

Recommended Posts

I was playing with the Complementary Colors Calculator at https://www.sessions.edu/color-calculator/

 

I made a plugin to simulate the algorithm...

 

Not an official release yet as I may need to tweak the algorithm I wrote.  I could not find a good source for the code, so I cobbled together something that kinda works.

 

Here's how it looks:  (It lives in the Effects > Fill menu.)

 

ComplementUI.png

 

It fills your selection with the selected color.  Use it to build a palette for your design project.

 

The help file (?) contains more information.

 

And, here's the download:

 

complement.zip

 

Enjoy.

 

  • Like 2
  • Upvote 2

Share this post


Link to post
Share on other sites
2 hours ago, xod said:

There is a plugin called Color Harmonies.
Is it different from what you offer us?

 

Honestly, I have no idea. I never downloaded that plugin.

 

But, I'll take a guess and say that it is probably using the RGB colorwheel instead of the RYB colorwheel I'm using.

 

Share this post


Link to post
Share on other sites

Thanks, but converting between the two color spaces was not necessary.  And, I had actually found code for that anyway. 

 

https://github.com/sanjayatpilcrow/SharpSnippets/blob/master/POCs/POCs/Sanjay/SharpSnippets/Drawing/ColorExtensions.cs

 

What I found difficult was measuring distances around the RYB colorwheel since the hue between each color is a different distance. This can be seen in the colorwheel shown in the help file (if you calculate the distances between each color).

 

I ended up just hard coding a 360 byte array. :D 

 

Here is what I used for RYB :arrow-downright:

RYB.png

P              S               P              S               P              S               P          (P=Primary, S=Secondary)

RGB.png

Compare that to RGB :arrow-upright:

 

The colors are in the same order, just some areas are stretched and some are compressed in the RYB model.  In the RGB model, all hue's are equally spaced.

 

(I had to write a CodeLab script to create that RYB image.  BTW, it doesn't matter that the green is dark, I'm only looking at the Hue.)

 

Share this post


Link to post
Share on other sites

From what I found, the RYB bar doesn't seem very accurate. Here's what I got with my own g'mic command, looks more like the reference you posted in the original link. This is more based on painting, and the only downfall is the blue is terrible.

 

image.png.457a2ce097216dbd4845d7bba92c5f22.png

 

EDIT: Never mind. Just making this more saturated alone the desaturation issue.

 

 

Edited by Reptillian

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this