当前位置: 首页 > wzjs >正文

什么做的网站推广营销渠道策略

什么做的网站推广,营销渠道策略,动态网站建设实训要求,做赌博网站被抓没盈利如果投影面闭合图形内有内线,生成对应面会失败导致solid生成失败 三视图dxf 生成brep 3d图重建 pythonocc solid 斜面不支持 这个投影面没什么问题,应该是图连接的问题 from collections import defaultdict from 三维投影线段寻找 import get_adjusted_…

 如果投影面闭合图形内有内线,生成对应面会失败导致solid生成失败

三视图dxf 生成brep 3d图重建 pythonocc solid

斜面不支持

这个投影面没什么问题,应该是图连接的问题

from collections import defaultdict
from 三维投影线段寻找 import get_adjusted_clusters,get_clusters,get_intersect_linesdxf_file_path = 'c.dxf'clusters=get_clusters(dxf_file_path)adjusted_clusters,yz中间面线段集,xy上下面线段集,xz左右面线段集  =get_adjusted_clusters(clusters)
intersect_lines=get_intersect_lines(xz左右面线段集,yz中间面线段集,xy上下面线段集)
intersect_lines1,intersect_lines2,intersect_lines3 = intersect_linesimport networkx as nx
from OCC.Core.BRepBuilderAPI import (BRepBuilderAPI_MakePolygon,BRepBuilderAPI_MakeFace,BRepBuilderAPI_MakeShell,BRepBuilderAPI_MakeSolid
)
from OCC.Core.BRep import BRep_Builder
from OCC.Core.TopoDS import TopoDS_Compound, TopoDS_Shellfrom OCC.Core.BRepLib import breplib_BuildCurves3d
from OCC.Core.gp import gp_Pntdef get_closed_subgraphs_in_open_faces(intersect_lines):all_polygons = []G = nx.Graph()G.add_edges_from(intersect_lines)cycles = list(nx.cycle_basis(G))for cycle in cycles:if cycle[0] != cycle[-1]:cycle.append(cycle[0])all_polygons.append(cycle)return all_polygonsdef create_face_from_polygon(points):make_polygon = BRepBuilderAPI_MakePolygon()for pt in points:make_polygon.Add(gp_Pnt(*pt))make_polygon.Close()wire = make_polygon.Wire()breplib_BuildCurves3d(wire)face = BRepBuilderAPI_MakeFace(wire).Face()return facedef create_shell_and_solid(polygons):"""输入:polygons 是所有多边形点集 [[(x, y, z), ...], ...]输出:TopoDS_Solid"""builder = BRep_Builder()shell = TopoDS_Shell()builder.MakeShell(shell)for polygon in polygons:face = create_face_from_polygon(polygon)builder.Add(shell, face)solid_builder = BRepBuilderAPI_MakeSolid(shell)solid = solid_builder.Solid()return solid# 生成所有多边形
polygons1 = get_closed_subgraphs_in_open_faces(intersect_lines1)
polygons2 = get_closed_subgraphs_in_open_faces(intersect_lines2)
polygons3 = get_closed_subgraphs_in_open_faces(intersect_lines3)
all_polygons = polygons1 + polygons2 + polygons3# 构建实体
solid = create_shell_and_solid(all_polygons)
# 显示模块
from OCC.Display.SimpleGui import init_display
display, start_display, add_menu, add_function_to_menu = init_display()
display.DisplayShape(solid, update=True)
start_display()
print("finished.")

http://www.dtcms.com/wzjs/409984.html

相关文章:

  • 介绍自己做的电影网站公司怎么推广网络营销
  • 广东省企网站建设seo排名点击 seo查询
  • 电子商务网站建设教程试卷百度竞价托管外包代运营
  • 网站建设报价网站建设报价单博客可以做seo吗
  • oa网站模板市场调研怎么写
  • 高端网络推广seo二级目录
  • 佛冈县住房和城乡建设局网站营销传播
  • 在什么网站上做兼职靠谱总排行榜总点击榜总收藏榜
  • 专注江苏网站建设锦州网站seo
  • 网站酷站谷歌google搜索引擎入口
  • 济南网站推广效果厦门网站制作全程服务
  • 网站建设工作量统计表今日重大军事新闻
  • 南京网站建设工作室能打开各种网站的浏览器下载
  • 顺德龙江网站建设天津优化公司哪家好
  • 无锡网站制作的公司有哪些sem全称
  • 济南商城网站开发google怎么推广
  • 秦皇岛做网站的公司选汉狮太原网站建设开发
  • 帝国做的电影网站活动软文怎么写
  • 做域名代理网站网站的建设流程
  • php做动漫网站怎么在广告联盟接广告
  • linux wordpress 域名杭州优化seo公司
  • 地方门户网站盈利模式杭州网站优化
  • wordpress 手机验证码seo手机端排名软件
  • 买了域名之后如何做网站河北seo网络推广
  • 网站 开发 合同宁波seo公司排名榜
  • 济南做网站费用网址提交
  • 广德做网站设计开发seo免费
  • 衡阳企业网站建设价格seocms
  • 可商用图片素材网站中国十大热门网站排名
  • 网站空间费用优化公司网站