POV-Ray : Newsgroups : povray.general : writing a texture identifier to file Server Time
18 May 2024 05:31:02 EDT (-0400)
  writing a texture identifier to file (Message 11 to 12 of 12)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Thomas de Groot
Subject: Re: writing a texture identifier to file
Date: 20 Jan 2016 02:43:34
Message: <569f3aa6@news.povray.org>
On 19-1-2016 17:40, dick balaska wrote:
> On 1/19/2016 3:13 AM, Thomas de Groot wrote:
>> I am baffled.
>
>> What to do? Thanks.
>
> I had a similar need. I ended up doing this and using the appropriate
> array as needed...
>
> #declare TexArray =
>    array[12]{
>      T_Stone1,  T_Stone2,
>      T_Stone3,  T_Stone4,
>      T_Stone5,  T_Stone6,
>      T_Stone7,  T_Stone8,
>      T_Stone9,  T_Stone10,
>      T_Stone11, T_Stone12
>    };
> #declare TexArrayText =
>    array[12]{
>      "T_Stone1",  "T_Stone2",
>      "T_Stone3",  "T_Stone4",
>      "T_Stone5",  "T_Stone6",
>      "T_Stone7",  "T_Stone8",
>      "T_Stone9",  "T_Stone10",
>      "T_Stone11", "T_Stone12"
>    };
>
Yes, it seems this is the way I shall have to go.

-- 
Thomas


Post a reply to this message

From: Christian Froeschlin
Subject: Re: writing a texture identifier to file
Date: 24 Jan 2016 18:59:27
Message: <56a5655f$1@news.povray.org>
On 20.01.2016 8:43, Thomas de Groot wrote:
> On 19-1-2016 17:40, dick balaska wrote:
>> I had a similar need. I ended up doing this and using the appropriate
>> array as needed...
>>
>> #declare TexArray =
>>    array[12]{
>>      T_Stone1,  T_Stone2,  ...
>>    };
>> #declare TexArrayText =
>>    array[12]{
>>      "T_Stone1",  "T_Stone2", ...
>>    };
>>
> Yes, it seems this is the way I shall have to go.

Note as far as I understand it you don't need to
maintain the list twice, just keep the string version
and fill the non-string version in a loop with
Parse_String as suggested by Jaime.


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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