X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FBLSURFPlugin%2FBLSURFPluginBuilder.py;h=f06850f72f37704dbb05219f267b802e8d198cc3;hb=0f2aa28809d72a7bc50330357e283ffbce742b8f;hp=31f15cd5915e8bcfaf8f1339f29b1faf3f07b5ae;hpb=d025189fc9764aeebd2d8de3927ff9ca474ce0d1;p=plugins%2Fblsurfplugin.git diff --git a/src/BLSURFPlugin/BLSURFPluginBuilder.py b/src/BLSURFPlugin/BLSURFPluginBuilder.py index 31f15cd..f06850f 100644 --- a/src/BLSURFPlugin/BLSURFPluginBuilder.py +++ b/src/BLSURFPlugin/BLSURFPluginBuilder.py @@ -23,6 +23,8 @@ from salome.smesh.smesh_algorithm import Mesh_Algorithm +LIBRARY = "libBLSURFEngine.so" + # Topology treatment way of MG-CADSurf FromCAD, PreProcess, PreProcessPlus, PreCAD = 0,1,2,3 @@ -83,7 +85,7 @@ class BLSURF_Algorithm(Mesh_Algorithm): Mesh_Algorithm.__init__(self) if noBLSURFPlugin: print "Warning: BLSURFPlugin module unavailable" - self.Create(mesh, geom, BLSURF, "libBLSURFEngine.so") + self.Create(mesh, geom, BLSURF, LIBRARY) self.params=None self.geompyD = mesh.geompyD #self.SetPhysicalMesh() - PAL19680 @@ -238,6 +240,22 @@ class BLSURF_Algorithm(Mesh_Algorithm): self.SetTopology(PreCAD) self.Parameters().SetPreCADOptionValue(optionName,optionValue) pass + + ## Adds custom advanced option value. + # @param optionName custom advanced option name + # @param level custom advanced option value + def AddOption(self, optionName, level): + self.Parameters().AddOption(optionName,level) + pass + + ## Adds custom advanced PreCAD option value. + # @param optionName custom name of the option + # @param optionValue value of the option + def AddPreCADOption(self, optionName, optionValue): + if self.Parameters().GetTopology() != PreCAD: + self.SetTopology(PreCAD) + self.Parameters().AddPreCADOption(optionName,optionValue) + pass ## Sets GMF file for export at computation # @param fileName GMF file name @@ -432,7 +450,7 @@ class BLSURF_Algorithm(Mesh_Algorithm): def Parameters(self): if not self.params: self.params = self.Hypothesis("MG-CADSurf Parameters", [], - "libBLSURFEngine.so", UseExisting=0) + LIBRARY, UseExisting=0) pass return self.params