Re: Merging images? Roepcke asks [message #6600 is a reply to message #6523] |
Wed, 10 July 1996 00:00  |
David Foster
Messages: 341 Registered: January 1996
|
Senior Member |
|
|
panther@jungle.toppoint.de (Hendrik S. Roepcke) wrote:
>
> Hello,
>
>
> i have two images with 256 colors (in rgb-code eg).
>
> no I want wo merge this two images...
>
> a) pixel1+pixel2 / 2 is working, but not fine...
>
> how about the brightness?
>
> In addition to that I want to fade both images in an
> interactive way with sliders and then finally choose
> an setting for saving.
If the images are gray-scale, then it might help to scale them
individually and especially after adding them. Also, you can
adjust the color-table to change the "grayscale setting" to
make the images brighter and darker.
I'll mail you two routines, BYTE_SCALE() and GRAYSCALE(), that
I've written to do this.
Hope this is useful. The GRAYSCALE() routine brings up a widget
with two sliders for adjusting the window size and level of the
grayscale. The BYTE_SCALE() routine gives the same results as
TVSCL(), but saves to an array (BYTSCL() always scales between
0 and 255; BYTE_SCALE() scales between 0 and !d.n_colors-1, and
allows flexibility for reserving colors, etc.)
Hope this is useful.
Dave Foster
foster@bial1.ucsd.edu
|
|
|