Giter VIP home page Giter VIP logo

Comments (9)

tpaviot avatar tpaviot commented on July 24, 2024 1

Class definitions are processed/written to interface file from the inheritance hierarchy. First bases classes, then classes that inherit from the previous one and so one. This is why only classes with single inheritance are taken into account.

For the BRepMesh_Delaun.hxx issue, I will manually add it to the top list of headers, it's the same for the <windows.h> header to be included in AddApp2Var see https://github.com/tpaviot/pythonocc-generator/blob/wip/occt7x-wrapper/src/generate_wrapper.py#L1951

from pythonocc-generator.

tpaviot avatar tpaviot commented on July 24, 2024

Header includes are ordered using an alphabetical sort. Just to know, which os/compiler do you use ?

from pythonocc-generator.

tpaviot avatar tpaviot commented on July 24, 2024

and what kind of error is raised by the compiler ?

from pythonocc-generator.

rainman110 avatar rainman110 commented on July 24, 2024

gcc 4.8.5. The problem is, that a header - BRepMesh_BaseMeshAlgo - uses BRepMesh_Delaun before including it. This is an OCCT issue. I get the following error:

Building CXX object CMakeFiles/_BRepMesh.dir/Unix/x86_64-Release-64/BRepMeshPYTHON_wrap.cxx.o
In file included from /localdata1/sigg_ma/src/pythonocc-core/buildocct740/Unix/x86_64-Release-64/BRepMeshPYTHON_wrap.cxx:3926:0:
/localdata1/sigg_ma/src/opencascade-7.4.0/build/install/include/opencascade/BRepMesh_CustomDelaunayBaseMeshAlgo.hxx: In member function ‘virtual void BRepMesh_CustomDelaunayBaseMeshAlgo<BaseAlgo>::postProcessMesh(BRepMesh_Delaun&)’:
/localdata1/sigg_ma/src/opencascade-7.4.0/build/install/include/opencascade/BRepMesh_CustomDelaunayBaseMeshAlgo.hxx:48:96: error: invalid use of incomplete type ‘class BRepMesh_DataStructureOfDelaun’
     std::pair<Standard_Integer, Standard_Integer> aCellsCount = this->getCellsCount (aStructure->NbNodes());
                                                                                                ^
In file included from /localdata1/sigg_ma/src/pythonocc-core/buildocct740/Unix/x86_64-Release-64/BRepMeshPYTHON_wrap.cxx:3916:0:
/localdata1/sigg_ma/src/opencascade-7.4.0/build/install/include/opencascade/BRepMesh_BaseMeshAlgo.hxx:25:7: error: forward declaration of ‘class BRepMesh_DataStructureOfDelaun’
 class BRepMesh_DataStructureOfDelaun;
       ^
In file included from /localdata1/sigg_ma/src/pythonocc-core/buildocct740/Unix/x86_64-Release-64/BRepMeshPYTHON_wrap.cxx:3926:0:
/localdata1/sigg_ma/src/opencascade-7.4.0/build/install/include/opencascade/BRepMesh_CustomDelaunayBaseMeshAlgo.hxx:49:14: error: invalid use of incomplete type ‘class BRepMesh_Delaun’
     theMesher.InitCirclesTool (aCellsCount.first, aCellsCount.second);
              ^
In file included from /localdata1/sigg_ma/src/pythonocc-core/buildocct740/Unix/x86_64-Release-64/BRepMeshPYTHON_wrap.cxx:3916:0:
/localdata1/sigg_ma/src/opencascade-7.4.0/build/install/include/opencascade/BRepMesh_BaseMeshAlgo.hxx:26:7: error: forward declaration of ‘class BRepMesh_Delaun’
 class BRepMesh_Delaun;
       ^

from pythonocc-generator.

rainman110 avatar rainman110 commented on July 24, 2024

How do you write class definitions into swig files?

Here, you also have to take care for class definition order, right? This could be used to correctly define header include order as well.

from pythonocc-generator.

tpaviot avatar tpaviot commented on July 24, 2024

Fixed by commit a5c7748

from pythonocc-generator.

rainman110 avatar rainman110 commented on July 24, 2024

The same is also required for the XBRepMesh package. It also includes BRepMesh stuff in the wrong order.

from pythonocc-generator.

tpaviot avatar tpaviot commented on July 24, 2024

so what's the correct order of headers in this package ?

from pythonocc-generator.

rainman110 avatar rainman110 commented on July 24, 2024

The same. BrepMesh_Delaun first.

from pythonocc-generator.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.