![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
hello,
i made a shape with bicubic_patch and failed as i tried to difference it
from a box:
difference{
box{<0,0,0>,<1,1,1> pigment{color Green}}
object{
a_bicubic_object
}
}//difference
the result was an empty scene.
is there any way to come by this problem?
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
hi marabou,
hey! thats one i can answer! difference is a constructive
solid geometry option, and that only works with "primitive"
shapes, such as cylinders, boxes, spheres, etc. all of those
shapes except the donut (toroid) are listed in the scene
language help document in section 2.2.
good luck, miker
"marabou" <not### [at] available yet> wrote in message
news:3bfbf8ed@news.povray.org...
>
> hello,
> i made a shape with bicubic_patch and failed as i tried to difference it
> from a box:
>
> difference{
> box{<0,0,0>,<1,1,1> pigment{color Green}}
> object{
> a_bicubic_object
> }
> }//difference
>
> the result was an empty scene.
> is there any way to come by this problem?
>
>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
MR wrote:
> hi marabou,
>
> hey! thats one i can answer! difference is a constructive
> solid geometry option, and that only works with "primitive"
> shapes, such as cylinders, boxes, spheres, etc. all of those
> shapes except the donut (toroid) are listed in the scene
> language help document in section 2.2.
>
> good luck, miker
miker, i fear you are right. and this confirms my results. yes. hm. smack.
but how to come by this problem? is there another possibility?
thanks for the hint!
>
>
> "marabou" <not### [at] available yet> wrote in message
> news:3bfbf8ed@news.povray.org...
>>
>> hello,
>> i made a shape with bicubic_patch and failed as i tried to difference it
>> from a box:
>>
>> difference{
>> box{<0,0,0>,<1,1,1> pigment{color Green}}
>> object{
>> a_bicubic_object
>> }
>> }//difference
>>
>> the result was an empty scene.
>> is there any way to come by this problem?
>>
>>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
hi marabou,
i would say that the easiest option is to tug on some of the
control points of your patch to difference the box. does
that make sense?
good luck, miker
"marabou" <not### [at] available yet> wrote in message
news:3bfc0381@news.povray.org...
> MR wrote:
>
> > hi marabou,
> >
> > hey! thats one i can answer! difference is a constructive
> > solid geometry option, and that only works with "primitive"
> > shapes, such as cylinders, boxes, spheres, etc. all of those
> > shapes except the donut (toroid) are listed in the scene
> > language help document in section 2.2.
> >
> > good luck, miker
>
> miker, i fear you are right. and this confirms my results. yes. hm. smack.
> but how to come by this problem? is there another possibility?
> thanks for the hint!
>
> >
> >
> > "marabou" <not### [at] available yet> wrote in message
> > news:3bfbf8ed@news.povray.org...
> >>
> >> hello,
> >> i made a shape with bicubic_patch and failed as i tried to difference
it
> >> from a box:
> >>
> >> difference{
> >> box{<0,0,0>,<1,1,1> pigment{color Green}}
> >> object{
> >> a_bicubic_object
> >> }
> >> }//difference
> >>
> >> the result was an empty scene.
> >> is there any way to come by this problem?
> >>
> >>
>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
MR
> hi marabou,
>
> hey! thats one i can answer! difference is a constructive
> solid geometry option, and that only works with "primitive"
> shapes, such as cylinders, boxes, spheres, etc. all of those
> shapes except the donut (toroid) are listed in the scene
> language help document in section 2.2.
What do you mean with "primitive"? Difference truly works with every object
which has got a well defined "inside" and "outside". So it works fine with
planes, isosurfaces, heightfields and (with MegaPov) meshes too.
--
Jonathan.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
AFAIK, CSG calculations need to know whether a certain point is inside
a given object or not. This means that the objects participating in the CSG
construct must have well-defined inside (ie. povray can calculate if the
point is or isn't inside the object).
The insideness test is defined for most primitives (because it's so easy).
However, meshes and bicubic patches make an exception because they don't have
a well-defined inside. It's not clear how to calculate whether a point is
inside them or not in a general case.
For closed meshes a test can be done, tough, and this has been implemented
in MegaPov.
--
#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
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"marabou" <not### [at] available yet> wrote in message news:3bfbf8ed@news.povray.org...
>
> hello,
> i made a shape with bicubic_patch and failed as i tried to difference it
> from a box:
>
> difference{
> box{<0,0,0>,<1,1,1> pigment{color Green}}
> object{
> a_bicubic_object
> }
> }//difference
>
> the result was an empty scene.
> is there any way to come by this problem?
As warp explained, this won't work directly. However, heightfields _do_
difference correctly. Depending on what you want to do, this will work: render
an orthographic view of your patch object, with the cutting side pointing
towards the camera, and a black to white gradient assigned to the patch -- back
to front with respect to the camera view -- and use ambient one and no lights.
Use the resulting image as a heigtfield and difference it from the cube. In 3.5
or MegaPOV, using max_extents on your patch object can help you get the proper
scaling values for the heightfield.
Hope that helps :)
Batronyx ^"^
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |