POV-Ray : Newsgroups : povray.advanced-users : format of hf_gray_16 .bmp files? Server Time
28 Jul 2024 18:19:17 EDT (-0400)
  format of hf_gray_16 .bmp files? (Message 8 to 17 of 27)  
<<< Previous 7 Messages Goto Latest 10 Messages Next 10 Messages >>>
From: Darren New
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 13:12:51
Message: <42cd6293@news.povray.org>
Christoph Hormann wrote:
> I would be really astonished if you could find a similarly complete 
> specification for the BMP format. 

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/bitmaps_4v1h.asp

Because, of course, we all know that Microsoft hates developers and 
wouldn't want to let anyone else create software that can export to 
their proprietary formats, naturally.  That's why when you search for 
"bitmap file" nothing comes up in MSDN. ;-)

-- 
   Darren New / San Diego, CA, USA (PST)
     The samba was clearly inspired
     by the margarita.


Post a reply to this message

From: Christoph Hormann
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 13:50:01
Message: <dajptc$chn$1@chho.imagico.de>
Darren New wrote:
> Christoph Hormann wrote:
> 
>> I would be really astonished if you could find a similarly complete 
>> specification for the BMP format. 
> 
> 
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/bitmaps_4v1h.asp 

;-)

I mean they write "established bitmap file format" - which says it all.

Never try to fool an ex-OS/2 user about there being a kind of standard 
in BMP files...

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.tu-bs.de/~y0013390/ (Last updated 01 Jul. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

From: Darren New
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 14:53:46
Message: <42cd7a3a$1@news.povray.org>
Christoph Hormann wrote:
> Never try to fool an ex-OS/2 user about there being a kind of standard 
> in BMP files...

Oh, you mean OS/2 took a Windows format and modified it, but called it 
the same thing, and screwed things up? OK. ;-)

Seriously, they're *all* bitmap formats. I figured you meant the 
microsoft bitmap format. Typing "OS/2 bitmap storage" into google and 
hitting "I'm feeling lucky" gets you that bitmap format.

-- 
   Darren New / San Diego, CA, USA (PST)
     The samba was clearly inspired
     by the margarita.


Post a reply to this message

From: Mike Williams
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:01:10
Message: <VBi2$BA5UWzCFwJs@econym.demon.co.uk>
Wasn't it Christoph Hormann who wrote:
>Mike Williams wrote:
>> 
>> When I use POVRay to generate a hf_gray_16 TGA file, it works as a
>> height_field.
>> 
>> When I do exactly the same thing with a PPM file generated with
>> hf_gray_16 and +fp. I get an error "Parse Error: File is not in PPM
>> format (type 53)" when I try to use it as a height_field. (POVRay 3.6
>> Windows 98se).
>
>As said with hf_gray_16 POV-Ray generates PGM files - you have to 
>specify them as 'pgm' in the heightfield statement.

Wow, how confusing. You're right and the documentation is wrong.

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

From: Christoph Hormann
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:25:01
Message: <dajvfd$dko$1@chho.imagico.de>
Mike Williams wrote:
>>
>>As said with hf_gray_16 POV-Ray generates PGM files - you have to 
>>specify them as 'pgm' in the heightfield statement.
> 
> Wow, how confusing. You're right and the documentation is wrong.
> 

What exactly do you think is wrong in the docs?

Of course the documentation of hf_gray_16 should be more elaborate - 
important information is missing but i am not aware of anything being wrong.

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.tu-bs.de/~y0013390/ (Last updated 01 Jul. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

From: Christoph Hormann
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:35:02
Message: <dajvth$dot$1@chho.imagico.de>
Darren New wrote:
> 
> Oh, you mean OS/2 took a Windows format and modified it, but called it 
> the same thing, and screwed things up? OK. ;-)

I am sure MS would describe things like this.

> Seriously, they're *all* bitmap formats. I figured you meant the 
> microsoft bitmap format. Typing "OS/2 bitmap storage" into google and 
> hitting "I'm feeling lucky" gets you that bitmap format.

No, but this isn't really the topic - i just wanted to point out that 
there is nothing even approximately as well defined as the PPM/PGM specs 
for BMP.

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.tu-bs.de/~y0013390/ (Last updated 01 Jul. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

From: Darren New
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:42:26
Message: <42cd85a2$1@news.povray.org>
Christoph Hormann wrote:
 > No, but this isn't really the topic - i just wanted to point out that
 > there is nothing even approximately as well defined as the PPM/PGM specs
 > for BMP.

OK. I'd disagree, given the resources I pointed you to and the number of 
people who have written to the specs. And in spite of the specs being 
well-defined for PPM/PGM, it's not the case that everyone importing 
those formats follows the specs either, including POV-Ray.

-- 
   Darren New / San Diego, CA, USA (PST)
     The samba was clearly inspired
     by the margarita.


Post a reply to this message

From: Mike Williams
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:49:36
Message: <ZPlVMAAlYYzCFwo5@econym.demon.co.uk>
Wasn't it Christoph Hormann who wrote:
>Mike Williams wrote:
>>>
>>>As said with hf_gray_16 POV-Ray generates PGM files - you have to 
>>>specify them as 'pgm' in the heightfield statement.
>> 
>> Wow, how confusing. You're right and the documentation is wrong.
>> 
>
>What exactly do you think is wrong in the docs?

It says that you can use a PPM file as a 16-bit height field, but you
have to use a PGM file (and the syntax is "height_field pgm filename").

It says that +fp outputs a PPM file, but if hf_gray_16 is active the
output is a PGM file with an incorrect extension.

I don't think that there's any way that someone could guess the correct
way to use PGM hf_gray_16 files by reading the documentation.

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

From: Christoph Hormann
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 15:55:02
Message: <dak17s$dvs$1@chho.imagico.de>
Darren New wrote:
> And in spite of the specs being
> well-defined for PPM/PGM, it's not the case that everyone importing 
> those formats follows the specs either, including POV-Ray.

In what way does POV-Ray's reading of PPM/PGM not follow the specs?

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.tu-bs.de/~y0013390/ (Last updated 01 Jul. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

From: Christoph Hormann
Subject: Re: format of hf_gray_16 .bmp files?
Date: 7 Jul 2005 16:20:01
Message: <dak2g9$e9p$1@chho.imagico.de>
Mike Williams wrote:
> 
> It says that you can use a PPM file as a 16-bit height field, but you
> have to use a PGM file (and the syntax is "height_field pgm filename").

You can use a PPM file in a height_field,

height_field {
   ppm "test.ppm"
}

works for any valid PPM - of course not for a PGM.

> It says that +fp outputs a PPM file, but if hf_gray_16 is active the
> output is a PGM file with an incorrect extension.

That's right.

> I don't think that there's any way that someone could guess the correct
> way to use PGM hf_gray_16 files by reading the documentation.

What's unclear about the use of PGMs? - you can use them in 
heightfields, image maps and elsewhere just like any other image file 
format supported.

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.tu-bs.de/~y0013390/ (Last updated 01 Jul. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

<<< Previous 7 Messages Goto Latest 10 Messages Next 10 Messages >>>

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