POV-Ray : Newsgroups : povray.advanced-users : Directly accessing array value in array of arrays (Part 2) : Re: Directly accessing array value in array of arrays (Part 2) Server Time
23 Apr 2024 14:53:39 EDT (-0400)
  Re: Directly accessing array value in array of arrays (Part 2)  
From: jr
Date: 27 Aug 2018 07:25:00
Message: <web.5b83dee3a4088b311500b2fd0@news.povray.org>
"jr" <cre### [at] gmailcom> wrote:
> clipka <ano### [at] anonymousorg> wrote:
> > As a side note, it might be worth mentioning that `Array1[2][3]` now
> > holds a /copy/ of `Array2`, not a reference.

I love that this works too:

<----- snip ----->
#version 3.8;

global_settings {assumed_gamma 1}

#declare Aa = array[1][1][1][1][2];

#declare Ab = array[2][2][2][2][2];
#declare Ab[0][0][0][0][1] = 255;

#declare Aa[0][0][0][0][1] = Ab;

#debug concat("0 0 0 0 1 - 0 0 0 0 1 : ",
        str(Aa[0][0][0][0][1][0][0][0][0][1],0,0),
        ".\n")
<----- snip ----->

very neat.  :-)


Post a reply to this message

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