you might want to unpremult the image first, so you don't let transparencies contaminate the result
On Sep 2, 2011, at 2:45 AM, Hugh Macdonald wrote: > You could generate an alpha based on value!=0. > > Then blur very heavily, and unpremult. > > > Hugh > > On 01/09/11 01:06, Jordan Olson wrote: >> >> hi fellow TDs! >> >> I'm working on a gizmo atm- and am trying to figure out the best way for >> this. >> I'd like to find the average non-zero value of a channel on the current >> frame. (working with depth and motion blur) >> >> The slowest way I can imagine doing it is to run nuke.sample() on every >> pixel with an if statement, to eventually average the non-zero (or alpha) >> pixel values together. Surely there's a better way to do it? Ideally this >> should happen on every frame transparent to the comper. >> >> Cheers, >> Jordan >> >> _______________________________________________ >> Nuke-python mailing list >> [email protected], http://forums.thefoundry.co.uk/ >> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python > > _______________________________________________ > Nuke-python mailing list > [email protected], http://forums.thefoundry.co.uk/ > http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
_______________________________________________ Nuke-python mailing list [email protected], http://forums.thefoundry.co.uk/ http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
