<div dir="ltr">That's what the vtkDataSetMapper does when it renders: if it's input is a 3D mesh, then it just renders the surface. You'd probably need to use something like vtkExtractEdges to turn it into a space-filling wireframe.<div><br></div><div>I don't do much mesh work with VTK, so hopefully someone else can chime in with different ways to render 3D meshes.</div><div><br></div><div> - David </div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 1, 2015 at 7:00 PM, vtk matt <span dir="ltr"><<a href="mailto:vtkmatt@gmail.com" target="_blank">vtkmatt@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Yeah this was my understanding. Any idea then why I only see surface triangles when I render it? I set my actor to wireframe mode and I see no internal structure. Maybe this is just a visualization thing? With the info you provided I did iterate across all cells and cast them to type vtkTetra and they all have four faces which is good. It would be great to see this visualized though as a sanity check that I do in fact have tetrahedrons. Thanks again.</div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 1, 2015 at 5:52 PM, David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">The documentation for vtkDelaunay3D says that it outputs only tetrahedrons unless you specifically set the "Alpha" value (I'm not 100% sure what "Alpha" is for, but since you aren't using it, I don't think you need to worry about it).<span><font color="#888888"><div><br></div><div> - David</div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 1, 2015 at 6:19 PM, vtk matt <span dir="ltr"><<a href="mailto:vtkmatt@gmail.com" target="_blank">vtkmatt@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi David,<div><br></div><div>Thanks for the clarification. I ran tets->GetOutput()->GetNumberOfElements(vtkDataObject::CELL) and got a value of 18 for my input which would make sense as the number of tetrahedrons. Do you know if I can expect these cells to in fact contain tetrahedrons then?</div><span><font color="#888888"><div><br></div><div>--Matt</div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, May 27, 2015 at 8:17 PM, David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Matt,<div><br></div><div>You've been misled by VTK's rather terse documentation:</div><div><br></div><div> Get the number of elements for a specific attribute type (POINT, CELL, etc.).<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">For a mesh, you can call GetNumberOfElements(vtkDataObject::POINT) or you can call GetNumberOfElements(vtkDataObject::CELL). Those are the only two choices. You can't ask for a particular type of cell, all you can do is ask it to return the total number of cells.</div><span><font color="#888888"><div class="gmail_extra"><br></div><div class="gmail_extra"> - David</div></font></span><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, May 27, 2015 at 5:41 PM, vtk matt <span dir="ltr"><<a href="mailto:vtkmatt@gmail.com" target="_blank">vtkmatt@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">Hi all,<div><br></div><div>I have spent the past few days trying to figure out how to use vtkDelaunay3D properly and decided I'd better seek out some help. My goal is relatively straight-forward: Given a set of points in 3D, generate a tetrahedral mesh, and use the results to determine which tetrahedron contains an arbitrary point.</div><div><br></div><div>In its simplest form I am doing the following:</div><div><div><br></div><div>vtkSmartPointer<vtkDelaunay3D> tets = vtkSmartPointer<vtkDelaunay3D>::New();</div><div>tets->SetInput(points);</div></div><div>tets->Update();</div><div><div>printf("Number of tets: %d\n", tets->GetOutput()->GetNumberOfElements(VTK_TETRA));<br></div></div><div><br></div><div>The output claims there are zero tetrahedrons. However if I render an actor from tets->GetOutput(), I am able to visualize a wireframe surface mesh, so I know it's doing something.</div><div><br></div><div>So I guess my questions are the following: Why does the output not contain any tetrahedrons? Why does the mesh only show surface triangles? Ultimately what is the proper way to construct a tetrahedral mesh such that I can query which tetrahedron contains an arbitrary point?</div><div><br></div><div>Thanks.</div><span><font color="#888888"><span><font color="#888888"><div><br></div><div>--Matt</div></font></span></font></span></div>
</div></div></blockquote></div><br></div></div></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>