Skip to content

expand mesh coercions quad-segment, etc.  #12

@mdsumner

Description

@mdsumner
quad2segment <- function(mesh) {
  ib <- mesh$ib
  allseg <- cbind(ib[1:2, ], ib[2:3, ], ib[3:4, ], ib[c(4, 1), ])
  dup <- duplicated(pmax(paste(allseg[1, ], allseg[2, ], sep = "-"), 
                         paste(allseg[2, ], allseg[1, ], sep = "-")))
  rgl::mesh3d(vertices = mesh$vb, segments = allseg[, !dup])
}

could have a kind of nascent quadmesh that started with just these segments, but would need to record the dim too

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions