POV-Ray : Newsgroups : povray.general : slope with a non-constant vector : Re: slope with a non-constant vector Server Time
28 Jul 2024 22:24:02 EDT (-0400)
  Re: slope with a non-constant vector  
From: clipka
Date: 14 Dec 2013 19:51:47
Message: <52acfd23@news.povray.org>
Am 15.12.2013 00:53, schrieb David Given:
> I'm fighting textures for my planet, with a fairly small amount of
> success. The problem is that because I can't manually paint any object
> (because the entire terrain is more-or-less procedural), I have to
> somehow extract enough information from the model to texture it
> interestingly. I'm finding it all looks very samey.
>
> One tool that would be incredibly useful is slope patterns. That way I
> can have the kind of vegetation change depending on the slope, with bare
> rock on the steepest.
>
> Unfortunately, slope's direction vector appears to be a constant. And
> planets are round, which means gravity keeps changing...
>
> Is there a way around this?

There is indeed; try the following syntax:

#version 3.7;
#declare PlanetCenter=<0,0,0>;
slope {
   point_at PlanetCenter
}


Post a reply to this message

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