POV-Ray : Newsgroups : povray.general : polygon not visible Server Time
10 Dec 2024 06:12:43 EST (-0500)
  polygon not visible (Message 1 to 6 of 6)  
From: folkert
Subject: polygon not visible
Date: 29 Nov 2024 18:25:00
Message: <web.674a4c31296bdfa2e3cbe740b3ec8729@news.povray.org>
Hi,

I'm trying to render a simple script:

polygon { 5, <15.45085, 0, 47.55283>, <15.11321, -3.212412, 47.55283>,
<24.45369, -5.197792, 43.30127>, <25, 0, 43.30127>, <15.45085, 0, 47.55283>
texture { pigment { color rgb <1, 0, 0> } } }

sky_sphere { pigment { color rgb <1, 1, 1> } }
camera { look_at <15, -3, 47> location <0, 0, 100> }
light_source { <0, 0, 100> color rgb <1, 1, 1> }


The red polygon is not visible. Any ideas why?


Post a reply to this message

From: William F Pokorny
Subject: Re: polygon not visible
Date: 29 Nov 2024 20:55:20
Message: <674a7088$1@news.povray.org>
On 11/29/24 18:20, folkert wrote:
> Hi,
> 
> I'm trying to render a simple script:
> 
> polygon { 5, <15.45085, 0, 47.55283>, <15.11321, -3.212412, 47.55283>,
> <24.45369, -5.197792, 43.30127>, <25, 0, 43.30127>, <15.45085, 0, 47.55283>
> texture { pigment { color rgb <1, 0, 0> } } }
> 
> sky_sphere { pigment { color rgb <1, 1, 1> } }
> camera { look_at <15, -3, 47> location <0, 0, 100> }
> light_source { <0, 0, 100> color rgb <1, 1, 1> }
> 
> 
> The red polygon is not visible. Any ideas why?
> 

The polygon is set up as a 2D object sitting in an x,y plane somewhere 
along z.

The normal way to specify it is to use 2D vectors of <x,y> or <u,v> 
values.

You can specify 3 coordinates, but the z values must all be the same. If 
not, the parser is supposed to issue an error because the polygon code 
won't work. However, it looks like that checking got dropped at some point.

I see this as a parser bug.

Bill P.


Post a reply to this message

From: folkert
Subject: Re: polygon not visible
Date: 30 Nov 2024 04:05:00
Message: <web.674ad4ab665357ecad5190bdb3ec8729@news.povray.org>
> The polygon is set up as a 2D object sitting in an x,y plane somewhere
> along z.

Ah ok!
Thanks for clarifying. Do you know if there's an other way of defining
polygon-alike structures in povray?

> I see this as a parser bug.

I'll submit an issue in github.


Post a reply to this message

From: jr
Subject: Re: polygon not visible
Date: 30 Nov 2024 05:05:00
Message: <web.674ae2b2665357ecb2e841a6cde94f1@news.povray.org>
hi,

"folkert" <fol### [at] vanheusdencom> wrote:
> > The polygon is set up as a 2D object sitting in an x,y plane somewhere
> > along z.
>
> Ah ok!
> Thanks for clarifying. Do you know if there's an other way of defining
> polygon-alike structures in povray?

POV-Ray does have (pretty decent) documentation, see eg:
<https://wiki.povray.org/content/Reference:Polygon>
<https://wiki.povray.org/content/Documentation:Contents>

hth.


regards, jr.


Post a reply to this message

From: folkert
Subject: Re: polygon not visible
Date: 30 Nov 2024 05:10:00
Message: <web.674ae447665357ecad5190bdb3ec8729@news.povray.org>
> > > The polygon is set up as a 2D object sitting in an x,y plane somewhere
> > > along z.
> >
> > Ah ok!
> > Thanks for clarifying. Do you know if there's an other way of defining
> > polygon-alike structures in povray?
>
> POV-Ray does have (pretty decent) documentation, see eg:
> <https://wiki.povray.org/content/Reference:Polygon>
> <https://wiki.povray.org/content/Documentation:Contents>

That doesn't tell me how to go from a 3D polygon to something PovRay
understands.

But for now I triangulate my polygons and put them in a mesh2 object.


Post a reply to this message

From: jr
Subject: Re: polygon not visible
Date: 30 Nov 2024 05:50:00
Message: <web.674aed2c665357ecb2e841a6cde94f1@news.povray.org>
hi,

"folkert" <fol### [at] vanheusdencom> wrote:
> > > > The polygon is set up as a 2D object sitting in an x,y plane somewhere
> > > > along z.
> > >
> > > Ah ok!
> > > Thanks for clarifying. ...
> That doesn't tell me how to go from a 3D polygon to something PovRay
> understands.
> But for now I triangulate my polygons and put them in a mesh2 object.

"language barriers" :-)  polygon, the dictionary tells me:
1. (geometry) A plane figure bounded by edges that are all straight lines.

you, otoh, appear to be talking "polyhedron":
1. (geometry) A solid figure with many flat faces and straight edges.

mesh2 seems a good choice.


regards, jr.


Post a reply to this message

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