1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0024002: Overall code and build procedure refactoring -- automatic

Automatic upgrade of OCCT code by command "occt_upgrade . -nocdl":
- WOK-generated header files from inc and sources from drv are moved to src
- CDL files removed
- All packages are converted to nocdlpack
This commit is contained in:
abv
2015-07-12 07:42:38 +03:00
parent 543a996496
commit 42cf5bc1ca
15354 changed files with 623957 additions and 509844 deletions

7
src/ShapeAlgo/FILES Normal file
View File

@@ -0,0 +1,7 @@
ShapeAlgo.cxx
ShapeAlgo.hxx
ShapeAlgo_AlgoContainer.cxx
ShapeAlgo_AlgoContainer.hxx
ShapeAlgo_AlgoContainer.lxx
ShapeAlgo_ToolContainer.cxx
ShapeAlgo_ToolContainer.hxx

View File

@@ -1,49 +0,0 @@
-- Created on: 2000-02-07
-- Created by: data exchange team
-- Copyright (c) 2000-2014 OPEN CASCADE SAS
--
-- This file is part of Open CASCADE Technology software library.
--
-- This library is free software; you can redistribute it and/or modify it under
-- the terms of the GNU Lesser General Public License version 2.1 as published
-- by the Free Software Foundation, with special exception defined in the file
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
-- distribution for complete text of the license and disclaimer of any warranty.
--
-- Alternatively, this file may be used under the terms of Open CASCADE
-- commercial license or contractual agreement.
package ShapeAlgo
---Purpose:
uses
MMgt,
Geom,
Geom2d,
TColGeom,
TColGeom2d,
TopoDS,
ShapeExtend,
ShapeAnalysis,
ShapeFix,
GeomAbs
is
class ToolContainer;
class AlgoContainer;
---Purpose: Provides initerface to the algorithms from Shape Healing.
Init;
---Purpose: Creates and initializes default AlgoContainer.
SetAlgoContainer (aContainer: AlgoContainer from ShapeAlgo);
---Purpose: Sets default AlgoContainer
AlgoContainer returns AlgoContainer from ShapeAlgo;
---Purpose: Returns default AlgoContainer
end ShapeAlgo;

View File

@@ -13,7 +13,9 @@
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#include <ShapeAlgo.ixx>
#include <ShapeAlgo.hxx>
#include <ShapeAlgo_AlgoContainer.hxx>
#include <ShapeExtend.hxx>
static Handle(ShapeAlgo_AlgoContainer) theContainer;

View File

@@ -0,0 +1,71 @@
// Created on: 2000-02-07
// Created by: data exchange team
// Copyright (c) 2000-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 as published
// by the Free Software Foundation, with special exception defined in the file
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
// distribution for complete text of the license and disclaimer of any warranty.
//
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#ifndef _ShapeAlgo_HeaderFile
#define _ShapeAlgo_HeaderFile
#include <Standard.hxx>
#include <Standard_DefineAlloc.hxx>
#include <Standard_Handle.hxx>
class ShapeAlgo_AlgoContainer;
class ShapeAlgo_ToolContainer;
class ShapeAlgo_AlgoContainer;
class ShapeAlgo
{
public:
DEFINE_STANDARD_ALLOC
//! Provides initerface to the algorithms from Shape Healing.
//! Creates and initializes default AlgoContainer.
Standard_EXPORT static void Init();
//! Sets default AlgoContainer
Standard_EXPORT static void SetAlgoContainer (const Handle(ShapeAlgo_AlgoContainer)& aContainer);
//! Returns default AlgoContainer
Standard_EXPORT static Handle(ShapeAlgo_AlgoContainer) AlgoContainer();
protected:
private:
friend class ShapeAlgo_ToolContainer;
friend class ShapeAlgo_AlgoContainer;
};
#endif // _ShapeAlgo_HeaderFile

View File

