POV-Ray : Newsgroups : povray.general : feature request (regarding &,|) Server Time
8 Aug 2024 20:22:21 EDT (-0400)
  feature request (regarding &,|) (Message 24 to 33 of 33)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Chris Huff
Subject: Re: feature request (regarding &,|)
Date: 21 Nov 2000 17:22:34
Message: <chrishuff-680BD6.17225821112000@news.povray.org>
In article <3a1a3c21@news.povray.org>, Warp <war### [at] tagpovrayorg> 
wrote:

>   Why should the user optimize by hand when povray could do it 
>   automatically?

Because it can't be done automatically without breaking certain things 
or leading to odd behavior that isn't intuitive from reading the code...


>   Avoiding a feature only because you CAN make obfuscated code with it is
> not a good principle.

I did not say that. I meant that the fact that you can make obfuscated 
code with it is not a good reason to add it. It was intended as a joke, 
because you seem to like doing that kind of thing. :-)


>   If povray can optimize the speed of the parsing, that's only a good 
>   thing.

Not if it complicates things unnecessarily. If a user puts a call to a 
macro with a side effect in the code, he will expect the macro to be 
called. Note: users are not always programmers or software designers, 
don't expect them to always avoid something that is "bad style". They 
just want things to do what they are told. The error caused when this 
optimization is done to a macro with a side effect is one that would be 
extremely difficult to track down unless you already know where to look 
for it.

-- 
Christopher James Huff
Personal: chr### [at] maccom, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tagpovrayorg, http://tag.povray.org/

<><


Post a reply to this message

From: Mark Wagner
Subject: Re: feature request (regarding &,|)
Date: 22 Nov 2000 01:07:45
Message: <3a1b62b1@news.povray.org>
Warp wrote in message <3a1a3c21@news.povray.org>...
>
>#local L=array[4800] #local Y=-2; #local I=0;
>#while(#local X=-2;
>#while(#local Zr=X; #local Zi=Y; #local N=0;
>#while(#local A=Zr*Zr; #local B=Zi*Zi;
>#local Zi=2*Zr*Zi+Y; #local Zr=A-B+X;
>#local N=N+1; N<20&A+B<2) #end
>#local L[I]=<X,N/40,Y>;
>#local X=X+.05; #local I=I+1; X<=1) #end
>#local Y=Y+.05; Y<=2) #end
>union
>{ #local I=0; #while(I<4800) sphere{L[I],.05} #local I=I+1; #end
>  pigment { rgb x } finish { specular .5 }
>}
>camera { location <-2,2,-2> look_at 0 }
>light_source { <0,20,-10>, 1 }


Nice mandelbroit.

--
Mark


Post a reply to this message

From: Pabs
Subject: Re: feature request (regarding &,|)
Date: 22 Nov 2000 01:20:48
Message: <3A1B6613.94C08E90@hotmail.com>
David Fontaine wrote:

> Ron Parker wrote:
> > #if ( a != 0 and 5/a > 2 )
> > because the parser will puke on 5/a if a really is zero.
> Hmm, didn't think of that scenario...

It is the same kind of thing as my original example.
--
Bye
Pabs


Post a reply to this message

From: Warp
Subject: Re: feature request (regarding &,|)
Date: 22 Nov 2000 08:46:46
Message: <3a1bce46@news.povray.org>
Chris Huff <chr### [at] maccom> wrote:
: Not if it complicates things unnecessarily. If a user puts a call to a 
: macro with a side effect in the code, he will expect the macro to be 
: called.

  If the user is so advanced that he knows how to make macros with side
