POV-Ray : Newsgroups : povray.general : Request: new simple pattern : Re: Request: new simple pattern Server Time
8 Aug 2024 20:27:05 EDT (-0400)
  Re: Request: new simple pattern  
From: Margus Ramst
Date: 12 Jan 2001 23:24:20
Message: <3A5FD8B9.9F1180B0@peak.edu.ee>
Ken wrote:
> 
> Additionally a hard coded pattern
> can be used with ease not only in pigments but also normals,
> texture maps, and pigment maps. The use of a macro complicates
> this process. Can you define a normal pattern with a macro ?
> I don't recall that being possible. Even if it is possible is
> it as easy as it is with a built in pattern ?
> 

If (as in the present case) the macro returns a function, you should be able to
use it anywhere a regular pattern keyword can be used. I.e. if the macro is
something like:

#macro MyPattern()
  function{...}
#end

then any of these should work:

pigment{MyPattern() color_map{...}}
normal{MyPattern() normal_map{...}}
density{MyPattern() density_map{...}}

etc. etc.
You don't need to know what the function itself looks like, you just need to
know the name of the macro, and the purpose of its parameters. Both of which
will presumably be well documented if the macro is part of an official
distribution.

-- 
Margus Ramst

Personal e-mail: mar### [at] peakeduee
TAG (Team Assistance Group) e-mail: mar### [at] tagpovrayorg
Home page http://www.hot.ee/margusrt


Post a reply to this message

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