P
P
Pavel Zhukau2015-08-21 23:02:54
MySQL
Pavel Zhukau, 2015-08-21 23:02:54

What is the best way to make a multidimensional dependence of colors on an object?

Good evening everyone. The question was probably formulated not as correctly as it should be, but I couldn’t come up with a better one. The bottom line is this: there is an object that has some color, and you need to pick up other objects that match the color. That is, there is a table of colors, and you need to somehow bind the colors that match each other. I thought for a long time, I tried to implement it in different ways, but the problem is that, for example, white can be combined with black and green, and green with blue, for example. So far, there is only one option in my head, namely to do a direct binding, that is, to store which colors I match, 1,2,3, 2,5,9, 20,5,4. But there are a lot of such options, and it seems to me that this is not the most rational way. Thanks in advance for the replies.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Alexander Taratin, 2015-08-21
@Taraflex

paletton.com
https://color.adobe.com/en/create/color-wheel/

S
SeptiM, 2015-08-22
@SeptiM

I saw a rather elegant solution in one smart design book. Do you need a palette? Take any photo of nature and drag the colors from there.
You can try to automate this business. The input is a photo, the output is ten colors that prevail in this photo.

S
Stanislav Makarov, 2015-08-22
@Nipheris

Your color matching is an ordinary graph in its purest form. Vertices - colors, edge - the fact of compatibility of two colors. How to store this graph is the tenth thing. How to enter it into the system is also a separate issue, although, of course, this will all have to be manually entered, because. compatibility is 80-90% subjective perception.
To select N items of different colors (well, or just N different colors for M >= N different items), find a subgraph with the required number of vertices, where all vertices are connected to each other, including some given vertices. For example, a 3-vertex subgraph containing a "green" vertex, with each vertex of the subgraph connected to another vertex by an edge (i.e., the path length is always 1). This means that in the kit you will only have colors that are compatible with each other, one of which is green.
You can increase the path length to 2, then if white is compatible with black, black with green, but white is NOT compatible with green, then such a set of colors will still be acceptable.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question