i have a question.
I export many meshes into a stl file using AssimpWpfExporter.export.
The resulting file is composed of the same numer of meshes like original file, but i need to create a file with one mesh (the addiction of the originally meshes).
I also need to create a filled (solid) mesh suitable for 3d printing.
Someone has a solution?
I am not sure that I fully understand your question.
If you want to combine all the meshes into one mesh, then you can use the Ab3d.Utilities.MeshUtils.CombineMeshes method - it takes a collection of MeshGeometry3D objects and creates a single MeshGeometry3D object.
But if you wanted to export only one model instead of all, then you can call AddModel or AddVisual3D instead of AddViewport3D - see code from sample:
// First create an instance of AssimpWpfExporter
var assimpWpfExporter = new AssimpWpfExporter();
// We can export Model3D, Visual3D or entire Viewport3D:
I do not understand what do you mean by "I also need to create a filled (solid) mesh suitable for 3d printing.". The MeshGeometry3D object already represents a solid mesh - it is created from filled triangles. Is this not ok?
I will try your solution and i will check if the result stl will be a tiangles filled mesh..
i checked the resulting mesh.
They are not filled with triangles but they are empty inside.
This is a problem because i need to 3dprint a fully filled mesh.
anyobody can help me?
how i can fill the mesh with triangles?
Hm, what do you mean by "fill the mesh with triangles"?
The 3D graphics usually works with defining 3D positions (in WPF 3D this is defined by MeshGeometry3D.Positions collection). Then the triangles are defined by triangles indices (MeshGeometry3D.TriangleIndices) - this collection defines the indexes in the positions collection. Those triangles are then usually filled by the color in the pixel shader.
Am an not an expert for 3D printing, but I think that .stl or .obj file format with positions and triangle indices should be enough for 3D printer. Both files can be created by AssimpExporter - see Assimp / Assimp exporter sample.
OK, i will try.
Another question. AssimpWpfExporter exports stl in ascii mode and not in binary creating a very big file (50/60 Mb, instead of 6/6 Mb)
Is there a way to create stl in binary?
As it is written in the comments in the AssimpWpfExporterSample.xaml.cs and as it can be seen in the ComboBox that show all the possible export file types, you can export to .stl in ascii or binary file format. To use binary file format set FormatId to "stlb".