POV-Ray : Newsgroups : povray.general : Feature Request - Texture Override, Help Request : Re: Feature Request - Texture Override, Help Request Server Time
21 May 2024 22:04:11 EDT (-0400)
  Re: Feature Request - Texture Override, Help Request  
From: Kyle
Date: 18 Jan 2008 00:20:56
Message: <alc0p3dimt7u0q9kt5q4hc5emibit7gg7c@4ax.com>
On Thu, 17 Jan 2008 20:29:42 EST, "SharkD" <nomail@nomail> wrote:

>I did this to illustrate the fact that, in order for the texture not to repeat
>for each section, the value for S must be passed to the texture. This is not
>possible if the declaration of the object comes before the declaration of the
>parameter, S.

Yes, I'm well aware of that.  It's one part of the problem.

>This was in response to your remark that my *earlier* suggestion would not work
>for this reason. If you combine the two methods (e.g., define an object that
>gets re-used for each section, apply a texture to each re-use of this object
>that takes into account the parameter S), it will work.

But the way your new code is written, you're basically building the entire road
brick-by-brick and
not resuing any objects.  The inner union is of no use, as is the S loop if you just
loop Z S*Z
times.

The brick-by-brick method is what I did originally, until I realize the amount of
memory that is
utilized to build a road of any lenght.  If you're curious, try building a road using
these two
methods and do a comparison of the peak memory used:

1) Build a 35x100 brick section.  Lay down 20 sections end-to-end to build the road.

2) Build a 35x2000 brick section.  That's your road.

Number two will consume allot more memory than number one for the same size road. 
Because the scene
i want to build will contain many objects in addition to this road, I have to consider
the amount of
memory that's used to avoid swapping (drive thrashing).

On the other hand, a layered texture can be used across the entire road in number two,
wheras it
cannot be in number one, providing that each brick is textured independently in both
cases.

Perhaps that better explains the problem and better defines the need for a way to
layer a texture
over a union of individually textured objects.


Post a reply to this message

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