OH MY DAYS, COLOUR

Joe's icon

Hey

Having a bit of trouble analysing how much colour is in a live video that I am using.

What is the object that will allow me to see how much Red Green or Blue is in the image?

Cheers,
J

dtr's icon

One way to do that:
- [jit.op @op > @val 0.x] to threshold the image (optional)
- [jit.3m] take the mean output
- [vexpr $f1 / x] with x = the max color value (char: 255, float32: 1.), this gives you a list with the ratio of color in each RGB plane

Joe's icon

thanks

Joe's icon

In terms of analysing the numbers that are spat out, is there a chart of some kind that shows what number is what colour?

Rob Ramirez's icon

the default colormode of 4 plane jitter matrices is ARGB. so first plane is alpha, second is red, etc.

Joe's icon

Thanks.

Just going back to the first reply, I am a little bit confused with "(char: 255, float32: 1.)"
Where can I find reference to what this means?

Wetterberg's icon

It is a description of of the ranges for char and float32 data types.

>Where can I find reference to what this means?

A good way to learn it is to do the Jitter tutorials.

Joe's icon

I am still having trouble getting the required data I need

I have taken a still image of what I have set up at the moment, could anyone see where I am going wrong?

Used jit.unpack 4, jit.pack 4 and the mean output of jit.3m but still no result

Cheers,

J

4854.howmuchcolour.jpg
jpg
Joe's icon

sorted it now, no worries.

jit.3m mean output, unpacked.. sorted

cheers.