@@ -1,142 +0,0 @@
-- Created on: 2000-02-07
-- Created by: data exchange team
-- Copyright (c) 2000-2014 OPEN CASCADE SAS
--
-- This file is part of Open CASCADE Technology software library.
--
-- This library is free software; you can redistribute it and/or modify it under
-- the terms of the GNU Lesser General Public License version 2.1 as published
-- by the Free Software Foundation, with special exception defined in the file
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
-- distribution for complete text of the license and disclaimer of any warranty.
--
-- Alternatively, this file may be used under the terms of Open CASCADE
-- commercial license or contractual agreement.
class AlgoContainer from ShapeAlgo inherits TShared from MMgt
---Purpose:
uses
Curve from Geom2d,
BSplineCurve from Geom2d,
BSplineCurve from Geom,
BSplineSurface from Geom,
Surface from Geom,
SequenceOfCurve from TColGeom,
HSequenceOfBoundedCurve from TColGeom,
SequenceOfCurve from TColGeom2d,
HSequenceOfBoundedCurve from TColGeom2d,
Shape from TopoDS,
Edge from TopoDS,
Wire from TopoDS,
Face from TopoDS,
ToolContainer from ShapeAlgo,
WireData from ShapeExtend,
Wire from ShapeAnalysis,
Curve from Geom,
Shape from GeomAbs
is
Create returns AlgoContainer from ShapeAlgo;
---Purpose: Empty constructor
SetToolContainer (me: mutable; TC: ToolContainer from ShapeAlgo);
---C++ : inline
---Purpose: Sets ToolContainer
ToolContainer (me) returns ToolContainer from ShapeAlgo;
---C++ : inline
---Purpose: Returns ToolContainer
--- Algorithms
ConnectNextWire (me; saw : Wire from ShapeAnalysis;
nextsewd : WireData from ShapeExtend;
maxtol : Real;
distmin : out Real;
revsewd : out Boolean;
revnextsewd: out Boolean)
returns Boolean is virtual;
---Purpose: Finds the best way to connect and connects <nextsewd> to already
-- built <sewd> (in <saw>).
-- Returns False if <nextsewd> cannot be connected, otherwise - True.
-- <maxtol> specifies the maximum tolerance with which <nextsewd> can
-- be added.
-- <distmin> is used to receive the minimum distance between <nextsewd>
-- and <sewd>.
-- <revsewd> is True if <sewd> has been reversed before connecting.
-- <revnextwd> is True if <nextsewd> has been reversed before connecting.
-- Uses functionality of ShapeAnalysis_Wire.
ApproxBSplineCurve (me; bspline: BSplineCurve from Geom; seq: out SequenceOfCurve from TColGeom)
is virtual;
---Purpose:
ApproxBSplineCurve (me; bspline: BSplineCurve from Geom2d; seq: out SequenceOfCurve from TColGeom2d)
is virtual;
---Purpose:
C0BSplineToSequenceOfC1BSplineCurve (me; BS : BSplineCurve from Geom;
seqBS: out HSequenceOfBoundedCurve from TColGeom)
returns Boolean is virtual;
C0BSplineToSequenceOfC1BSplineCurve (me; BS : BSplineCurve from Geom2d;
seqBS: out HSequenceOfBoundedCurve from TColGeom2d)
returns Boolean is virtual;
---Purpose: Converts C0 B-Spline curve into sequence of C1 B-Spline curves.
-- Calls ShapeUpgrade::C0BSplineToSequenceOfC1BSplineCurve.
C0ShapeToC1Shape (me; shape: Shape from TopoDS; tol: Real)
returns Shape from TopoDS is virtual;
---Purpose: Converts a shape on C0 geometry into the shape on C1 geometry.
---Remark : Uses ShapeUpgrade_ShapeDivide.
ConvertSurfaceToBSpline(me; surf : Surface from Geom;
UF,UL,VF,VL: Real)
returns BSplineSurface from Geom is virtual;
---Purpose: Converts a surface to B-Spline.
-- Uses ShapeConstruct.
HomoWires (me; wireIn1 : Wire from TopoDS;
wireIn2 : Wire from TopoDS;
wireOut1: out Wire from TopoDS;
wireOut2: out Wire from TopoDS;
byParam : Boolean from Standard)
returns Boolean is virtual;
---Purpose: Return 2 wires with the same number of edges. The both Edges
-- number i of these wires have got the same ratio between
-- theirs parameter lengths and their wire parameter lengths.
OuterWire (me; face: Face from TopoDS) returns Wire from TopoDS is virtual;
---Purpose: Returns the outer wire on the face <Face>.
ConvertToPeriodic (me; surf: Surface from Geom)
returns Surface from Geom is virtual;
---Purpose: Converts surface to periodic form.
-- Calls ShapeCustom_Surface.
GetFaceUVBounds (me; F: Face from TopoDS; Umin, Umax, Vmin, Vmax: out Real)
is virtual;
---Purpose: Computes exact UV bounds of all wires on the face
---Remark : Calls ShapeAnalysis::GetFaceUVBounds.
ConvertCurveToBSpline(me;C3D : Curve from Geom;
First : Real;
Last : Real;
Tol3d : Real;
Continuity : Shape from GeomAbs;
MaxSegments: Integer;
MaxDegree : Integer)
returns BSplineCurve from Geom is virtual;
---Purpose: Convert Geom_Curve to Geom_BSplineCurve
---Remark : Calls ShapeConstruct::CurveCurveToBSplineCurve.
fields
myTC : ToolContainer from ShapeAlgo;
end AlgoContainer;

