![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Er, I thought you were supposed to be able to have different triangles in
a mesh have different pigments or textures, but I'm getting seemingly
contradictory error messages when I render.
I have a mesh that I want to use for some panes in a "stained glass"
window, and I want the triangles to be of different glass textures from
the glass.inc file.
I'm specifically trying to use the Col_Glass_Winebottle on individual
triangles, like so:
#declare leaf_window =
mesh {
triangle {<a>, <b>, <c> texture { Col_Glass_Winebottle}}
triangle {<c>, <d>, <e> texture { Col_Glass_Orange }}
etc...
}
but it chokes on the first one, saying
-- Parse Error: Expected 'texture identifier', colour identifier found instead
so if I change the above to say "pigment { Col_Glass_Winebottle}}", it
says:
Parse Error: No matching } in 'triangle', pigment found instead
So which is it, a texture or a pigment ? WTF?!?
The docs use a texture statement within individual triangles, so I know
I'm supposed to be able to treat each one separately. What obvious thing
am I missing?
Thanks for any help!
Mark W.
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Mark M. Wilson" wrote:
>
> Er, I thought you were supposed to be able to have different triangles in
> a mesh have different pigments or textures, but I'm getting seemingly
> contradictory error messages when I render.
>
> I have a mesh that I want to use for some panes in a "stained glass"
> window, and I want the triangles to be of different glass textures from
> the glass.inc file.
>
> I'm specifically trying to use the Col_Glass_Winebottle on individual
> triangles, like so:
>
> #declare leaf_window =
> mesh {
> triangle {<a>, <b>, <c> texture { Col_Glass_Winebottle}}
> triangle {<c>, <d>, <e> texture { Col_Glass_Orange }}
> etc...
> }
> but it chokes on the first one, saying
> -- Parse Error: Expected 'texture identifier', colour identifier found instead
>
> so if I change the above to say "pigment { Col_Glass_Winebottle}}", it
> says:
> Parse Error: No matching } in 'triangle', pigment found instead
>
> So which is it, a texture or a pigment ? WTF?!?
> The docs use a texture statement within individual triangles, so I know
> I'm supposed to be able to treat each one separately. What obvious thing
> am I missing?
> Thanks for any help!
> Mark W.
You're trying to use color definitions as a texture identifier. Triangles
in a mesh will only take a texture. To use the pre-declare colors listed
in glass.inc you would have to use them like this -
#include "glass.inc"
mesh {
triangle {<a>, <b>, <c> texture { pigment { Col_Glass_Winebottle }}}
triangle {<c>, <d>, <e> texture { pigment { Col_Glass_Orange }}}
etc...
}
--
Ken Tyler
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Sun, 08 Sep 2002 22:53:20 -0400, Ken wrote:
Oh. Well, I had tried to do a "test run" on a square (mesh of 2
triangles) but I had assigned only one texture to the whole mesh,
like so:
mesh {
triangle {1}
triangle {2}
texture { Col_Glass_Winebottle}
}
and it worked like that! Why does it let me use a color identifier as a
texture for the whole mesh, but not for the ind. triangles? That doesn't
really make sense to me. The docs could have been a little clearer on
that point, if you ask me....
Thanks -- you've saved me >some< head-banging. ;-)
--Mark W.
>
> You're trying to use color definitions as a texture identifier.
> Triangles in a mesh will only take a texture. To use the pre-declare
> colors listed in glass.inc you would have to use them like this -
>
> #include "glass.inc"
>
> mesh {
> triangle {<a>, <b>, <c> texture { pigment { Col_Glass_Winebottle
> }}} triangle {<c>, <d>, <e> texture { pigment { Col_Glass_Orange
> }}} etc...
> }
>
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Er, never mind what I said about the docs being unclear. I just read
again the part where it says "Textures cannot be specified inside the
mesh due to thepoor memory performance that would result."
I notice it says "CANNOT", not SHOULD NOT! They really mean it!
I'll go sit quietly in my corner now...
Thanks,
Mark
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Mark M. Wilson" wrote:
>
> Er, never mind what I said about the docs being unclear. I just read
> again the part where it says "Textures cannot be specified inside the
> mesh due to thepoor memory performance that would result."
> I notice it says "CANNOT", not SHOULD NOT! They really mean it!
> I'll go sit quietly in my corner now...
Unless you have a great need to use a mesh object you can get greater
flexibility by just using a union of triangles instead of a mesh.
--
Ken Tyler
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Sun, 08 Sep 2002 22:53:20 -0400, Ken wrote:
To use the pre-declare
> colors listed in glass.inc you would have to use them like this -
>
> #include "glass.inc"
>
> mesh {
> triangle {<a>, <b>, <c> texture { pigment { Col_Glass_Winebottle
> }}} triangle {<c>, <d>, <e> texture { pigment { Col_Glass_Orange
> }}} etc...
> }
Ok, I tried this, and it didn't work either. AAARRGGH! I _really_
don't relish the idea of making extremely thin triangle-shaped prisms,
and rotating/translating them into place...
--Mark W.
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Sun, 08 Sep 2002 23:18:07 -0400, Ken wrote:
>
> Unless you have a great need to use a mesh object you can get greater
> flexibility by just using a union of triangles instead of a mesh.
>
I didn't know that triangles could be used outside the context of a
mesh.... That's why I'm posting to the newusers group! ;-)
Thanks again!
--Mark W.
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Mark M. Wilson" wrote:
> Ok, I tried this, and it didn't work either. AAARRGGH! I _really_
> don't relish the idea of making extremely thin triangle-shaped prisms,
> and rotating/translating them into place...
What it really want's is -
#include "glass.inc"
#declare T1 = texture { pigment { Col_Glass_Winebottle }}
#declare T2 = texture { pigment { Col_Glass_Orange }}
mesh {
triangle {<a>, <b>, <c> texture { T1 }}
triangle {<c>, <d>, <e> texture { T2 }}
etc...
}
--
Ken Tyler
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Sun, 08 Sep 2002 23:27:25 -0400, Ken wrote:
But you're saying, if I understand correctly, that with a union of
triangles, I can use a pigment OR a texture quite freely, yes?
--Mark
> What it really want's is -
>
> #include "glass.inc"
>
> #declare T1 = texture { pigment { Col_Glass_Winebottle }} #declare T2 =
> texture { pigment { Col_Glass_Orange }}
>
>
> mesh {
> triangle {<a>, <b>, <c> texture { T1 }} triangle {<c>, <d>, <e>
> texture { T2 }} etc...
> }
>
>
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GLS$ d+ s+: a C+ UL--- P L++ E--- W+ N+ o+ K- w--
O-- M- V-- PS+ PE Y+ PGP- t 5-- X- R- tv+ b+ DI++ D++
G e+++ h--- r+++ y+++
------END GEEK CODE BLOCK------
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Mark M. Wilson" wrote:
> I didn't know that triangles could be used outside the context of a
> mesh.... That's why I'm posting to the newusers group! ;-)
In POV-Ray v1.0 and v2.2 all triangle based objects where contained in a union.
Meshes didn't appear until POV-Ray v3.0 and the restrictions that came with them.
The real beauty of meshes are the reduced memory requirements when copies of
declared mesh objects are used. There is no real difference otherwise.
--
Ken Tyler
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |