Jump to content

Brightest Point In Image


symek

Recommended Posts

hallo!

I wonder if there is a way in VEX to find brightest or darkest pixel in image without coding some fansy loop... I would like to know the range in pixel value from input before I apply some filter designed in VEX.

I don't need t6o know the positon - just info, that white point is at 17.4 and black at -3.6 (in floating point image for example)

thanks for help.

PS Mplay have a buttom which normalize the image range to 0 and 1. To do this it must know "bri" and "dark" to clamp or shift data.

Link to comment
Share on other sites

Hey there,

You can slurp the image into CHOPs and find the value there - probably with icmin() and icmax() or such. (type exhelp icmax in a Houdini textport). You might want to run it though the Mono COP first (if you want Luminance or Max Component) and just suck in the single resultant channel into CHOPs.

There might be other tricks too- I was kinda hoping that the new "minmax" filter that we see in Mantra 8.0 would have snuck into the Scale (downscale) filter menu then you could've scaled the image down to a single pixel and a "minmax max" would've sorted it out for you.

Hope this helps,

Jason

Link to comment
Share on other sites

no, no,

I meant that function which gives you back a max or min value in some data, set, array (plate!) it is so common need that it should be implemented in VEX. Houdini must use such function all the time, for example in MPlay to automatic shift pixel for 0 to 1... I'm sure there is a way to get it :).

Link to comment
Share on other sites

no, no,

I meant that function which gives you back a max or min value in some data, set, array (plate!)  it is so common need that it should be implemented in VEX. Houdini must use such function all the time, for example in MPlay to automatic shift pixel for 0 to 1... I'm sure there is a way to get it :).

22627[/snapback]

Probably some nice access to the histogram would be able to provide a lot of this, no?

Link to comment
Share on other sites

  • 1 month later...
  • 2 months later...

Huh, I have the same problem. The basic idea is clear - Image COP and icmin/icmax expression functions. But I wonder how we can use ic* for "export" values from CHOPs to COPs. I'm asking because ic* work in the sand-box of the _current_ CHOP. And I can't use them as expression in my COPs.

So what can I do? :huh:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...