最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

python - Extract all the cells that are touching an Object in PyVista - Stack Overflow

programmeradmin1浏览0评论

I have a pv.PolyData object like this.

PolyData (0x78cbbcc6ba00)
  N Cells:    1280
  N Points:   642
  N Strips:   0
  X Bounds:   2.346e-01, 9.625e-01
  Y Bounds:   -2.296e-01, 5.064e-01
  Z Bounds:   -1.066e-02, 3.016e-01
  N Arrays:   0

And I have a pv.UnstrcutredGrid object like this.

UnstructuredGrid (0x78cbbcc6b520)
  N Cells:    60835
  N Points:   16652
  X Bounds:   -1.329e+00, 1.329e+00
  Y Bounds:   -1.329e+00, 1.329e+00
  Z Bounds:   -1.338e+00, 1.338e+00
  N Arrays:   0

I want to extract all the cells in the pv.UnstrcturedGrid object that are touching the pv.PolyData object.

One more detail, the UnstructuredGrid cells are not at all phasing thorough polydata object or clipping inside it, or glitching inside the polydata, no such things. it is only touching. I want to extract all the cells that are touching the polydata object.

The polydata object is a closed surface in every case.

How can I do it?

Thanks in advance.

发布评论

评论列表(0)

  1. 暂无评论