POV-Ray : Newsgroups : povray.general : 16-bit grayscale PNGs -> PoV-Ray 16-bit heightfield TGAs? : Re: 16-bit grayscale PNGs -> PoV-Ray 16-bit heightfield TGAs? Server Time
31 Jul 2024 04:19:07 EDT (-0400)
  Re: 16-bit grayscale PNGs -> PoV-Ray 16-bit heightfield TGAs?  
From: Kenneth
Date: 31 Mar 2008 06:10:00
Message: <web.47f0c50eb76e233678dcad930@news.povray.org>
Alain <ele### [at] netscapenet> wrote:
> Kenneth nous apporta ses lumieres en ce 2008/03/27 21:24:

> >
> > So if the file_type has to be manually set to .png, and the Bits_Per_Color to
> > 16--what exactly does global{hf-gray-16} do?? Besides making the image
> > gray-scale?  Hmm, perhaps that IS its only purpose, to eliminate unnecessary
> > color channels. Gee, I feel smarter already!
> >
> > Ken W.
> >
> >
> hf_gray_16 turn the display black and white and the file output to a specialy
> formated TGA file with the hight encoded in the red and green chanels.

It doesn't *automatically* switch the file output to TGA--that still has to be
set manually, in the INI file or on the command line.

> Low part in the green and high part in the red. It still an 8 bit per
> channel file. If you open it in a graphic viewer, you see a red shape
> striped with green gradients. The blue channel is set to zero everywhere.

Yes, I see that now.  Thanks. It *is* a strange-looking image, when pulled up in
Photoshop. The red channel looks like the image, but the green channel looks
like distorted noise!  But somehow it all works.

Concerning the Bits_Per_Color setting:  I did a series of TGA tests, setting
Bits_Per_Color to 2,then 4,8,16 and then leaving it out altogether.  The
resulting images (and the HFs made from them) all look identical.  Which leads
me to believe that Bits_Per_Color is ignored, and automatically set to 16 when
global_settings{hf_gray_16} is used.

Ken W.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.