POV-Ray : Newsgroups : povray.programming : RE: Re: Feature request - modification of dimensions() function. Server Time
2 May 2024 13:15:54 EDT (-0400)
  RE: Re: Feature request - modification of dimensions() function. (Message 1 to 1 of 1)  
From: Muulhed
Subject: RE: Re: Feature request - modification of dimensions() function.
Date: 14 Dec 2005 06:40:41
Message: <0512140638453@news.povray.org>
> I was wondering if any of you has ever ran into trouble trying to identify
whether a declared variable is a scalar or an array.

Well, usually when you script things yourself, you should know whats going
in and out of macros and scripts. Unless you need/want some way to have a
part of script do different things based upon float or array, I'm not sure
if the effort is actually worth it, I've never needed it. Where do you need
it? I'm curious. :-)

And you could always declare one-dimensional-arrays as well.

Regards,
Tim> 

Thanks for the reply Tim.
  I agree it is not a _needed_ thing. However, when I'm writing any code that
is intended for general use, I try to make it as robust as possible. I'm cobbling
up some mesh deformation macros that some of my co-workers want to use. 
  In the particular case I ran into, I wanted a macro that would possibly be used
in two different contexts. Since data would be in 1 of two known formats, it would be
nice to be able to automatically decide how to handle it. The data is either in an
array of floats, or floats in an 'array of arrays'.
  I took a peek at some old POV-Ray source code, but it seems like there's going to be
 a fairly steep learning curve before I could reliably start messing around in there.
I'm sure if I took the time, I could get it done. It doesn't seem to be a tough fix
to code up, if I can find the time to dig into it.

In general, I'm wondering if other folks would also find it useful to expose more
object properties.

Regards,
Mark LaBonte


Post a reply to this message

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