prakashra
prakashra

Reputation: 11

How to find out if two shape objects in PowerPoint intersect with each other?

There are multiple shapes present in a PowerPoint slide. See image below

enter image description here

As can be seen in the image, we have 3 shapes - rectangle, triangle and circle. I would like to iterate over the shapes in the slide and create a list of shapes for each shape with which it intersects. Shape intersection here refers to actual visual shape intersection and not the rectangular bounding box around those shapes.

List 1 - triangle, circle List 2 - circle, rectangle List 3 - rectangle, triangle

Is there any API to determine shape intersection? I have checked the PowerPoint add-in API, haven't found any. What approach should I follow?

Upvotes: 0

Views: 269

Answers (1)

Eugene Astafiev
Eugene Astafiev

Reputation: 49395

There is no API to determine the shape intersection. You need to use Shape's properties to find out and intersection with others. A similar questions was posted some time ago, see List of objects in front of an object in PowerPoint using VSTO for more information.

Upvotes: 0

Related Questions