hello
I've been smashing my head against my desk all evening trying to grab a range of grayscale values in a gradient/mask using the pixel processor
I can select a "stripe" from a gradient as a 1 bit mask easily enough
I can also bash a distance node after it to get a nice gradient
what would be nice is to be able to do all that within the pixel processor. I don't want to simply work over a pixel distance - that would be cheating and also wrong. What I'd like to do is build the gradient based on the values within the range I'm selecting (ie. normalized gradient from the matching value out to the edges of the range)
I'm struggling with trying to normalize a float mostly - it's hard to work out what the min/max values of the whole image is when you can only look at one pixel.
Do I need to sample in the whole image (or bits) to do this or is there a cunning way that only clever people know about?
sorry for the rambling. has anyone done this succesfully? i found a height slice thing on substance share but it doesn't work as elegantly as I'd like.
ta
Replies
https://share.allegorithmic.com/libraries/2569
here the .sbs: https://www.dropbox.com/s/fel5rzidm1z1mjm/histogram_select.sbs?dl=0