POV-Ray : Newsgroups : povray.advanced-users : Nested objects limitations Server Time
29 Jul 2024 16:25:03 EDT (-0400)
  Nested objects limitations (Message 1 to 10 of 23)  
Goto Latest 10 Messages Next 10 Messages >>>
From: Tim Nikias
Subject: Nested objects limitations
Date: 1 Jan 2002 11:14:13
Message: <3C31E010.3AD70CE1@gmx.de>
I was creating an animation with some hundred particles using my
particle-system, but got an "Too many nested objects"-error.
I do know the reason for this and don't want this to be taken as
bug-report or such.
I just wanted to know, how many objects may be nested, and if
this may be changed somehow (and if yes, then how). I thought
about implementing a check into the algorithm which avoids the
problem...

Thanks in advance,

Tim


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Nested objects limitations
Date: 1 Jan 2002 12:29:51
Message: <3c31f20f@news.povray.org>
In article <3C31E010.3AD70CE1@gmx.de> , Tim Nikias <Tim### [at] gmxde>  
wrote:

> I was creating an animation with some hundred particles using my
> particle-system, but got an "Too many nested objects"-error.
> I do know the reason for this and don't want this to be taken as
> bug-report or such.
> I just wanted to know, how many objects may be nested, and if
> this may be changed somehow (and if yes, then how). I thought
> about implementing a check into the algorithm which avoids the
> problem...

Without knowing your scene it is not possible to really help you.  You
probably just use some inefficient way to generate the particles in a
recursive way.  Per se there is never any need to build object "trees" in a
completely recursive way, nor would it be efficient, i.e. if you are using
unions POV-ray would ten just need time to split them or be very slow.

    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

From: Tim Nikias
Subject: Re: Nested objects limitations
Date: 1 Jan 2002 13:00:05
Message: <3C31F8DE.9D7F422C@gmx.de>
I thought the nested-objects-error was due to overlapping
media-particles (a bunch of overlapping spheres, transparent
texture, no_shadow). If the amount is just too big, it crashes.

The system does not place tons of unions, only one around all
the macro-calls required for the particles (which doesn't use
a union either).

In simplified version it's like this:

#macro Particle(Position,Parameters)
 sphere{Position, Parameter_Radius material{Parameter_Material}}
#end
#declare Objects=union{

#declare S=0; #while (S<200)
 Particle(Some_Position_near_origin,Other_Parameters)
#declare S=S+1;
#end
}

Hope this clarifies the problem a bit...

Tim


Post a reply to this message

From: Slime
Subject: Re: Nested objects limitations
Date: 1 Jan 2002 22:29:20
Message: <3c327e90$1@news.povray.org>
Are you sure you're not creating something like this at any point?

union {
object{particle}
union{
object{particle}
union {
...repeating many times...
}
}
}

I ask because it's one way some people do collision detection with objects
that have already been created, and it creates many nested objects.

