pradeep-pyro / tinynurbs

C++ library for NURBS curves and surfaces

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TinyNURBS and IFC - CoordinateSystems

dlabz opened this issue · comments

I’ve been trying to implement IfcBsplineSurface, IfcBsplineSurfaceWithKnots and IfcRationalBSplineSurfaceWithKnots using this library in c++ / emscripten / WabAssembly and I having some issues which are probably caused by me doing something wrong.

One thing is that axes direction don’t seem to match, and I’m not sure in which space TinyNURBS operate.

X right, y up, z to viewer ?

IFC allows defining custom coords, which additionally complicates things.

On the upside, tinynurbs perfectly matches the IfcAdvancdFace use case, and seems to work quite fast, solving a decades long problem entire BIM community was facing when rendering detailed toilet bowls and doorknobs in a browser.

There’s a huge community and even some bounties involved. See https://github.com/tomvandig/web-ifc for more details.

Hi @dlabz, sorry for the delayed response. Thanks for your interest. tinynurbs doesn't have any inherent coordinate system. The only format currently supported is the Wavefront OBJ format which also doesn't define coordinate systems as far I know. So the up-direction is a convention that you have to define and perhaps use a world matrix to transform things the right way in your viewer.