I have a feeling that the .identify() method is getting called on the original image rather than the post-scaled image. If so, what's the best way to correct this and have identify called on the result of the scale? Would it require writing it first to a file/buffer then reading it?
Any help would be appreciated. Thanks.
The following command is specified in the IM docs as a simple way to extract the dominant color from an image:
This yields the following result for my image:
srgb(129,109,85)
.Now I'm trying to do this same command using gm, but I'm getting a very different color. I'm obviously doing something wrong. Here is what I tried:
I have a feeling that the
.identify()
method is getting called on the original image rather than the post-scaled image. If so, what's the best way to correct this and haveidentify
called on the result of thescale
? Would it require writing it first to a file/buffer then reading it? Any help would be appreciated. Thanks.