|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
I am trying to generate a scene where I am assign textures to a
height_field based on the height of the field. I can get this to work
fine if I define the pigment in the texture_map. However, what I want
to do is layer an image_map over the hight_field, and then set the
texture based on the height of the height_field.
Basically, the effect I'm trying to achieve is a 3D map, using an
image_map for colouration, and a height_field for 3D-ness. I want to be
able to define textures along the y-axis to make waves at the water
level, trees in the hills, rocks on peaks, etc.
I've entered the code I am using at the bottom of the message; as the
code is written it works.
However, if I remove the pigment commands, and add the following:
pigment {image_map { jpeg im_map_1 } rotate <90,0,0> scale <15,1,8.4>
translate <1,1.001,-4.2> }
it stops working; regardless of where I put the pigment (outside/inside
the texture, even individually entered into each layer of the
texture_map). When I add the line I get one of two errors:
1) "No matching } in 'texture', gradient found instead" (if "pigment" is
placed inside of texture)
2) "Cannot layer a patterned texture over another" (if "pigment" is
located outside of the texture block).
The pigment command above also works; if I put it into a texture block
that just contains pigment, finish and normals it works fine. It's only
when I try to do a texture_map that things fail.
Any ideas?
Thanx
Bryan
-----------------------------------------------------------
height_field { tiff ht_map_1 smooth scale
<15,(ht_map_1_height+0.0001),8.4> translate <1,1.001,-4.2>
texture {
gradient y
texture_map {
[0.0 pigment { color rgb <0,0,0> } finish { ambient 0.5 diffuse
0.5 } normal { leopard 1 turbulence 1.7 scale 0.05 }]
[(1/255) pigment { color rgb <0,0,1> } finish { ambient 0.5
diffuse 0.5 } normal { leopard 1 turbulence 1.7 scale 0.05 }]
[(3/255) pigment { color rgb <0,1,0> } finish { ambient 0.5
diffuse 0.5 } normal { leopard 1 turbulence 1.7 scale 0.05 }]
[1.0 pigment { color rgb <0,1,0> } finish { ambient 0.5 diffuse
0.5 } normal { leopard 1 turbulence 1.7 scale 0.05 }]
}//end texture map
}//end texture
}// end height_field
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> pigment {image_map { jpeg im_map_1 } rotate <90,0,0> scale <15,1,8.4>
> translate <1,1.001,-4.2> }
I don't think that the rotate, scale, and translate statements are legal
there. You need to find a way to transform the pigments after the
texture_map.
--
William Tracy
afi### [at] gmailcom -- wtr### [at] calpolyedu
You know you've been raytracing too long when www.povray.org is your
default homepage in your web browser.
fish-head
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
William Tracy <wtr### [at] calpolyedu> wrote:
> > pigment {image_map { jpeg im_map_1 } rotate <90,0,0> scale <15,1,8.4>
> > translate <1,1.001,-4.2> }
> I don't think that the rotate, scale, and translate statements are legal
> there.
Perhaps you should consult the documentation before making such claims.
--
- Warp
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Perhaps you should consult the documentation before making such claims.
Congratulations, you made me look at the documentation again. :-)
My initial reaction was that I didn't think you could do transforms to
textures nested within a texture_map. The docs are pretty silent on
this, but looking around it seems that pretty anything legal in a
texture outside a texture_map is legal inside a texture_map.
That, and looking at the original post again, the error looks like its
something completely different.
So, yeah, stupid me. :-P *puts dunce cap on*
--
William Tracy
afi### [at] gmailcom -- wtr### [at] calpolyedu
You know you've been raytracing too long when you're watching Bay Watch
on the telly, see Pamela A. walking by and shout out "Great bump mapping!"
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Bryan Heit" <bjh### [at] NOSPAMucalgaryca> wrote in message
news:461e998f@news.povray.org...
You need the quotes:
pigment {image_map { jpeg "im_map_1"}
~Steve~
> Bryan
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
St. wrote:
> "Bryan Heit" <bjh### [at] NOSPAMucalgaryca> wrote in message
> news:461e998f@news.povray.org...
>
> You need the quotes:
>
> pigment {image_map { jpeg "im_map_1"}
>
> ~Steve~
Sorry, im_map_1 refers to a text-string variable which already contains
the quotations. This is a macro, so pretty much all input textures and
files are defined outside of the macro (for flexibility)
Bryan
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Bryan Heit" <bjh### [at] NOSPAMucalgaryca> wrote in message
news:46236ebf$1@news.povray.org...
> St. wrote:
>> "Bryan Heit" <bjh### [at] NOSPAMucalgaryca> wrote in message
>> news:461e998f@news.povray.org...
>>
>> You need the quotes:
>>
>> pigment {image_map { jpeg "im_map_1"}
>>
>> ~Steve~
>
> Sorry, im_map_1 refers to a text-string variable which already contains
> the quotations. This is a macro, so pretty much all input textures and
> files are defined outside of the macro (for flexibility)
Gah... No, I'm sorry, I didn't realise you could do that. But, there you
go, now I've learnt something. :o)
~Steve~
>
> Bryan
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Bryan Heit wrote:
> Sorry, im_map_1 refers to a text-string variable which already contains
> the quotations. This is a macro, so pretty much all input textures and
> files are defined outside of the macro (for flexibility)
May be the problem is related to your macro. I tried applying
a texture_map to a sphere and using image_maps for pigments
without encountering any problem.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Christian Froeschlin wrote:
> Bryan Heit wrote:
>
>> Sorry, im_map_1 refers to a text-string variable which already
>> contains the quotations. This is a macro, so pretty much all input
>> textures and files are defined outside of the macro (for flexibility)
>
> May be the problem is related to your macro. I tried applying
> a texture_map to a sphere and using image_maps for pigments
> without encountering any problem.
Did you define an image_map for each pigment statement within each block
in the texture_map (this isn't clear in your response)? That works fine
for me. What is not working is defining the pigment once (i.e. placing
the image_map over the entirety of the height_map), and then defining
the finish{} and normal{} statements within the texture_map.
Bryan
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Bryan Heit wrote:
> for me. What is not working is defining the pigment once (i.e. placing
> the image_map over the entirety of the height_map), and then defining
> the finish{} and normal{} statements within the texture_map.
I don't think textures work like that. Do something along the lines of
#declare P = pigment { image_map { ... } ... }
and use pigment {P} in each individual texture map entry.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |