How to Create a Multipatch Sphere via SDK

1139
2
05-03-2021 07:21 AM
DHuantes
New Contributor III

I'm using ArcGIS Pro version 2.7.2 and the 2.7 SDK.

I've created multi-patch features programmatically and I thought it would be simple to create one from a simple shape.  Specifically a Sphere.  I've looked high and low and haven't found an example or figured out how to do this yet.  Via the Pro UI, I can add a Multipatch Feature Class and the Create options allows the interactive creation of a sphere but the MultiPatchBuilder.MakePatch is limited to esriPatchTypes... An help or examples would be greatly appreciated.  Thank you!

0 Kudos
2 Replies
NarelleChedzey
Esri Contributor

Hello

 

Attached is code for a button that creates a  multipatch sphere and adds it as a feature to a multipatch layer  (rename the attached file to MultipatchSphere.cs).  it uses the MultipatchBuilderEx builder object constructing patches of type  TriangleStrip.

Let me know if you have any questions about the code. 

 

As a result of your question, we have added additional constructors to the MultipatchBuilderEx object (and the related convenience methods) to support the creation of some basic 3d shapes.  These will include cubes, tetrahedrons, diamonds, hexagons, cylinders, spheres, sphere frames and cones and will be available in the 2.9 ArcGIS Pro release.. 

 

Regards 

Narelle

0 Kudos
NarelleChedzey
Esri Contributor

Hi, 

 

I wanted to confirm that additional constructors have been added to the MultipatchBuilderEx object at ArcGIS Pro 2.9 to add basic 3d shapes such as cubes, cones, spheres, diamonds, cylinders etc. 

 

Regards

Narelle

0 Kudos