comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: 3D triangulation of x,y,z vertices
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: 3D triangulation of x,y,z vertices [message #50452 is a reply to message #50449] Mon, 02 October 2006 01:35 Go to previous message
Dick Jackson is currently offline  Dick Jackson
Messages: 347
Registered: August 1998
Senior Member
Hi Thomas,

I think the terminology used in the docs is a bit confusing. QHull's output
"Connectivity list" *sounds* like something you'd want for Tetra_Surface's
Connin "Tetrahedral connectivity array"... but it's not. What you want to
use is QHull's output "Tr" which is a 4-by-nTetra array of indices for each
tetrahedron.

=====

PRO QHullTetra

oldverts = RandomU(seed, 3, 20)
Qhull, oldverts, tetrahedra, /delaunay
newconn=tetra_surface(oldverts, tetrahedra)
oPts = Obj_New('IDLgrPolygon', oldverts, Style=0, Thick=3)
oSurf = Obj_New('IDLgrPolygon', oldverts, Polygons=newconn, Color=[255,0,0])
XObjView, [oPts, oSurf]

END

=====

To see any points hiding inside, choose menu item View:Drag Quality:Low,
then press and drag!

In IDL, a "connectivity LIST" is a description of a general polygon mesh:
[nPts0, <set of "nPts0" indices>, nPts1, <set of "nPts1" indices>, ...]

But, as described in Tetra_Clip's doc (but not in all of the tetra-routines'
docs, alas):

=====
A tetrahedral connectivity array consists of groups of four vertex index
values. Each set of four index values specifies four vertices which define a
single tetrahedron.
=====

Hope this helps!

Cheers,
-Dick

--
Dick Jackson Software Consulting http://www.d-jackson.com
Victoria, BC, Canada +1-250-220-6117 dick@d-jackson.com


"Thomas Launey" <t_launey@brain.riken.jp> wrote in message
news:1159708839.580643.297020@h48g2000cwc.googlegroups.com.. .
> Hello,
>
> I have a 3D object defined by its surface triangles. The connectivity
> is a bit messed up with some faces normals pointing inward (toward the
> inside of the object). Since I have all the points describing the
> surface, I thougth that it would be easy to re-triangulate the x,y,x
> vertices but apparently, I am missing the obvious...
> What I did is:
> Qhull, oldverts, tetrahedra, /delaunay, connectivity=connectivity
> newconn = TETRA_SURFACE (oldvert, connectivity)
>
> It fails however because the connectivity list returned by the Delaunay
> triangulation is not recognized as a proper connectivity list for
> tetrahedra. The IDL doc actually describe the 'connectivity' returned
> by Qhull as an adjacency list. I tried to reformat it but without
> success.
> Any help or pointer would be very much appreciated .
> Thanks,
> Thomas
>
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: 4D visualization
Next Topic: subset an image by roi in idl

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sun Oct 12 00:02:58 PDT 2025

Total time taken to generate the page: 1.75980 seconds