effects and how to use them in complicated places (such as inside an
#if conditional), he has probably already very familiar with the povray
code (and he has probably read the documentation about all the commands).
  If the behaviour is clearly and well documented, it shouldn't cause
problems.

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Mark Wagner
Subject: Re: feature request (regarding &,|)
Date: 23 Nov 2000 02:56:03
Message: <3a1ccd93@news.povray.org>
Warp wrote in message <3a1bce46@news.povray.org>...
>
>  If the user is so advanced that he knows how to make macros with side
>effects and how to use them in complicated places (such as inside an
>#if conditional), he has probably already very familiar with the povray
>code (and he has probably read the documentation about all the commands).
>  If the behaviour is clearly and well documented, it shouldn't cause
>problems.


Are you offering to handle tech support for this new feature?

--
Mark
"The derivative of sin(2x) is cos(2x)"  - Matt Giwer


Post a reply to this message

From: Warp
Subject: Re: feature request (regarding &,|)
Date: 23 Nov 2000 05:25:58
Message: <3a1cf0b6@news.povray.org>
Mark Wagner <mar### [at] gtenet> wrote:
: Are you offering to handle tech support for this new feature?

  Does this mean that if someone suggests a new feature, he should also
offer tech support for that feature?
  Does it mean that if the person who has the suggestion doesn't want to
do it, he should not make the suggestion?

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Ron Parker
Subject: Re: feature request (regarding &,|)
Date: 23 Nov 2000 10:59:49
Message: <slrn91qfnm.fri.ron.parker@fwi.com>
On Thu, 23 Nov 2000 02:57:27 -0500, Mark Wagner wrote:
>Warp wrote in message <3a1bce46@news.povray.org>...
>>
>>  If the user is so advanced that he knows how to make macros with side
>>effects and how to use them in complicated places (such as inside an
>>#if conditional), he has probably already very familiar with the povray
>>code (and he has probably read the documentation about all the commands).
>>  If the behaviour is clearly and well documented, it shouldn't cause
>>problems.
>
>
>Are you offering to handle tech support for this new feature?

Isn't that why we hired him? :)

-- 
Ron Parker   http://www2.fwi.com/~parkerr/traces.html
My opinions.  Mine.  Not anyone else's.


Post a reply to this message

From: Warp
Subject: Re: feature request (regarding &,|)
Date: 23 Nov 2000 13:20:29
Message: <3a1d5fed@news.povray.org>
Ron Parker <ron### [at] povrayorg> wrote:
: Isn't that why we hired him? :)

  Well, if you put it that way... :)

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Bill DeWitt
Subject: Re: feature request (regarding &,|)
Date: 25 Nov 2000 08:19:57
Message: <3a1fbc7d@news.povray.org>
"David Fontaine" <dav### [at] faricynet> wrote :
>
> Same goes for a
> non-contigous set:
>   #if((a>0 & a<10) | a>20 | a=15)
> Imagine that coded as individual tests!

    If it were, there is a chance that I -would- be able to imagine it. As
it is, those of us who do not have a mathematical mind need to break it down
in to steps to be able to understand it at all. When I see example code like
this it takes me hours to turn it into nested statements so that I can
absorb it in bite sized chunks.

    If pov is just for programmers and mathematicians then I should just
give up now. I mean when guy like Warp...

main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/

    ...says something is "easier and more intutive", I know that I will get
lost right away. My skills are in other areas.


Post a reply to this message

From: Warp
Subject: Re: feature request (regarding &,|)
Date: 27 Nov 2000 02:51:25
Message: <3a22127d@news.povray.org>
Bill DeWitt <the### [at] earthlinknet> wrote:
: I mean when guy like Warp...
:     ...says something is "easier and more intutive", I know that I will get
: lost right away. My skills are in other areas.

  That was an insult.

  For your information, I have studied computer science (software) for 5 years
in the Tampere University of Technology. I have been working in the Software
Systems Laboratory here for more than 2 years now, programming actively.
My intention is to make my doctoral thesis here.
  I know what an easy and intuitive programming language is. I know what
good programming is. I have been preaching about modularity and high-quality
programming in this news-server so long that most people probably just hate
me for that.
  So please don't underestimate my knowledge.

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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