POV-Ray : Newsgroups : povray.programming : this : Re: this Server Time
28 Jul 2024 18:18:20 EDT (-0400)
  Re: this  
From: Thorsten Froehlich
Date: 25 Jun 2002 15:38:44
Message: <3d18c6c4@news.povray.org>
In article <Xns### [at] 204213191226> , "Rafal 'Raf256' 
Maj" <raf### [at] raf256com> wrote:

>> specification of the exact scope you are working on.  But why would
>> you want to have to write "self.radius = 1" if you could just as well
>> implement it such that you can write "radius = 1"?
>
> because this is needed to pass current object (this) to other function.
> same as in C++ you would write draw(this);  and not :
> temporary_object = { ... };
> draw(temporary_object);

Not really.  As you cannot reference other objects than the current one
anyway you would not need to pass that information, it would already be
known.

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

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