[Sidefx-houdini-list] COPS - Average Colour Luminance in Image

Pete Wallace pies4peter at hotmail.com
Fri Apr 20 16:18:34 EDT 2007


 
francois suggested :
A first math with 100/(720*576) 
and lay out a second Math to multiply by 0.001 the result.
i guess there must have been some rounding issues.
 
and this has brought the result within a decent range.
 
(The result is 3.05 for a white image)
 
- I'm now multiplying by a 'magic' number 
to get the results between 0 and 1
 
feels fishy tho!   (Well, it is Friday)
 
I'm pretty sure i've missed something...
- Do i need to mess with CHOP parameters, like samples - & frames<VS>seconds etc?
 
 
 
 
 
 
 
> From: pies4peter at hotmail.com> To: sidefx-houdini-list at sidefx.com> Subject: RE: [Sidefx-houdini-list] COPS - Average Colour Luminance in Image> Date: Fri, 20 Apr 2007 10:09:13 +0000> > > > Thanks for the method Mark> > - Right now I'm getting 0 in the result > Though everything looks healthy up until the Maths CHOPs :/> > here's the locked tree:> http://www.grittyknitters.com/files/pete/image.hipnc> > Am i trimming it correctly? bearing in mind the image is 720x576?> > Pete> Pete Wallacepies4peter at hotmail.commob. 07759 039 167> > > Date: Thu, 19 Apr 2007 14:46:10 -0400> From: malexander at sidefx.com> To: sidefx-houdini-list at sidefx.com> Subject: Re: [Sidefx-houdini-list] COPS - Average Colour Luminance in Image> > > Mark A showed me a cool way of doing this using CHOPs. Read the> > whole image into CHOPs then... > > Yes, you read the entire image into CHOPs via an Image CHOP (Alpha = > none, Crop = Full Image), then append an Area CHOP, then trim the > channel to the last frame using a Trim CHOP, then use a Math CHOP to sum > the channels, and then use another Math CHOP (or, the same one) to scale > the value by 1/(xres * yres). You'll end up with a single channel with a > single point, and that will be the average value.> > M.> _______________________________________________> Sidefx-houdini-list mailing list> Sidefx-houdini-list at sidefx.com> https://lists.sidefx.com:443/mailman/listinfo/sidefx-houdini-list_______________________________________________> Sidefx-houdini-list mailing list> Sidefx-houdini-list at sidefx.com> https://lists.sidefx.com:443/mailman/listinfo/sidefx-houdini-list


More information about the Sidefx-houdini-list mailing list