POV-Ray : Newsgroups : povray.binaries.images : Hopes dashed again Server Time
18 Aug 2024 18:22:19 EDT (-0400)
  Hopes dashed again (Message 1 to 7 of 7)  
From: Bryan Valencia
Subject: Hopes dashed again
Date: 3 Apr 2001 14:53:06
Message: <3ACA1CC1.A576CCF7@209software.com>
[Image]

This is my lego planet.  It's made entirely of clear 4x2 Lego blocks.
It was to have a diameter of 500 units, but anything much over 20 and it
crashes my system.

Here's the source.

// Persistence of Vision Ray Tracer Scene Description File
// File: ClearLegoFortress.pov
// Vers: 3.1
// Desc: Clear Lego Planets
// Date: 3/28/2K1
// Auth: Bryan Valencia
//

#version unofficial MegaPov 0.6;

#include "colors.inc"

global_settings{assumed_gamma 1.0}


#include "Lego.inc"



#declare D=20; //units, not blocks

#declare A=-D;
#while (A<D)

    #declare B=-D;
    #while (B<D)
        #declare C=-D;
        #while (C<D)
            #if (sqrt((A*A)+(B*B)+(C*C))<D) object {ClearLego
translate<A,B,C>} #end
            #declare C=C+BZ;

        #end
        #declare B=B+LH;
    #end
    #declare A=A+BX;
#end


// ----------------------------------------
camera{
  location  <-D, D, -D*3>
  look_at   <0,0,0>
}


light_source{ <-90, 30, 30> color rgb<1,1,1> }

// ----------------------------------------

//This is Lego.inc
#declare LH=1.5;
#declare CT=LH+.25;
#declare Rounding=0.04;
#declare BX=2;
#declare BZ=4;

#declare Z=Rounding;
#declare FH=LH-Rounding;
#declare FX=BX-Rounding;
#declare FZ=BZ-Rounding;


#declare SubtractFrame=merge{
            cylinder{<0,0,0><BX,0,0>,Rounding}
            cylinder{<0,LH,0><BX,LH,0>,Rounding}
            cylinder{<0,0,BZ><BX,0,BZ>,Rounding}
            cylinder{<0,LH,BZ><BX,LH,BZ>,Rounding}
            cylinder{<0,0,BZ><0,LH,BZ>,Rounding}
            cylinder{<BX,0,BZ><BX,LH,BZ>,Rounding}
            cylinder{<0,0,0><0,LH,0>,Rounding}
            cylinder{<BX,0,0><BX,LH,0>,Rounding}
            cylinder{<0,0,0><0,0,BZ>,Rounding}
            cylinder{<BX,0,0><BX,0,BZ>,Rounding}
            cylinder{<0,LH,0><0,LH,BZ>,Rounding}
            cylinder{<BX,LH,0><BX,LH,BZ>,Rounding}
            sphere{<0,0,0>,Rounding}//bottom4
            sphere{<BX,0,0>,Rounding}
            sphere{<BX,0,BZ>,Rounding}
            sphere{<0,0,BZ>,Rounding}
            sphere{<0,LH,0>,Rounding}//top
            sphere{<BX,LH,0>,Rounding}
            sphere{<BX,LH,BZ>,Rounding}
            sphere{<0,LH,BZ>,Rounding}
}



#declare AddFrame=merge{
            cylinder{<Z,Z,Z><FX,Z,Z>,Rounding}
            cylinder{<Z,FH,Z><FX,FH,Z>,Rounding}
            cylinder{<Z,Z,FZ><FX,Z,FZ>,Rounding}
            cylinder{<Z,FH,FZ><FX,FH,FZ>,Rounding}
            cylinder{<Z,Z,FZ><Z,FH,FZ>,Rounding}
            cylinder{<FX,Z,FZ><FX,FH,FZ>,Rounding}
            cylinder{<Z,Z,Z><Z,FH,Z>,Rounding}
            cylinder{<FX,Z,Z><FX,FH,Z>,Rounding}
            cylinder{<Z,Z,Z><Z,Z,FZ>,Rounding}
            cylinder{<FX,Z,Z><FX,Z,FZ>,Rounding}
            cylinder{<Z,FH,Z><Z,FH,FZ>,Rounding}
            cylinder{<FX,FH,Z><FX,FH,FZ>,Rounding}
            sphere{<Z,Z,Z>,Rounding}//bottom4
            sphere{<FX,Z,Z>,Rounding}
            sphere{<FX,Z,FZ>,Rounding}
            sphere{<Z,Z,FZ>,Rounding}
            sphere{<Z,FH,Z>,Rounding}//top
            sphere{<FX,FH,Z>,Rounding}
            sphere{<FX,FH,FZ>,Rounding}
            sphere{<Z,FH,FZ>,Rounding}
}

#declare INR1=.4;

#declare InCyl=union{
    difference{
        cylinder{<0,0,0>,<0,LH-Rounding,0>,INR1}
        cylinder{<0,-Rounding,0>,<0,LH-Rounding,0>,INR1-Rounding}

    }
    torus{INR1-Rounding, Rounding}
}

#declare Lego=union{
    difference{
        box{<0,0,0><BX,1.5,BZ>}
        union{
            object{SubtractFrame}

box{<Rounding,-Rounding,Rounding><BX-Rounding,LH-.1,BZ-Rounding>}
        }
    }
    object{InCyl translate<BX/2, 0, BZ/2>}
    object{InCyl translate<BX/2, 0, BZ/2+1>}
    object{InCyl translate<BX/2, 0, BZ/2-1>}
    object{AddFrame}
    cylinder{<.5,LH,.5>  <.5,CT,.5>,.2}
    cylinder{<1.5,LH,.5> <1.5,CT,.5>,.2}
    cylinder{<.5,LH,1.5>  <.5,CT,1.5>,.2}
    cylinder{<1.5,LH,1.5> <1.5,CT,1.5>,.2}
    cylinder{<.5,LH,2.5>  <.5,CT,2.5>,.2}
    cylinder{<1.5,LH,2.5> <1.5,CT,2.5>,.2}
    cylinder{<.5,LH,3.5>  <.5,CT,3.5>,.2}
    cylinder{<1.5,LH,3.5> <1.5,CT,3.5>,.2}
}


#declare FastClear = texture{
        pigment{rgbf<1,1,1,.8>}
        finish{reflection .1 phong .2}
}

#declare LegoIOR=1.88;

#declare ClearLego=object{Lego texture{FastClear} interior{ ior LegoIOR
}}


Post a reply to this message

From: Bryan Valencia
Subject: Re: Hopes dashed again (image)
Date: 3 Apr 2001 14:54:09
Message: <3ACA1D00.9D8D3C27@209software.com>
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<body background="cid:par### [at] 209softwarecom">
<img SRC="cid:par### [at] 209softwarecom" height=120 width=160>
</body>
</html>


Post a reply to this message


Attachments:
Download 'c:\temp\nsmailm9.gif' (1 KB) Download 'c:\temp\nsmail9h.jpeg.jpg' (3 KB)

Preview of image 'c:\temp\nsmailm9.gif'
c:\temp\nsmailm9.gif

Preview of image 'c:\temp\nsmail9h.jpeg.jpg'
c:\temp\nsmail9h.jpeg.jpg


 

From: Dave Blandston
Subject: Re: Hopes dashed again
Date: 3 Apr 2001 17:06:14
Message: <3aca3b46@news.povray.org>
Yep, those exponentially huge scenes will do it every time... Something
tells me you will never see your planet rendered at 500 units!

Regards,
Dave

"Bryan Valencia" <bry### [at] 209softwarecom> wrote in message
news:3ACA1CC1.A576CCF7@209software.com...
> This is my lego planet.  It's made entirely of clear 4x2 Lego blocks.
> It was to have a diameter of 500 units, but anything much over 20 and it
> crashes my system.


Post a reply to this message

From: Bob H 
Subject: Re: Hopes dashed again
Date: 3 Apr 2001 17:19:25
Message: <3aca3e5d$1@news.povray.org>
I gave the scene a try and then put another zero onto the 20 units.  This
800MHz CPU struggled with it for 8 minutes before the memory gave out.  Has
taken another 14 minutes to free it back, at least much faster than my other
computer with 256MB and 500MHz CPU would have been.  I have 192MB on here.
I was going to ask if coincident surfaces might be the cause but now I
wonder.  Still, I'm not certain about it but even with merge wouldn't so
many coincident surfaces within a clear CSG be potential trouble?

Bob H.

"Dave Blandston" <gra### [at] earthlinknet> wrote in message
news:3aca3b46@news.povray.org...
> Yep, those exponentially huge scenes will do it every time... Something
> tells me you will never see your planet rendered at 500 units!


Post a reply to this message

From: Bryan Valencia
Subject: Re: Hopes dashed again
Date: 3 Apr 2001 17:25:08
Message: <3ACA4062.AEFFC4DD@209software.com>
I was thinking that instead of making it solid, I could make it, say 5 units
thick...  That's still a lot of legos, but maybe I could get a bigger sphere.

"Bob H." wrote:

> I gave the scene a try and then put another zero onto the 20 units.  This
> 800MHz CPU struggled with it for 8 minutes before the memory gave out.  Has
> taken another 14 minutes to free it back, at least much faster than my other
> computer with 256MB and 500MHz CPU would have been.  I have 192MB on here.
> I was going to ask if coincident surfaces might be the cause but now I
> wonder.  Still, I'm not certain about it but even with merge wouldn't so
> many coincident surfaces within a clear CSG be potential trouble?
>
> Bob H.
>
> "Dave Blandston" <gra### [at] earthlinknet> wrote in message
> news:3aca3b46@news.povray.org...
> > Yep, those exponentially huge scenes will do it every time... Something
> > tells me you will never see your planet rendered at 500 units!


Post a reply to this message

From: Dave Blandston
Subject: Re: Hopes dashed again
Date: 4 Apr 2001 14:14:13
Message: <3acb6475$1@news.povray.org>
That's just what I was about to suggest! Probably even 3-4 levels thick
would be sufficient. (While leaving the center hollow.) All those cylinders
would obscure any objects that were more than a few levels deep inside the
object anyway. That way you should be able to make it pretty big.

-Dave

"Bryan Valencia" <bry### [at] 209softwarecom> wrote in message
news:3ACA4062.AEFFC4DD@209software.com...
> I was thinking that instead of making it solid, I could make it, say 5
units
> thick...  That's still a lot of legos, but maybe I could get a bigger
sphere.
>
> "Bob H." wrote:
>
> > I gave the scene a try and then put another zero onto the 20 units.
This
> > 800MHz CPU struggled with it for 8 minutes before the memory gave out.
Has
> > taken another 14 minutes to free it back, at least much faster than my
other
> > computer with 256MB and 500MHz CPU would have been.  I have 192MB on
here.
> > I was going to ask if coincident surfaces might be the cause but now I
> > wonder.  Still, I'm not certain about it but even with merge wouldn't so
> > many coincident surfaces within a clear CSG be potential trouble?
> >
> > Bob H.
> >
> > "Dave Blandston" <gra### [at] earthlinknet> wrote in message
> > news:3aca3b46@news.povray.org...
> > > Yep, those exponentially huge scenes will do it every time...
Something
> > > tells me you will never see your planet rendered at 500 units!
>


Post a reply to this message

From: Bryan Valencia
Subject: Re: Hopes dashed again
Date: 4 Apr 2001 15:29:23
Message: <3ACB76BD.C47338E6@209software.com>
This is interesting: I put in some #render commands, and I found that my
            #declare C=C+BZ;
line NEVER gets called.


Did I screw up the #if command?


Bryan Valencia wrote:

