Skip to content
Discussion options

You must be logged in to vote

Ah Db.Surface VS Ge.Surface, I don’t think there’s a direct conversion. Maybe using Brep?

import traceback
from pyrx import Ap, Br, Db, Ed, Ge, Cv

def get_ge_surfaces_from_db_surface(db_surface):
    ge_surfaces = []
    brep = Br.Brep(db_surface)
    traverser = Br.FaceTraverser(brep)
    for face in traverser.getFaces():
        ge_surf = face.getSurface()
        ge_surfaces.append(ge_surf)
    return ge_surfaces

@Ap.Command()
def doit():
    try:
        ps, id, _ = Ed.Editor.entSel("\nSelect TIN: ",Cv.CvDbTinSurface.desc())
        if ps != Ed.PromptStatus.eOk:
            raise RuntimeError("Yeet! {}: ".format(ps))

        tin = Cv.CvDbTinSurface(id)
        sbmesh = tin.subDMesh(…

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by schoeller
Comment options

You must be logged in to vote
1 reply
@CEXT-Dan
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants