[vtkusers] RE Boolean Operation on two (cube) objects

Stephane PLOIX stephane.ploix at edf.fr
Thu Apr 8 05:43:34 EDT 2010


Hi Sebastian,

VTK is not a CAD tool, so you may not find exactly what you need.

The clip operation is made cell by cell.
If you have a box as input, then you have 6 cells which are the 6 faces of 
your cube. 
I think what you are looking for is an hexaedron, which is one volumic 
cubic cell.

After that, during the clip operation, the cell(s) are clipped by the 
0-level set of the field you set as input, the values being linearly 
interpolated between the vertices inside the cell.
The distance field to a cube is higly non-linear, so there is no chance 
that you will get what you are looking for.

Now you have two solutions : 
1/ dividing your input in smaller cells so that the non-linear nature of 
your clip function is not too far from the linearly interpolated one.
2/ implementing a non-linear clipping operation inside the cells.

While the second solution would be a great addition to VTK, it is also 
very difficult to implement...

Best,
Stephane




sebastian.gatzka at stud.tu-darmstadt.de 
Envoyé par : vtkusers-bounces at vtk.org
08/04/2010 11:26

A
vtkusers at vtk.org
cc

Objet
[vtkusers] Boolean Operation on two (cube) objects






Hello World.

I have finally manged to clip one cube with another.
The result is not what I have expected.
The intersecting cube clips one edge-point of the first cube and with it 
all the attached faces.
Look at the attached image to see how this looks like.

What I really wanted to realize was that the intersection is cut out and 
not to delete the whole sides.
It's hard to explain but a boolean operation like "substract" may descibe 
it the best - like the picture boolean.png in the attachement!

See you. Sebastian_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: 
http://www.vtk.org/Wiki/VTK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers




Ce message et toutes les pièces jointes (ci-après le 'Message') sont établis à l'intention exclusive des destinataires et les informations qui y figurent sont strictement confidentielles. Toute utilisation de ce Message non conforme à sa destination, toute diffusion ou toute publication totale ou partielle, est interdite sauf autorisation expresse.

Si vous n'êtes pas le destinataire de ce Message, il vous est interdit de le copier, de le faire suivre, de le divulguer ou d'en utiliser tout ou partie. Si vous avez reçu ce Message par erreur, merci de le supprimer de votre système, ainsi que toutes ses copies, et de n'en garder aucune trace sur quelque support que ce soit. Nous vous remercions également d'en avertir immédiatement l'expéditeur par retour du message.

Il est impossible de garantir que les communications par messagerie électronique arrivent en temps utile, sont sécurisées ou dénuées de toute erreur ou virus.
____________________________________________________

This message and any attachments (the 'Message') are intended solely for the addressees. The information contained in this Message is confidential. Any use of information contained in this Message not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited except formal approval.

If you are not the addressee, you may not copy, forward, disclose or use any part of it. If you have received this message in error, please delete it and all copies from your system and notify the sender immediately by return message.

E-mail communication cannot be guaranteed to be timely secure, error or virus-free.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100408/9361b261/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: clip.png
Type: application/octet-stream
Size: 28394 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100408/9361b261/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: boolean.png
Type: application/octet-stream
Size: 6261 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100408/9361b261/attachment-0001.obj>


More information about the vtkusers mailing list