> [Image]
>
> This is my lego planet.  It's made entirely of clear 4x2 Lego blocks.
> It was to have a diameter of 500 units, but anything much over 20 and it
> crashes my system.
>
> Here's the source.
>
> // Persistence of Vision Ray Tracer Scene Description File
> // File: ClearLegoFortress.pov
> // Vers: 3.1
> // Desc: Clear Lego Planets
> // Date: 3/28/2K1
> // Auth: Bryan Valencia
> //
>
> #version unofficial MegaPov 0.6;
>
> #include "colors.inc"
>
> global_settings{assumed_gamma 1.0}
>
> #include "Lego.inc"
>
> #declare D=20; //units, not blocks
>
> #declare A=-D;
> #while (A<D)
>
>     #declare B=-D;
>     #while (B<D)
>         #declare C=-D;
>         #while (C<D)
>             #if (sqrt((A*A)+(B*B)+(C*C))<D) object {ClearLego
> translate<A,B,C>} #end
>             #declare C=C+BZ;
>
>         #end
>         #declare B=B+LH;
>     #end
>     #declare A=A+BX;
> #end
>
> // ----------------------------------------
> camera{
>   location  <-D, D, -D*3>
>   look_at   <0,0,0>
> }
>
> light_source{ <-90, 30, 30> color rgb<1,1,1> }
>
> // ----------------------------------------
>
> //This is Lego.inc
> #declare LH=1.5;
> #declare CT=LH+.25;
> #declare Rounding=0.04;
> #declare BX=2;
> #declare BZ=4;
>
> #declare Z=Rounding;
> #declare FH=LH-Rounding;
> #declare FX=BX-Rounding;
> #declare FZ=BZ-Rounding;
>
> #declare SubtractFrame=merge{
>             cylinder{<0,0,0><BX,0,0>,Rounding}
>             cylinder{<0,LH,0><BX,LH,0>,Rounding}
>             cylinder{<0,0,BZ><BX,0,BZ>,Rounding}
>             cylinder{<0,LH,BZ><BX,LH,BZ>,Rounding}
>             cylinder{<0,0,BZ><0,LH,BZ>,Rounding}
>             cylinder{<BX,0,BZ><BX,LH,BZ>,Rounding}
>             cylinder{<0,0,0><0,LH,0>,Rounding}
>             cylinder{<BX,0,0><BX,LH,0>,Rounding}
>             cylinder{<0,0,0><0,0,BZ>,Rounding}
>             cylinder{<BX,0,0><BX,0,BZ>,Rounding}
>             cylinder{<0,LH,0><0,LH,BZ>,Rounding}
>             cylinder{<BX,LH,0><BX,LH,BZ>,Rounding}
>             sphere{<0,0,0>,Rounding}//bottom4
>             sphere{<BX,0,0>,Rounding}
>             sphere{<BX,0,BZ>,Rounding}
>             sphere{<0,0,BZ>,Rounding}
>             sphere{<0,LH,0>,Rounding}//top
>             sphere{<BX,LH,0>,Rounding}
>             sphere{<BX,LH,BZ>,Rounding}
>             sphere{<0,LH,BZ>,Rounding}
> }
>
> #declare AddFrame=merge{
>             cylinder{<Z,Z,Z><FX,Z,Z>,Rounding}
>             cylinder{<Z,FH,Z><FX,FH,Z>,Rounding}
>             cylinder{<Z,Z,FZ><FX,Z,FZ>,Rounding}
>             cylinder{<Z,FH,FZ><FX,FH,FZ>,Rounding}
>             cylinder{<Z,Z,FZ><Z,FH,FZ>,Rounding}
>             cylinder{<FX,Z,FZ><FX,FH,FZ>,Rounding}
>             cylinder{<Z,Z,Z><Z,FH,Z>,Rounding}
>             cylinder{<FX,Z,Z><FX,FH,Z>,Rounding}
>             cylinder{<Z,Z,Z><Z,Z,FZ>,Rounding}
>             cylinder{<FX,Z,Z><FX,Z,FZ>,Rounding}
>             cylinder{<Z,FH,Z><Z,FH,FZ>,Rounding}
>             cylinder{<FX,FH,Z><FX,FH,FZ>,Rounding}
>             sphere{<Z,Z,Z>,Rounding}//bottom4
>             sphere{<FX,Z,Z>,Rounding}
>             sphere{<FX,Z,FZ>,Rounding}
>             sphere{<Z,Z,FZ>,Rounding}
>             sphere{<Z,FH,Z>,Rounding}//top
>             sphere{<FX,FH,Z>,Rounding}
>             sphere{<FX,FH,FZ>,Rounding}
>             sphere{<Z,FH,FZ>,Rounding}
> }
>
> #declare INR1=.4;
>
> #declare InCyl=union{
>     difference{
>         cylinder{<0,0,0>,<0,LH-Rounding,0>,INR1}
>         cylinder{<0,-Rounding,0>,<0,LH-Rounding,0>,INR1-Rounding}
>
>     }
>     torus{INR1-Rounding, Rounding}
> }
>
> #declare Lego=union{
>     difference{
>         box{<0,0,0><BX,1.5,BZ>}
>         union{
>             object{SubtractFrame}
>
> box{<Rounding,-Rounding,Rounding><BX-Rounding,LH-.1,BZ-Rounding>}
>         }
>     }
>     object{InCyl translate<BX/2, 0, BZ/2>}
>     object{InCyl translate<BX/2, 0, BZ/2+1>}
>     object{InCyl translate<BX/2, 0, BZ/2-1>}
>     object{AddFrame}
>     cylinder{<.5,LH,.5>  <.5,CT,.5>,.2}
>     cylinder{<1.5,LH,.5> <1.5,CT,.5>,.2}
>     cylinder{<.5,LH,1.5>  <.5,CT,1.5>,.2}
>     cylinder{<1.5,LH,1.5> <1.5,CT,1.5>,.2}
>     cylinder{<.5,LH,2.5>  <.5,CT,2.5>,.2}
>     cylinder{<1.5,LH,2.5> <1.5,CT,2.5>,.2}
>     cylinder{<.5,LH,3.5>  <.5,CT,3.5>,.2}
>     cylinder{<1.5,LH,3.5> <1.5,CT,3.5>,.2}
> }
>
> #declare FastClear = texture{
>         pigment{rgbf<1,1,1,.8>}
>         finish{reflection .1 phong .2}
> }
>
> #declare LegoIOR=1.88;
>
> #declare ClearLego=object{Lego texture{FastClear} interior{ ior LegoIOR
> }}

--
Bryan Valencia
Software Development Engineer
ELOAN - A better way to get a loan.


Post a reply to this message

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