View File

@@ -13,55 +13,55 @@
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#include <ShapeAlgo_AlgoContainer.ixx>
#include <GeomInt_WLApprox.hxx>
#include <IntSurf_LineOn2S.hxx>
#include <IntSurf_PntOn2S.hxx>
#include <IntPatch_WLine.hxx>
#include <BRep_Builder.hxx>
#include <BRep_Tool.hxx>
#include <BRepBuilderAPI_MakeEdge.hxx>
#include <BRepBuilderAPI_MakeWire.hxx>
#include <TopoDS.hxx>
#include <TopoDS_Edge.hxx>
#include <TopoDS_Wire.hxx>
#include <TopoDS_Iterator.hxx>
#include <TopExp.hxx>
#include <BRepTools.hxx>
#include <Geom2d_BSplineCurve.hxx>
#include <Geom_BSplineCurve.hxx>
#include <Geom_BSplineSurface.hxx>
#include <Geom_Curve.hxx>
#include <Geom_Surface.hxx>
#include <GeomInt_WLApprox.hxx>
#include <gp_Pnt.hxx>
#include <IntPatch_WLine.hxx>
#include <IntSurf_LineOn2S.hxx>
#include <IntSurf_PntOn2S.hxx>
#include <Precision.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TColStd_Array1OfInteger.hxx>
#include <TColgp_Array1OfPnt.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
#include <ShapeAlgo_AlgoContainer.hxx>
#include <ShapeAlgo_ToolContainer.hxx>
#include <ShapeAnalysis.hxx>
#include <ShapeAnalysis_Edge.hxx>
#include <ShapeAnalysis_Wire.hxx>
#include <ShapeBuild_Edge.hxx>
#include <ShapeConstruct.hxx>
#include <ShapeCustom.hxx>
#include <ShapeCustom_Surface.hxx>
#include <ShapeAnalysis.hxx>
#include <ShapeAnalysis_Edge.hxx>
#include <ShapeExtend_WireData.hxx>
#include <ShapeFix.hxx>
#include <ShapeFix_Edge.hxx>
#include <ShapeFix_Wire.hxx>
#include <ShapeUpgrade.hxx>
#include <ShapeUpgrade_ShapeDivideContinuity.hxx>
#include <ShapeExtend_WireData.hxx>
#include <ShapeExtend_WireData.hxx>
#include <Standard_Type.hxx>
#include <TColgp_Array1OfPnt.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
#include <TColStd_Array1OfInteger.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TopExp.hxx>
#include <gp_Pnt.hxx>
#include <Precision.hxx>
#include <ShapeFix_Wire.hxx>
#include <BRepTools.hxx>
#include <Geom_BSplineCurve.hxx>
#include <Geom2d_BSplineCurve.hxx>
#include <TopoDS.hxx>
#include <TopoDS_Edge.hxx>
#include <TopoDS_Face.hxx>
#include <TopoDS_Iterator.hxx>
#include <TopoDS_Shape.hxx>
#include <TopoDS_Wire.hxx>
//=======================================================================
//function : ShapeAlgo_AlgoContainer
//purpose :
//=======================================================================
ShapeAlgo_AlgoContainer::ShapeAlgo_AlgoContainer()
{
myTC = new ShapeAlgo_ToolContainer;

View File

@@ -0,0 +1,135 @@
// Created on: 2000-02-07
// Created by: data exchange team
// Copyright (c) 2000-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 as published
// by the Free Software Foundation, with special exception defined in the file
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
// distribution for complete text of the license and disclaimer of any warranty.
//
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#ifndef _ShapeAlgo_AlgoContainer_HeaderFile
#define _ShapeAlgo_AlgoContainer_HeaderFile
#include <Standard.hxx>
#include <Standard_Type.hxx>
#include <MMgt_TShared.hxx>
#include <Standard_Boolean.hxx>
#include <Standard_Real.hxx>
#include <TColGeom_SequenceOfCurve.hxx>
#include <TColGeom2d_SequenceOfCurve.hxx>
#include <TColGeom_HSequenceOfBoundedCurve.hxx>
#include <TColGeom2d_HSequenceOfBoundedCurve.hxx>
#include <GeomAbs_Shape.hxx>
#include <Standard_Integer.hxx>
class ShapeAlgo_ToolContainer;
class ShapeAnalysis_Wire;
class ShapeExtend_WireData;
class Geom_BSplineCurve;
class Geom2d_BSplineCurve;
class TopoDS_Shape;
class Geom_BSplineSurface;
class Geom_Surface;
class TopoDS_Wire;
class TopoDS_Face;
class Geom_Curve;
class ShapeAlgo_AlgoContainer;
DEFINE_STANDARD_HANDLE(ShapeAlgo_AlgoContainer, MMgt_TShared)
class ShapeAlgo_AlgoContainer : public MMgt_TShared
{
public:
//! Empty constructor
Standard_EXPORT ShapeAlgo_AlgoContainer();
//! Sets ToolContainer
void SetToolContainer (const Handle(ShapeAlgo_ToolContainer)& TC);
//! Returns ToolContainer
Handle(ShapeAlgo_ToolContainer) ToolContainer() const;
//! Finds the best way to connect and connects <nextsewd> to already
//! built <sewd> (in <saw>).
//! Returns False if <nextsewd> cannot be connected, otherwise - True.
//! <maxtol> specifies the maximum tolerance with which <nextsewd> can
//! be added.
//! <distmin> is used to receive the minimum distance between <nextsewd>
//! and <sewd>.
//! <revsewd> is True if <sewd> has been reversed before connecting.
//! <revnextwd> is True if <nextsewd> has been reversed before connecting.
//! Uses functionality of ShapeAnalysis_Wire.
Standard_EXPORT virtual Standard_Boolean ConnectNextWire (const Handle(ShapeAnalysis_Wire)& saw, const Handle(ShapeExtend_WireData)& nextsewd, const Standard_Real maxtol, Standard_Real& distmin, Standard_Boolean& revsewd, Standard_Boolean& revnextsewd) const;
Standard_EXPORT virtual void ApproxBSplineCurve (const Handle(Geom_BSplineCurve)& bspline, TColGeom_SequenceOfCurve& seq) const;
Standard_EXPORT virtual void ApproxBSplineCurve (const Handle(Geom2d_BSplineCurve)& bspline, TColGeom2d_SequenceOfCurve& seq) const;
Standard_EXPORT virtual Standard_Boolean C0BSplineToSequenceOfC1BSplineCurve (const Handle(Geom_BSplineCurve)& BS, Handle(TColGeom_HSequenceOfBoundedCurve)& seqBS) const;
//! Converts C0 B-Spline curve into sequence of C1 B-Spline curves.
//! Calls ShapeUpgrade::C0BSplineToSequenceOfC1BSplineCurve.
Standard_EXPORT virtual Standard_Boolean C0BSplineToSequenceOfC1BSplineCurve (const Handle(Geom2d_BSplineCurve)& BS, Handle(TColGeom2d_HSequenceOfBoundedCurve)& seqBS) const;
//! Converts a shape on C0 geometry into the shape on C1 geometry.
Standard_EXPORT virtual TopoDS_Shape C0ShapeToC1Shape (const TopoDS_Shape& shape, const Standard_Real tol) const;
//! Converts a surface to B-Spline.
//! Uses ShapeConstruct.
Standard_EXPORT virtual Handle(Geom_BSplineSurface) ConvertSurfaceToBSpline (const Handle(Geom_Surface)& surf, const Standard_Real UF, const Standard_Real UL, const Standard_Real VF, const Standard_Real VL) const;
//! Return 2 wires with the same number of edges. The both Edges
//! number i of these wires have got the same ratio between
//! theirs parameter lengths and their wire parameter lengths.
Standard_EXPORT virtual Standard_Boolean HomoWires (const TopoDS_Wire& wireIn1, const TopoDS_Wire& wireIn2, TopoDS_Wire& wireOut1, TopoDS_Wire& wireOut2, const Standard_Boolean byParam) const;
//! Returns the outer wire on the face <Face>.
Standard_EXPORT virtual TopoDS_Wire OuterWire (const TopoDS_Face& face) const;
//! Converts surface to periodic form.
//! Calls ShapeCustom_Surface.
Standard_EXPORT virtual Handle(Geom_Surface) ConvertToPeriodic (const Handle(Geom_Surface)& surf) const;
//! Computes exact UV bounds of all wires on the face
Standard_EXPORT virtual void GetFaceUVBounds (const TopoDS_Face& F, Standard_Real& Umin, Standard_Real& Umax, Standard_Real& Vmin, Standard_Real& Vmax) const;
//! Convert Geom_Curve to Geom_BSplineCurve
Standard_EXPORT virtual Handle(Geom_BSplineCurve) ConvertCurveToBSpline (const Handle(Geom_Curve)& C3D, const Standard_Real First, const Standard_Real Last, const Standard_Real Tol3d, const GeomAbs_Shape Continuity, const Standard_Integer MaxSegments, const Standard_Integer MaxDegree) const;
DEFINE_STANDARD_RTTI(ShapeAlgo_AlgoContainer,MMgt_TShared)
protected:
private:
Handle(ShapeAlgo_ToolContainer) myTC;
};
#include <ShapeAlgo_AlgoContainer.lxx>
#endif // _ShapeAlgo_AlgoContainer_HeaderFile

View File

@@ -1,36 +0,0 @@
-- Created on: 2000-02-07
-- Created by: data exchange team
-- Copyright (c) 2000-2014 OPEN CASCADE SAS
--
-- This file is part of Open CASCADE Technology software library.
--
-- This library is free software; you can redistribute it and/or modify it under
-- the terms of the GNU Lesser General Public License version 2.1 as published
-- by the Free Software Foundation, with special exception defined in the file
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
-- distribution for complete text of the license and disclaimer of any warranty.
--
-- Alternatively, this file may be used under the terms of Open CASCADE
-- commercial license or contractual agreement.
class ToolContainer from ShapeAlgo inherits TShared from MMgt
---Purpose: Returns tools used by AlgoContainer
uses
Shape from ShapeFix,
EdgeProjAux from ShapeFix
is
Create returns ToolContainer from ShapeAlgo;
---Purpose: Empty constructor
FixShape (me) returns Shape from ShapeFix is virtual;
---Purpose: Returns ShapeFix_Shape
EdgeProjAux (me) returns EdgeProjAux from ShapeFix is virtual;
---Purpose: Returns ShapeFix_EdgeProjAux
end ToolContainer;

View File

@@ -13,13 +13,16 @@
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#include <ShapeAlgo_ToolContainer.ixx>
#include <ShapeAlgo_ToolContainer.hxx>
#include <ShapeFix_EdgeProjAux.hxx>
#include <ShapeFix_Shape.hxx>
#include <Standard_Type.hxx>
//=======================================================================
//function : ShapeAlgo_ToolContainer
//purpose :
//=======================================================================
ShapeAlgo_ToolContainer::ShapeAlgo_ToolContainer()
{
}

View File

@@ -0,0 +1,69 @@
// Created on: 2000-02-07
// Created by: data exchange team
// Copyright (c) 2000-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 as published
// by the Free Software Foundation, with special exception defined in the file
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
// distribution for complete text of the license and disclaimer of any warranty.
//
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#ifndef _ShapeAlgo_ToolContainer_HeaderFile
#define _ShapeAlgo_ToolContainer_HeaderFile
#include <Standard.hxx>
#include <Standard_Type.hxx>
#include <MMgt_TShared.hxx>
class ShapeFix_Shape;
class ShapeFix_EdgeProjAux;
class ShapeAlgo_ToolContainer;
DEFINE_STANDARD_HANDLE(ShapeAlgo_ToolContainer, MMgt_TShared)
//! Returns tools used by AlgoContainer
class ShapeAlgo_ToolContainer : public MMgt_TShared
{
public:
//! Empty constructor
Standard_EXPORT ShapeAlgo_ToolContainer();
//! Returns ShapeFix_Shape
Standard_EXPORT virtual Handle(ShapeFix_Shape) FixShape() const;
//! Returns ShapeFix_EdgeProjAux
Standard_EXPORT virtual Handle(ShapeFix_EdgeProjAux) EdgeProjAux() const;
DEFINE_STANDARD_RTTI(ShapeAlgo_ToolContainer,MMgt_TShared)
protected:
private:
};
#endif // _ShapeAlgo_ToolContainer_HeaderFile