3D object to slices like in medical scan

I am novice lacking professional terminology.

I want to create from 3D object (let's say from polygon mesh) a slice through to PNG file in order to create something like reverse medical MRI scan from which volumetric renders are created.

How it's called? It will enable me to find methods of achieving it. Bonus points for pointing to a library doing that.

• MRI produces slices from volumetric data, your surface to slice conversion will just produce a flat slice with nothing remarkable inside the boundary. Granted, you can do that - just find the intersection of a slicing plane with all of your triangles, then assemble the resulting polygon. – lightxbulb Apr 22 '19 at 10:20

Some terminology: Intersection of a polyhedron with a plane.

Wolfram Demo.

I just answered the question: How to build a 3d model from 2d pictures

and the answer is applicable here. In short, to build wiremesh from the 2d slice, you can take a look marching cube method. In this case you need to assume (or provide) the thickness of each pixel (hence a voxel) so that the MC algorithm can work. ITK/VTK should have some implementation for that.

The term could be called: 3d mesh reconstruction from volumetric data

The terminology you are looking for is "Volume Renderig"

A MRI scan scans a "volume" (object). You get a point cloude, with different density of different matter, for example skin/blood har different density. The you can use the point cloud to do volune rendering.

So what you want to do is go make your mest Into a point cloud, with density, density depending on what matter the volume contains. Then you want to har that data for volume rendering.

Then you can yourself decide how/what to render, slice through the data or whatever

A way to create the image (texture) of just a slice can be done by positioning the camera orthogonal above the slice you want to create. The second step is to add two clipping planes very close to each other slightly above and below the slice and render the geometry (mesh) into a Frame Buffer Object (FBO). From the FBO you can load the texture to CPU side and save it as PNG file.

The result you'll get is the silhouette of your 3D model of the slice. The result is of cause not perfect, because there is a small distance between the two clipping planes... But it is an very easy way to generate it.