Use OpenCascade to visualise tessellated data? (no BREP info)

Hi all,

Does anyone use this engine to visualize tessellated data models? I am working with a 3D model format that describes rendered polygon from triangulated data (no geometry or any BREP data). I need simple shading and texture rendering for my models.

I would like to use this engine as it has STEP and GLTF reader built in too. But I will need to support another third format with tessellated data only...

Is this the right tool at all for such models? Any examples out there?

Regards,
David.

Kirill Gavrilov's picture

I cannot say if it is a good idea or not, but may share a couple of thoughts:

  • Graphic engines designed for different domains has quite different features and API.
    Something that is obvious to be in graphic engine for CAD application might be missing / more difficult to implement in a game engine and vice versa.
    AIS in OCCT evaluated to solve numerous problems in various CAD/CAM/CAE applications, but used also in some simulators and similar applications.
  • Collect some list of features that you would like to have / implement in your application (and not only at first step - take a look a little bit behind the horizon),
    and make some research which must-have features could be implemented / are available in specific engine.
  • Importing not yet supported mesh file formats is possible, but may require some extra efforts.
    For instance, you may use Assimp library for reading other mesh formats in your application.
    There is some code in CADRays that could be helpful, though I would better import Assimp scene into XCAF document structure by subclassing RWMesh_CafReader, which would allow using XCAFPrs_AISObject in the same way as for glTF reader.

It is usually much simpler and faster to start development with technology that you (and your team) already used / familiar with, even if it is not superior in some aspects. The most painful decision would be changing engine in the middle of the project.