[Radiance-general] getting pixel value at x,y
Greg Ward
gregoryjward at gmail.com
Thu May 29 10:25:53 PDT 2008
Hi Lars,
So, this is why being specific about your problem helps -- we avoid a
lot of spurious suggestions that don't apply.
The best/fastest solution for rectangular areas is pcompos piped into
pvalue and total, like so:
pcomb -o captured.pic \
| pcompos -x ${box_width} -y ${box_height} - -${left} -${lower} \
| pvalue -h -H -df | total -if3 -m
The initial pcomb command is necessary to apply the exposure values
correctly. If you want luminance (rather than radiance) output, use:
pcomb -s 179 -o captured.pic \
| pcompos -x ${box_width} -y ${box_height} - -${left} -${lower} \
| pvalue -h -H -b -df | total -if -m
Either of these commands will be very fast compared to any script you
might concoct.
-Greg
> From: "Lars O. Grobe" <grobe at gmx.net>
> Date: May 29, 2008 8:52:51 AM PDT
>
> First thanks for the replies and suggestions. What I actually want to
> do, is to sample pixel values over an area and get the average.
> This is
> done for a HDR image assembled of photographs, so I cannot use vwrays.
> Pfilt also does not work, as I need the samples to hit a light
> source in
> a black (dark) surrounding. What I did now is writing a script in perl
> which filters the output of pvalue, but still, as these files are
> large
> and I am working on batches of such images, it is not that comfortable
> to do so (it takes time). I am taking these values into my script
> anyway, so writing this was not the problem, it is more about the
> unnecessary lookups of all those pixels that are just not that
> interesting.
>
> CU Lars.
More information about the Radiance-general
mailing list