- Slime
[ http://www.slimeland.com/ ]
[ http://www.slimeland.com/images/ ]


Post a reply to this message

From:
Subject: Re: Nested objects limitations
Date: 2 Jan 2002 02:17:49
Message: <cuc53uoi0nfppn8k91pdsevbjo9bdoi68t@4ax.com>
On Tue, 01 Jan 2002 18:58:54 +0100, Tim Nikias <Tim### [at] gmxde> wrote:
> If the amount is just too big, it crashes.

If there is crash then it is a bug, so try to report in proper group.

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

From: Peter Popov
Subject: Re: Nested objects limitations
Date: 2 Jan 2002 03:50:40
Message: <m8i53usojfp76gskqai3mq7511i3p0e26q@4ax.com>
On Tue, 01 Jan 2002 17:13:04 +0100, Tim Nikias <Tim### [at] gmxde>
wrote:

>I was creating an animation with some hundred particles using my
>particle-system, but got an "Too many nested objects"-error.

I know this may sound stupid but anyway... are you sure the 'union'
statement is outside the while loop?


Peter Popov ICQ : 15002700
Personal e-mail : pet### [at] vipbg
TAG      e-mail : pet### [at] tagpovrayorg


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Nested objects limitations
Date: 2 Jan 2002 07:31:42
Message: <3c32fdae@news.povray.org>

Skiba <abx### [at] babilonorg>  wrote:

>> If the amount is just too big, it crashes.
>
> If there is crash then it is a bug, so try to report in proper group.

You misunderstand his use of "crash".  in the post before he said POV-ray
shows an error message.  He and some other users call this a "crash"...

    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

From: Tim Nikias
Subject: For all those who actually answered!
Date: 2 Jan 2002 10:48:34
Message: <3C332B91.718020EB@gmx.de>
So, this is the pseudo-code:

//Macro
#macro Particle(Position)
 sphere{Position,1 hollow texture{Nice_And_Transparent}}
#end

union{
#declare C=0; #while (C < Particles)
 #declare This_Pos = Generate_Random_Position_Near_Origin
 Particle(This_Pos)
#declare C=C+1; #end
}

In effect, it should internally create something like:

union{
sphere{...}
sphere{...}
[...]
}

The actuall error-message occurs during tracing. The entire image itself
works fine, until
it reaches the particles, there it stops and aborts using the "too many
nested objects"-message.

It's not a crash (POV still works after that)
and I suppose it's not a bug (because this occurs only somewhat above
150 Particles or
such).

IMHO it has to do with several spheres overlapping, and POV-Ray can't
keep track
of it anymore (I read something like that somewhere at sometime...;)

So, I was just asking, how many objects-overlappings POV-Ray can handle.

This all DEFINITELY has NOTHING to do with UNIONs, since there is only
one
statement in the ENTIRE SCENE.

Still thanks for all the thoughts you gave, and hope, that perhaps now
someone has the answer
I'm looking for (after I've finally explained myself more precisely as I
should have in the first place).

Tim


Post a reply to this message

From: Gleb
Subject: Re: For all those who actually answered!
Date: 2 Jan 2002 14:08:42
Message: <3c335aba$1@news.povray.org>
I've found a number of 117 nested spheres with this code, which cause

the "Too many nested objects" error message. If  Particles<117, then it's OK
for spheres.

But for boxes the limit is Particles<112

//--------------------8<------------------

#declare Particles=117;
#macro Particle(Radius)
 sphere{0,Radius+1}

//box{-(Radius+1),Radius+1}
#end

union{
#declare R=0;
#while (R < Particles)
  Particle(R)
  #declare R=R+1;
#end
}
//--------------------8<------------------

atb,

gleb

"Tim Nikias" <Tim### [at] gmxde> wrote in message
news:3C332B91.718020EB@gmx.de...
>
> The actuall error-message occurs during tracing. The entire image itself
> works fine, until
> it reaches the particles, there it stops and aborts using the "too many
> nested objects"-message.
>
> and I suppose it's not a bug (because this occurs only somewhat above
> 150 Particles or
> such).
>
> IMHO it has to do with several spheres overlapping, and POV-Ray can't
> keep track
> of it anymore (I read something like that somewhere at sometime...;)
>
> So, I was just asking, how many objects-overlappings POV-Ray can handle.


Post a reply to this message

From: Ron Parker
Subject: Re: For all those who actually answered!
Date: 2 Jan 2002 15:13:08
Message: <slrna36qem.1q4.ron.parker@fwi.com>
On Wed, 2 Jan 2002 19:08:41 -0000, Gleb wrote:
> I've found a number of 117 nested spheres with this code, which cause
> 
> the "Too many nested objects" error message. If  Particles<117, then it's OK
> for spheres.
> 
> But for boxes the limit is Particles<112

It's actually 100.  It can be changed, but it'll probably still be hard-coded
to some value.  In your test code, your rays must be missing some of the 
smaller spheres and/or boxes.

-- 
plane{-z,-3normal{crackle scale.2#local a=5;#while(a)warp{repeat x flip x}rotate
z*60#local a=a-1;#end translate-9*x}pigment{rgb 1}}light_source{-9red 1rotate 60
*z}light_source{-9rgb y rotate-z*60}light_source{9-z*18rgb z}text{ttf"arial.ttf"
"RP".01,0translate-<.6,.4,.02>pigment{bozo}}light_source{-z*3rgb-.2}//Ron Parker


Post a reply to this message

Goto Latest 10 Messages Next 10 Messages >>>

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