POV-Ray : Newsgroups : povray.general : The Language of POV-Ray : Re: The Language of POV-Ray Server Time
11 Aug 2024 01:24:51 EDT (-0400)
  Re: The Language of POV-Ray  
From: Chris Huff
Date: 11 Mar 2000 10:19:42
Message: <chrishuff_99-B1BF65.10213111032000@news.povray.org>
In article <38CA3F4E.54F5C535@inapg.inra.fr>, Gilles Tran 
<tra### [at] inapginrafr> wrote:

> My own ventures in OO programming and other advanced programming 
> indicate that, though there's no discussion on the necessity of it 
> when it comes to programming efficiency, it also requires a *much 
> higher* level of abstract thinking. This may be natural to full-time 
> programmers, but for many people (including me) these ways of 
> thinking are extraordinary hard, if not impossible, to grasp. Many of 
> the concepts discussed in this thread (or in the programmers' wish 
> lists) are simply out of my intellectual reach.

I think you are getting scared off by the "inheritance" features of most 
object-oriented languages. They are the main source of complexity in 
programming languages, and I don't think they would be necessary or 
useful in POV. What I am talking about(and what I think most other 
people who want OO features are talking about) is adding the ability to 
bind macros and variables to objects, and access the attributes of the 
object. Which seems more intuitive:
#declare MyObject = object {MyObject translate y*3}
or
MyObject.Move(y*3);

You could have a separate Move() macro for a specific object which would 
do things like change the color depending on the distance moved. (like 
in steam dispersing or fire turning into smoke) The code would be much 
less complex, and easier to understand. Copies of the object would have 
the same macros and copies of the variables, but that would be the only 
inheritance-like feature, and is not difficult to understand.

-- 
Chris Huff
e-mail: chr### [at] yahoocom
Web page: http://chrishuff.dhs.org/


Post a reply to this message

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