Salome HOME
Make filter "On line" applicable to use axis as an argument.
[modules/shaper.git] / src / FiltersPlugin / FiltersPlugin_Plugin.cpp
index a5183c5330ae0db1f166cbd7e5abb819932124c0..385ff0201e128f8b75fd09319030cdecedcf6f6f 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2019  CEA/DEN, EDF R&D
+// Copyright (C) 2014-2020  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
 #include "FiltersPlugin_Selection.h"
 #include "FiltersPlugin_HorizontalFace.h"
 #include "FiltersPlugin_VerticalFace.h"
+#include "FiltersPlugin_BelongsTo.h"
+#include "FiltersPlugin_OnPlane.h"
+#include "FiltersPlugin_OnLine.h"
+#include "FiltersPlugin_OnGeometry.h"
+#include "FiltersPlugin_OnPlaneSide.h"
+#include "FiltersPlugin_OppositeToEdge.h"
+#include "FiltersPlugin_RelativeToSolid.h"
+#include "FiltersPlugin_ExternalFaces.h"
+#include "FiltersPlugin_Validators.h"
+
+#include <Config_ModuleReader.h>
 
 #include <ModelAPI_Session.h>
-#include <ModelAPI_Filter.h>
+#include <ModelAPI_FiltersFactory.h>
 
 // the only created instance of this plugin
 static FiltersPlugin_Plugin* MY_VIEWFILTERS_INSTANCE = new FiltersPlugin_Plugin();
 
 FiltersPlugin_Plugin::FiltersPlugin_Plugin()
 {
-  // register validators
+  // register filters
   SessionPtr aMgr = ModelAPI_Session::get();
   ModelAPI_FiltersFactory* aFactory = aMgr->filters();
   aFactory->registerFilter("HorizontalFaces", new FiltersPlugin_HorizontalFace);
   aFactory->registerFilter("VerticalFaces", new FiltersPlugin_VerticalFace);
+  aFactory->registerFilter("BelongsTo", new FiltersPlugin_BelongsTo);
+  aFactory->registerFilter("OnPlane", new FiltersPlugin_OnPlane);
+  aFactory->registerFilter("OnLine", new FiltersPlugin_OnLine);
+  aFactory->registerFilter("OnGeometry", new FiltersPlugin_OnGeometry);
+  aFactory->registerFilter("OnPlaneSide", new FiltersPlugin_OnPlaneSide);
+  aFactory->registerFilter("OppositeToEdge", new FiltersPlugin_OppositeToEdge);
+  aFactory->registerFilter("RelativeToSolid", new FiltersPlugin_RelativeToSolid);
+  aFactory->registerFilter("ExternalFaces", new FiltersPlugin_ExternalFaces);
+
+  Config_ModuleReader::loadScript("FiltersPlugin_TopoConnectedFaces");
+
+  // register validators
+  ModelAPI_ValidatorsFactory* aValidators = aMgr->validators();
+  aValidators->registerValidator("FiltersPlugin_ShapeType",
+                                 new FiltersPlugin_ShapeTypeValidator);
 
   ModelAPI_Session::get()->registerPlugin(this);
 }