POV-Ray : Newsgroups : povray.general : possible difference bug Server Time
4 Aug 2024 14:28:28 EDT (-0400)
  possible difference bug (Message 6 to 15 of 15)  
<<< Previous 5 Messages Goto Initial 10 Messages
From: ABX
Subject: Re: possible difference bug
Date: 2 Jun 2003 10:14:31
Message: <5qmmdvsfecfc69k4feb71pv07h0qo15jpp@4ax.com>
On Mon, 2 Jun 2003 10:06:11 -0400, "Mario" <ant### [at] spamcopnet> wrote:
> No I don't   :-(

documentation: "3.3.6.1 Co-incident Surfaces"
http://www.povray.org/documentation/view/46/#s03_03_06_01

ABX


Post a reply to this message

From: Mario
Subject: Re: possible difference bug
Date: 2 Jun 2003 10:22:45
Message: <3edb5db5$1@news.povray.org>
Thanks....

I think I saw that when I started with povray, but I probably thought "I
would never use a difference. That's too advanced for me"

*sigh*


"ABX" <abx### [at] abxartpl> wrote in message
news:5qmmdvsfecfc69k4feb71pv07h0qo15jpp@4ax.com...
> On Mon, 2 Jun 2003 10:06:11 -0400, "Mario" <ant### [at] spamcopnet>
wrote:
> > No I don't   :-(
>
> documentation: "3.3.6.1 Co-incident Surfaces"
> http://www.povray.org/documentation/view/46/#s03_03_06_01
>
> ABX


Post a reply to this message

From: Mario
Subject: Re: possible difference bug
Date: 2 Jun 2003 10:34:57
Message: <3edb6091$1@news.povray.org>
I made that change, and I still don't see a hole in the first cube.

Any other suggestions?


