Page 1 of 1
Colors of an image contained in another image
Posted: 2015-02-06T08:27:25-07:00
by YvesTan
Hello,
I wish to make the following comparison:
On one side, I have a simple image (A) which contains certain colors :
On the other hand, I have another image (B) that contains a color palette :
I want to know if the dominant colors in image A are contained in image B
how do I proceed?
thank you
(french user : sorry to my bad english)
Re: Colors of an image contained in another image
Posted: 2015-02-06T10:58:33-07:00
by fmw42
Re: Colors of an image contained in another image
Posted: 2015-02-09T02:32:13-07:00
by YvesTan
Thank you for your answer
I tried:
Code: Select all
convert image_B.gif -colors 256 -depth 8 -format "%c" histogram:info:
And loop on results and push HEXA on database
Code: Select all
convert image_A.gif -colors 256 -depth 8 -format "%c" histogram:info:
And loop on resultst and compare each HEXA with image B results on database
But I think the problem is that I use a limited palette too? Not enough intervals colors?
Re: Colors of an image contained in another image
Posted: 2015-02-11T02:31:14-07:00
by YvesTan
Maybe I'm not using the right method.
The project is:
- Taking a picture of a liquid for analysis (like this:
http://www.poolplaza.com/pool-school/pH_testing.shtml)
- We try to determine in which areas of the range "red phenol" the liquid is (negative, not determined, positive)
Thank you for your advice
Re: Colors of an image contained in another image
Posted: 2015-02-11T08:55:30-07:00
by snibgo
Perhaps you have a sample colour patch and want to find that in the colour chart of pH values.
So, scale your sample to a single pixel. Then do a subimage-search for that pixel in the colour chart o find the closest match.
Re: Colors of an image contained in another image
Posted: 2015-04-01T08:55:34-07:00
by YvesTan
Hello,
My apologies for the response time. I solved my problem by calculating the distance Delta E
Thank you for your ideas