when i use this code i obtain
Code: Select all
convert fragresultc.png -define connected-components:area-threshold=0 -define connected-components:verbose=true -connected-components 8 tmp.png > data.cc
Code: Select all
Objects (id: bounding-box centroid area mean-color):
0: 242x330+0+0 132.6,99.5 28190 gray(0)
2: 192x279+24+51 122.9,167.5 11332 gray(1%)
104: 136x160+59+167 126.8,245.3 11064 gray(75%)
1: 165x300+69+30 176.1,146.4 6022 gray(1%)
24: 90x245+0+85 46.4,217.8 5201 gray(17%)
134: 59x108+0+222 22.1,281.5 4085 gray(96%)
135: 75x82+88+248 126.6,288.7 2164 gray(97%)
32: 62x80+145+102 172.2,136.6 1908 gray(23%)
11: 78x58+132+71 166.2,103.1 1237 gray(8%)
123: 54x44+16+191 37.8,215.7 1232 gray(88%)
36: 42x28+86+105 104.9,117.9 800 gray(26%)
138: 69x14+91+316 125.5,323.4 780 gray(99%)
27: 51x32+53+88 74.2,103.5 728 gray(19%)
47: 24x41+56+123 67.5,144.0 656 gray(34%)
136: 36x43+112+273 127.3,298.1 444 gray(98%)
137: 25x26+117+284 128.2,299.1 440 gray(99%)
106: 35x25+173+168 193.6,182.2 396 gray(76%)
101: 32x30+44+164 61.0,175.6 383 gray(73%)
i need to obatin the color in format similar to this
2: (50919,50919,50919) #C6E7C6E7C6E7 gray(78%)
3: (51391,51391,51391) #C8BFC8BFC8BF gray(78%)
for recognizing the diffrence in gray of same percentage