"ABX" <abx### [at] abxartpl> wrote in message
news:l4mmdvsj3j82f1vjc3h7bd8khkg7m3eelr@4ax.com...
> On Mon, 2 Jun 2003 09:56:39 -0400, "Mario" <ant### [at] spamcopnet>
wrote:
> >    box {
> >        <-10, -1, -10>,  // Near lower left corner
> .......................
> >    box { <4,-1,-9.875>,
>
> This "-1" cause two walls on the same plane. You probably want something
like
>
>     box { <4,-1.01,-9.875>,
>
> for second box. Do you know why ?
>
> ABX


Post a reply to this message

From: ABX
Subject: Re: possible difference bug
Date: 2 Jun 2003 10:51:18
Message: <ivomdvg0pe9pfdhrp3ve9pt9leqso56jg4@4ax.com>
On Mon, 2 Jun 2003 10:34:58 -0400, "Mario" <ant### [at] spamcopnet> wrote:
> I made that change, and I still don't see a hole in the first cube.
>
> Any other suggestions?

Put your camera to look into correct wall of box. Or reorient box to show hole.

ABX


Post a reply to this message

From: Mario
Subject: Re: possible difference bug
Date: 2 Jun 2003 11:23:49
Message: <3edb6c05$1@news.povray.org>
> Put your camera to look into correct wall of box. Or reorient box to show
hole.

Below I have copied the updated scene I am using.
Now what appears to be happening is that the differnce is creating a
"tunnel" into the first cube, with the "end of the tunnel" being the same
color as the second cube. This is odd because I thought all objects were
hollow. I expected to see a rectangular hole punched into the first cube,
and being able to look inside of the first cube.



#include "textures.inc"
#include "colors.inc"

// ----------------------------------------
// ############ BEGIN #####################
// ----------------------------------------

camera {
//  location  <-6, 12, -50.05>
//  look_at   <-6, 12, -25.05>

//location <5,3,-11.05>
//look_at <5,3,-8.05>
location <5,3,-15.05>
look_at <5,3,-11.05>

  #if (frame_number < 361)
    rotate <0,360*clock,0>
  #end
}

light_source {
    <-6, 30, -60.05>
    color rgb <1, 1, 1>  // light's color
}

light_source {
    <5,3,-5.05>
    color rgb <1, 1, 1>  // light's color
}


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


// house cube
difference {
    box {
        <-10, -1, -10>,  // Near lower left corner
        <10,15,10>       // Far upper right corner

        texture {
            //MJHouse
            Red_Marble
            scale  .25
            rotate y*90
        }
    }

            // this is only done for the difference of the house cube
        // front door
        box { <4,-1.01,-10.01>, <7, 4, -9> texture { White_Marble } }


} //end of difference for the house cube


Post a reply to this message

From: ABX
Subject: Re: possible difference bug
Date: 2 Jun 2003 11:34:55
Message: <55rmdv0najiqf1qfd6mkj50sjnnl36g10t@4ax.com>
On Mon, 2 Jun 2003 11:23:50 -0400, "Mario" <ant### [at] spamcopnet> wrote:
> Now what appears to be happening is that the differnce is creating a
> "tunnel" into the first cube, with the "end of the tunnel" being the same
> color as the second cube. This is odd because I thought all objects were
> hollow. I expected to see a rectangular hole punched into the first cube,
> and being able to look inside of the first cube.

It looks like you have not enough imagination to draw this scene in your mind
and therefore you do not understand result. It works as you designed it. Take a
piece of paper and try draw by hand edges of those boxes you have in scene or
download some modeller like for example Moray and duplicate your scene to see
how those boxes are located. I can't help you because I'm not sure what you
really expect but since you are saying aboyt tunnel perhaps changing
<7, 4, -9> to <7, 16, -9> could help. Anyway try to imagine your coordinates.
I would suggest reading of http://www.povray.org/documentation/view/40/ as well.

ABX


Post a reply to this message

From: Mario
Subject: Re: possible difference bug
Date: 2 Jun 2003 12:18:44
Message: <3edb78e4$1@news.povray.org>
> It looks like you have not enough imagination to draw this scene in your
mind
> and therefore you do not understand result. It works as you designed it.
Take a
> piece of paper and try draw by hand edges of those boxes you have in scene
or
> download some modeller like for example Moray and duplicate your scene to
see
> how those boxes are located. I can't help you because I'm not sure what
you
> really expect but since you are saying aboyt tunnel perhaps changing
> <7, 4, -9> to <7, 16, -9> could help. Anyway try to imagine your
coordinates.
> I would suggest reading of http://www.povray.org/documentation/view/40/ as
well.


The example scene was something I cut out of a larger project. The end
result will be a animation sequence involving a house.

In the example scene I posted earlier, the larger cube would represent the
house, and the difference would create the hole where the front door of the
house would go.What should be left, is a big hollow cube, with a rectangular
hole punched into the site of it. According to
http://www.povray.org/documentation/view/307/ the big cube should be hollow,
and yet, after the difference it appears not to be.


Post a reply to this message

From: Manuel Kasten
Subject: Re: possible difference bug
Date: 2 Jun 2003 14:35:51
Message: <3edb9907@news.povray.org>
Hi!

> In the example scene I posted earlier, the larger cube would
> represent the house, and the difference would create the hole where
> the front door of the house would go.What should be left, is a big
> hollow cube, with a rectangular hole punched into the site of it.
> According to http://www.povray.org/documentation/view/307/ the big
> cube should be hollow, and yet, after the difference it appears not
> to be.

Look carefully at the hole section -> 6.5.6 "Constructive Solid Geometry"
http://www.povray.org/documentation/view/171/ especially at -->  6.5.6.4
"Difference".

The sample images are describing very well what's going on. If you use
difference, the surface of the differenced object will be visible inside the
object differenced from, so it will "look" solid.

If you want to cut holes into objects, so that you can see the inner
surface, use clipped_by described in ->  6.5.9.1 "Clipped_By"
http://www.povray.org/documentation/view/174/


I hope I understood correctly, what you wanted to do, let me know, if I was
able to help you.


--
MfG    Manuel Kasten


Post a reply to this message

From: Manuel Kasten
Subject: Re: possible difference bug
Date: 2 Jun 2003 14:47:31
Message: <3edb9bc3@news.povray.org>
Ohh, and if I understood correctly, what you are going to do, you should
really change the -1 here to -.999 'cause of the coincident surfaces
problem.

box { <4,-1,-9.875>, <7, 4, -10.125> }
goes
box { <4,-.999,-9.875>, <7, 4, -10.125> }


See 9.1.2.5  http://www.povray.org/documentation/view/308/


Post a reply to this message

From: Patrick Elliott
Subject: Re: possible difference bug
Date: 2 Jun 2003 18:33:34
Message: <MPG.19457e63d633cca09897ff@news.povray.org>
In article <3edb5968$1@news.povray.org>, ant### [at] spamcopnet says...
> I'd like to add I'm using povray 3.5 on a Win2000 machine.
> 
> 
> "Mario" <ant### [at] spamcopnet> wrote in message
> news:3edb5796$1@news.povray.org...
> >
> > I am doing the difference of two cubes. I expect the first cube to have a
> > hole where the second cube is. When I render the scene, the second cube is
> > visible. From what I have seen with differences, this seems like a bug.
> >
> > //scene used to create this bug:
> >
> > #include "textures.inc"
> > #include "colors.inc"
> >
> > // ----------------------------------------
> > // ############ BEGIN #####################
> > // ----------------------------------------
> >
> > camera {
> > //  location  <-6, 12, -50.05>
> > //  look_at   <-6, 12, -25.05>
> >
> > //location <5,3,-11.05>
> > //look_at <5,3,-8.05>
> > location <5,3,-0.05>
> > look_at <5,3,-11.05>
> >
> > light_source {
> >     <-6, 30, -60.05>
> >     color rgb <1, 1, 1>  // light's color
> > }
> >
> >
> > // house cube
> > difference {
> >     box {
> >         <-10, -1, -10>,  // Near lower left corner
> >         <10,15,10>       // Far upper right corner
> >
> >         texture {
> >             //MJHouse
> >             Red_Marble
> >             scale  .25
> >             rotate y*90
> >         }
> >
> >     }
> >
> >     box { <4,-1,-9.875>, <7, 4, -10.125> texture { White_Marble } }
> >
> >
> > } //end of difference
> >
> >
> >
> 
> 
> 

Umm.. It is working.. Try:

 #include "textures.inc"
 #include "colors.inc"

 // ----------------------------------------
 // ############ BEGIN #####################
 // ----------------------------------------

camera {
  location <5,3,-16.05> // **Moved camera out a little for better view.
  look_at <5,3,-8.05>
}

light_source {
    <8, 3, -20.05> // **Moved closer to get more light and place it where
                   // **it will illuminates the inside edge.
    color rgb <1, 1, 1>  // light's color
}

// house cube
difference {
    box {
        <-10, -1, -10>,  // Near lower left corner
        <10,15,10>       // Far upper right corner
        texture {
            //MJHouse
            Red_Marble
            scale  .25
            rotate y*90
        }
    }
    box { <4,-1,-9.875>, <7, 4, -10.125> texture { White_Marble } }
    rotate <0,10,0>  // **Rotated the whole thing slightly to let you see
                     // **the actual interior edge.
} //end of difference

The lines with ** I changed. The problem you are having is two fold. 
First off, you where zoomed in so close that all you could see that the 
middle of the part you cut out. Obviously this makes seeing the edges a 
bit hard. Second, the depth of the cut you are making is very shallow, so 
since you where looking straight at it, then even moving the camera 
farther back didn't show you the indention, it looked like it stuck out 
instead. And third, since you are cutting it out of a solid box, where a 
normal house would be hollow in the inside, and it was hard to see if the 
result was cut from the inside or sticking out of the cube.

Sometimes it helps a lot to change your perspective. ;) Though why ABX 
and Manual both missed this obvious way to check what it was actually 
doing.... ;) lol

-- 
void main () {

    call functional_code()
  else
    call crash_windows();
}


Post a reply to this message

<<< Previous 5 Messages Goto Initial 10 Messages

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