feat: 拆分 STEP 编辑器并完善最小系统
将原来的 main.py/step_model.py 拆分为 step_editor 包,补充测量、同域高亮、模型修复、历史导出、槽宽/凸台/边长等 MVP 编辑能力,并更新 README 和忽略规则。
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from OCC.Core.GeomAbs import (
|
||||
GeomAbs_BSplineCurve,
|
||||
GeomAbs_BSplineSurface,
|
||||
GeomAbs_BezierCurve,
|
||||
GeomAbs_BezierSurface,
|
||||
GeomAbs_Circle,
|
||||
GeomAbs_Cone,
|
||||
GeomAbs_Cylinder,
|
||||
GeomAbs_Ellipse,
|
||||
GeomAbs_Hyperbola,
|
||||
GeomAbs_Line,
|
||||
GeomAbs_OffsetSurface,
|
||||
GeomAbs_OtherCurve,
|
||||
GeomAbs_OtherSurface,
|
||||
GeomAbs_Parabola,
|
||||
GeomAbs_Plane,
|
||||
GeomAbs_Sphere,
|
||||
GeomAbs_SurfaceOfExtrusion,
|
||||
GeomAbs_SurfaceOfRevolution,
|
||||
GeomAbs_Torus,
|
||||
)
|
||||
from OCC.Core.TopAbs import TopAbs_EXTERNAL, TopAbs_FORWARD, TopAbs_INTERNAL, TopAbs_REVERSED
|
||||
|
||||
|
||||
SURFACE_TYPES = {
|
||||
GeomAbs_Plane: "plane",
|
||||
GeomAbs_Cylinder: "cylinder",
|
||||
GeomAbs_Cone: "cone",
|
||||
GeomAbs_Sphere: "sphere",
|
||||
GeomAbs_Torus: "torus",
|
||||
GeomAbs_BezierSurface: "bezier surface",
|
||||
GeomAbs_BSplineSurface: "b-spline surface",
|
||||
GeomAbs_SurfaceOfRevolution: "surface of revolution",
|
||||
GeomAbs_SurfaceOfExtrusion: "surface of extrusion",
|
||||
GeomAbs_OffsetSurface: "offset surface",
|
||||
GeomAbs_OtherSurface: "other surface",
|
||||
}
|
||||
|
||||
SNAPSHOT_FACE_LOGICAL_IDS_KEY = "__face_logical_ids__"
|
||||
|
||||
CURVE_TYPES = {
|
||||
GeomAbs_Line: "line",
|
||||
GeomAbs_Circle: "circle",
|
||||
GeomAbs_Ellipse: "ellipse",
|
||||
GeomAbs_Hyperbola: "hyperbola",
|
||||
GeomAbs_Parabola: "parabola",
|
||||
GeomAbs_BezierCurve: "bezier curve",
|
||||
GeomAbs_BSplineCurve: "b-spline curve",
|
||||
GeomAbs_OtherCurve: "other curve",
|
||||
}
|
||||
|
||||
ORIENTATION_TYPES = {
|
||||
TopAbs_FORWARD: "forward",
|
||||
TopAbs_REVERSED: "reversed",
|
||||
TopAbs_INTERNAL: "internal",
|
||||
TopAbs_EXTERNAL: "external",
|
||||
}
|
||||
Reference in New Issue
Block a user