X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHexoticPlugin%2FHexoticPlugin_Hexotic.hxx;h=38284f6473632fd8187b4ae44655a2ca2c65275e;hb=959804f6a87fc6d1ed9f946988b2ae0137864c8b;hp=3c05824054bcf3a7beb243997e10e22c787604b0;hpb=f0db207a5bb09cd82192e3eca75ea12764c2ed4c;p=plugins%2Fhexoticplugin.git diff --git a/src/HexoticPlugin/HexoticPlugin_Hexotic.hxx b/src/HexoticPlugin/HexoticPlugin_Hexotic.hxx old mode 100755 new mode 100644 index 3c05824..38284f6 --- a/src/HexoticPlugin/HexoticPlugin_Hexotic.hxx +++ b/src/HexoticPlugin/HexoticPlugin_Hexotic.hxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2014 CEA/DEN, EDF R&D +// Copyright (C) 2007-2023 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -45,15 +45,15 @@ #include CORBA_CLIENT_HEADER(GEOM_Gen) #include -class SMESH_Mesh; class HexoticPlugin_Hypothesis; class TCollection_AsciiString; class gp_Pnt; +class MG_Hexotic_API; class HEXOTICPLUGIN_EXPORT HexoticPlugin_Hexotic: public SMESH_3D_Algo { public: - HexoticPlugin_Hexotic(int hypId, int studyId, SMESH_Gen* gen); + HexoticPlugin_Hexotic(int hypId, SMESH_Gen* gen); virtual ~HexoticPlugin_Hexotic(); #ifdef WITH_BLSURFPLUGIN @@ -71,8 +71,8 @@ public: virtual bool Compute(SMESH_Mesh & aMesh, SMESH_MesherHelper* aHelper); - virtual void CancelCompute(); - bool computeCanceled() { return _compute_canceled;}; + virtual void CancelCompute(); + bool computeCanceled() { return _computeCanceled; } virtual bool Evaluate(SMESH_Mesh& aMesh, const TopoDS_Shape& aShape, MapShapeNbElems& aResMap); @@ -84,70 +84,48 @@ private: std::string getHexoticCommand(const TCollection_AsciiString& Hexotic_In, const TCollection_AsciiString& Hexotic_Out, - const TCollection_AsciiString& Hexotic_Sol) const; + const TCollection_AsciiString& Hexotic_Sol, + const bool forExecutable) const; GEOM::GEOM_Object_var entryToGeomObj(std::string entry); TopoDS_Shape entryToShape(std::string entry); - std::vector writeSizeMapFile(std::string fileName); + std::vector writeSizeMapFile(MG_Hexotic_API* mgOutput, + std::string fileName); - // Functions to get sample point from shapes - void createControlPoints( const TopoDS_Shape& theShape, - const double& theSize, - std::vector< Control_Pnt >& thePoints ); - void createPointsSampleFromEdge( const TopoDS_Shape& aShape, - const double& theSize, - std::vector& thePoints ); - void createPointsSampleFromFace( const TopoDS_Shape& aShape, - const double& theSize, - std::vector& thePoints ); - void createPointsSampleFromSolid( const TopoDS_Shape& aShape, - const double& theSize, - std::vector& thePoints ); - - // Some functions for surface sampling - void subdivideTriangle( const gp_Pnt& p1, - const gp_Pnt& p2, - const gp_Pnt& p3, - const double& theSize, - std::vector& thePoints ); - - std::vector computePointsForSplitting( const gp_Pnt& p1, - const gp_Pnt& p2, - const gp_Pnt& p3 ); - gp_Pnt tangencyPoint(const gp_Pnt& p1, - const gp_Pnt& p2, - const gp_Pnt& Center); - - - int _iShape; - int _nbShape; - int _hexesMinLevel; - int _hexesMaxLevel; - double _hexesMinSize; - double _hexesMaxSize; - bool _hexoticIgnoreRidges; - bool _hexoticInvalidElements; - bool _hexoticFilesKept; - int _hexoticSharpAngleThreshold; - int _hexoticNbProc; - std::string _hexoticWorkingDirectory; - int _hexoticVerbosity; - int _hexoticMaxMemory; - int _hexoticSdMode; + int _iShape; + int _nbShape; + int _hexesMinLevel; + int _hexesMaxLevel; + double _hexesMinSize; + double _hexesMaxSize; + double _approxAngle; + bool _hexoticIgnoreRidges; + bool _hexoticInvalidElements; + bool _hexoticFilesKept; + int _hexoticSharpAngleThreshold; + int _hexoticNbProc; + std::string _hexoticWorkingDirectory; + int _hexoticVerbosity; + int _hexoticMaxMemory; + int _hexoticSdMode; + std::string _textOptions; HexoticPlugin_Hypothesis::THexoticSizeMaps _sizeMaps; - SMDS_MeshNode** _tabNode; + int _nbLayers; + double _firstLayerSize; + bool _direction; + double _growth; + std::vector _facesWithLayers; + std::vector _imprintedFaces; + SMDS_MeshNode** _tabNode; + bool _keepFiles; + bool _removeLogOnSuccess; + bool _logInStandardOutput; #ifdef WITH_BLSURFPLUGIN const BLSURFPlugin_Hypothesis* _blsurfHypo; #endif - - volatile bool _compute_canceled; - - SALOMEDS::Study_var myStudy; - SMESH_Gen_i* smeshGen_i; - }; #endif