C# 获取两个几何图形的交点大小

C# 获取两个几何图形的交点大小,c#,wpf,geometry,C#,Wpf,Geometry,我有一些时髦的xml文件,其中包含闭合的复杂2d几何形式(这些表示拥有的属性)。我想将这些xml几何体读入PathGeometry/PathFigures 如何获得这两个路径几何体之间的剖切面? 是否有办法获得切割表面的尺寸(例如,相对于其中一个几何图形的完整尺寸) 或者我应该使用其他方法而不是PathGeometry来获得横截面吗?比我想象的要简单: PathGeometry firstGeometry; PathGeometry secondGeometry; PathGeometry in

我有一些时髦的xml文件,其中包含闭合的复杂2d几何形式(这些表示拥有的属性)。我想将这些xml几何体读入PathGeometry/PathFigures

如何获得这两个路径几何体之间的剖切面?
是否有办法获得切割表面的尺寸(例如,相对于其中一个几何图形的完整尺寸)


或者我应该使用其他方法而不是PathGeometry来获得横截面吗?

比我想象的要简单:

PathGeometry firstGeometry;
PathGeometry secondGeometry;
PathGeometry intersectionGeometry = PathGeometry.Combine(firstGeometry, secondGeometry, GeometryCombineMode.Intersect, null);
可能会帮助您: