Posts: 12
Threads: 6
Joined: Jan 2024
Reputation:
0
How to get a mesh and get mesh points
I am trying to create a triangular mesh on the web screen using Ab3d.Reader3ds.
thank you
Posts: 731
Threads: 8
Joined: Sep 2009
Reputation:
35
Hm, what does "web screen" mean? You cannot use Ab3d.Reader3ds in a web application because Ab3d.Reader3ds requires WPF.
But you can get the meshes of the read objects in a WPF application and with Ab3d.Reader3ds in the following way:
- the ReadFile method returns a ModelGroup3D object
- go through each child object in ModelGroup3D.Children collection
- if the child object is ModelGroup3D, then go through its Children...
- if the child object is GeometryModel3D than cast its Geometry to MeshGeometry3D. There you will have Positions, Normals, TextureCoordinates and TriangleIndices collections.
Andrej Benedik