【问题标题】:How to retrive the outer points from shapes or point Collection?如何从形状或点集合中检索外部点?
【发布时间】:2019-03-10 14:38:30
【问题描述】:

这里有这个积分集,

<Polyline Points="568,263,568,262,568,262,568,260,568,260,568,259,568,257,568,257,568,256,567,256,567,256,567,255,567,255,567,255,567,255,567,255,567,254,567,254,566,254,566,254,567,253,566,253,566,253,566,252,566,252,566,251,565,251,565,250,565,250,565,250,565,250,565,250,565,249,564,249,564,249,564,248,564,248" Stroke="Black" StrokeThickness="1" />
<Polyline Points="544,238,545,238,546,238,548,238,549,239,550,239,551,239,551,239,552,239,552,240,553,240,553,240,554,240,554,240,555,241,556,241,556,241,557,241,557,241,557,242,557,242,557,242,558,242,558,242,558,243,558,243,559,243,559,243,559,243,559,244,560,244,560,244,560,244,560,244,561,245,561,245,561,245,561,245,562,245,562,245,562,246,562,246" Stroke="Black" StrokeThickness="1" />
<Polyline Points="544,238,563,247,568,263,544,263,544,238,544,238" Stroke="Black" StrokeThickness="1" />
<Polyline Points="557,244,559,245,560,245,561,245,562,246,562,246,563,247,563,247,563,247,563,248,557,248,557,243,557,243" Stroke="Black" StrokeThickness="1" />
<Polyline Points="520,263,520,262,520,262,520,260,520,260,520,259,520,257,520,257,520,256,521,256,521,256,521,255,521,255,521,255,521,255,521,255,521,254,521,254,522,254,522,254,521,253,522,253,522,253,522,252,522,252,522,251,523,251,523,250,523,250,523,250,523,250,523,250,523,249,524,249,524,249,524,248,524,248" Stroke="Black" StrokeThickness="1" />
<Polyline Points="544,238,543,238,542,238,540,238,539,239,538,239,537,239,537,239,536,239,536,240,535,240,535,240,534,240,534,240,533,241,532,241,532,241,531,241,531,241,531,242,531,242,531,242,530,242,530,242,530,243,530,243,529,243,529,243,529,243,529,244,528,244,528,244,528,244,528,244,527,245,527,245,527,245,527,245,526,245,526,245,526,246,526,246" Stroke="Black" StrokeThickness="1" />
<Polyline Points="544,238,525,247,520,263,544,263,544,238,544,238" Stroke="Black" StrokeThickness="1"  />

这个点集合形成下面的形状,

我需要没有内部形状的外部点。 我需要这样的输出图像

我也尝试使用算法找到外点。

参考链接:Graham scan 但我没有得到任何人指导我的确切结果。提前致谢。

【问题讨论】:

标签: c# algorithm image-processing graphics


【解决方案1】:

这个我得到了答案。

我合并所有点并使用凸包算法,我将得到外部点。

convex hull algorithm reference Project

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-04-11
    • 1970-01-01
    • 2011-02-09
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多