|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
I don't know whether these are bugs or not but...
1) This code won't work:
#include "functions.inc"
#declare dim = <30,15,20>
isosurface {
function {f_rounded_box (x,y,z,1,dim.x,dim.y,dim.z)}
accuracy 10^-2
max_gradient 2
contained_by {box {-dim, dim}}
pigment {rgb 1}
}
camera {location <0,100,-300> look_at 0}
light_source {<500,500,-500> rgb 1.5}
The workaround is to write as follows:
#local dimx=dim.x;
#local dimy=dim.y;
#local dimz=dim.z;
[...] function {f_rounded_box (x,y,z,1,dimx,dimy,dimz)}
2) This code won't work too:
#include "functions.inc"
#declare dim = <30,15,20>
#local dimx=dim.x;
#local dimy=dim.y;
#local dimz=dim.z;
#declare RS=seed(0);
isosurface {
function {f_rounded_box (x,y,z,1+rand(RS),dimx,dimy,dimz)}
accuracy 10^-2
max_gradient 2
contained_by {box {-dim, dim}}
pigment {rgb 1}
}
camera {location <0,100,-300> look_at 0}
light_source {<500,500,-500> rgb 1.5}
the workaround is the same:
#include "functions.inc"
#declare RS=seed(0);
#local rand_rad=rand(RS);
[...] function {f_rounded_box (x,y,z,1+rand_rad,dimx,dimy,dimz)}
Ok, what am I missing?
--
Jonathan.
Home: http://digilander.iol.it/jrgpov
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
In article <3c041e51@news.povray.org> , "JRG" <jrg### [at] hotmailcom> wrote:
>
> Ok, what am I missing?
Try to RTFM? ;-)
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
3c0429c7$1@news.povray.org...
> Try to RTFM? ;-)
Could you be more specific ? I too have fallen in this trap lately and
wasn't able to find a reference about it in the doc (see 6.1.4.3., 7.7).
G.
--
**********************
http://www.oyonale.com
**********************
- Graphic experiments
- POV-Ray and Poser computer images
- Posters
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On Wed, 28 Nov 2001 10:48:56 +0100, "Gilles Tran" <tra### [at] inapginrafr> wrote:
> Could you be more specific ? I too have fallen in this trap lately and
> wasn't able to find a reference about it in the doc (see 6.1.4.3., 7.7).
6.1.6 .
There is syntax specification in the frame.
Where is rand() function and dot operator for vectors ?
ABX
--
#declare _=function(a,b,x){((a^2)+(b^2))^.5-x}#default {pigment{color rgb 1}}
union{plane{y,-3}plane{-x,-3}finish{reflection 1 ambient 0}}isosurface{ //ABX
function{_(x-2,y,1)|_((x+y)*.7,z,.1)|_((x+y+2)*.7,z,.1)|_(x/2+y*.8+1.5,z,.1)}
contained_by{box{<0,-3,-.1>,<3,0,.1>}}translate z*15finish{ambient 1}}//POV35
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Skiba <abx### [at] babilonorg> wrote:
> On Wed, 28 Nov 2001 10:48:56 +0100, "Gilles Tran" <tra### [at] inapginrafr> wrote:
>> Could you be more specific ? I too have fallen in this trap lately and
>> wasn't able to find a reference about it in the doc (see 6.1.4.3., 7.7).
>
> 6.1.6 .
>
> There is syntax specification in the frame.
> Where is rand() function and dot operator for vectors ?
Exactly. They are listed nowhere as allowed in functions and thus cannot be
used.
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
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Thorsten Froehlich <tho### [at] trfde> wrote:
: Exactly. They are listed nowhere as allowed in functions and thus cannot be
: used.
Perhaps it would be a good idea to add a "These functions and operators
are NOT supported" to the docs?
--
#macro N(D,I)#if(I<6)cylinder{M()#local D[I]=div(D[I],104);M().5,2pigment{
rgb M()}}N(D,(D[I]>99?I:I+1))#end#end#macro M()<mod(D[I],13)-6,mod(div(D[I
],13),8)-3,10>#end blob{N(array[6]{11117333955,
7382340,3358,3900569407,970,4254934330},0)}// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
in news:3c04ce0a@news.povray.org Warp wrote:
> Perhaps it would be a good idea to add a "These functions and
> operators are NOT supported" to the docs?
documentation{ invert }
Ingo
--
Photography: http://members.home.nl/ingoogni/
Pov-Ray : http://members.home.nl/seed7/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
ingo <ing### [at] homenl> wrote:
:> Perhaps it would be a good idea to add a "These functions and
:> operators are NOT supported" to the docs?
: documentation{ invert }
What I mean is that this supported/unsupported functions/operators in
functions is a FAQ now, at beta testing stage. How much more will it be asked
when the final version has been released for some time? It's easy to cut off
all those questions by just adding a short section in the functions docs
stating which functions and operators are *not* supported.
--
#macro N(D,I)#if(I<6)cylinder{M()#local D[I]=div(D[I],104);M().5,2pigment{
rgb M()}}N(D,(D[I]>99?I:I+1))#end#end#macro M()<mod(D[I],13)-6,mod(div(D[I
],13),8)-3,10>#end blob{N(array[6]{11117333955,
7382340,3358,3900569407,970,4254934330},0)}// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
3c04d2b9@news.povray.org...
> What I mean is that this supported/unsupported functions/operators in
> functions is a FAQ now, at beta testing stage. How much more will it be
asked
> when the final version has been released for some time? It's easy to cut
off
> all those questions by just adding a short section in the functions docs
> stating which functions and operators are *not* supported.
I second that.
Not only I didn't realise that the unsupported functions were not supported
when calling a function, but I shamefully admit that I never considered the
dot operator as being a vector function...
G.
--
**********************
http://www.oyonale.com
**********************
- Graphic experiments
- POV-Ray and Poser computer images
- Posters
> --
> #macro N(D,I)#if(I<6)cylinder{M()#local D[I]=div(D[I],104);M().5,2pigment{
> rgb M()}}N(D,(D[I]>99?I:I+1))#end#end#macro M()<mod(D[I],13)-6,mod(div(D[I
> ],13),8)-3,10>#end blob{N(array[6]{11117333955,
> 7382340,3358,3900569407,970,4254934330},0)}// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On Wed, 28 Nov 2001 13:50:55 +0100, "Gilles Tran" <tra### [at] inapginrafr>
wrote:
>Not only I didn't realise that the unsupported functions were not supported
>when calling a function, but I shamefully admit that I never considered the
>dot operator as being a vector function...
That's because it's listed in the float functions. I understand it
returns a float, just as vlength, but still it seems logical to me to
have it in the vector functions, maybe in both to follow the current
logic.
Peter Popov ICQ : 15002700
Personal e-mail : pet### [at] vipbg
TAG e-mail : pet### [at] tagpovrayorg
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|