OCC.Core.BinTools module¶
BinTools module, see official documentation at https://www.opencascade.com/doc/occt-7.4.0/refman/html/package_bintools.html
-
class
BinTools_Curve2dSet(*args)¶ Bases:
object- Returns an empty set of Curves.
- rtype
None
-
Add()¶ - Incorporate a new Curve in the set and returns its index.
- param C
- type C
opencascade::handle<Geom2d_Curve> &
- rtype
int
-
Clear()¶ - Clears the content of the set.
- rtype
None
-
Curve2d()¶ - Returns the Curve of index <I>.
- param I
- type I
int
- rtype
opencascade::handle<Geom2d_Curve>
-
Index()¶ - Returns the index of <L>.
- param C
- type C
opencascade::handle<Geom2d_Curve> &
- rtype
int
-
static
ReadCurve2d()¶ - Reads the curve from the stream. The curve is assumed to have been written with the Write method.
- param IS
- type IS
Standard_IStream &
- param C
- type C
opencascade::handle<Geom2d_Curve> &
- rtype
Standard_IStream
-
ReadFromString(BinTools_Curve2dSet self, std::string src)¶
-
static
WriteCurve2d()¶ - Dumps the curve on the binary stream, that can be read back.
- param C
- type C
opencascade::handle<Geom2d_Curve> &
- param OS
- type OS
Standard_OStream &
- rtype
void
-
WriteToString(BinTools_Curve2dSet self) → std::string¶
-
property
thisown¶ The membership flag
-
class
BinTools_CurveSet(*args)¶ Bases:
object- Returns an empty set of Curves.
- rtype
None
-
Add()¶ - Incorporate a new Curve in the set and returns its index.
- param C
- type C
opencascade::handle<Geom_Curve> &
- rtype
int
-
Clear()¶ - Clears the content of the set.
- rtype
None
-
Curve()¶ - Returns the Curve of index <I>.
- param I
- type I
int
- rtype
opencascade::handle<Geom_Curve>
-
Index()¶ - Returns the index of <L>.
- param C
- type C
opencascade::handle<Geom_Curve> &
- rtype
int
-
static
ReadCurve()¶ - Reads the curve from the stream. The curve is assumed to have been written with the Write method
- param IS
- type IS
Standard_IStream &
- param C
- type C
opencascade::handle<Geom_Curve> &
- rtype
Standard_IStream
-
ReadFromString(BinTools_CurveSet self, std::string src)¶
-
static
WriteCurve()¶ - Dumps the curve on the stream in binary format that can be read back.
- param C
- type C
opencascade::handle<Geom_Curve> &
- param OS
- type OS
Standard_OStream &
- rtype
void
-
WriteToString(BinTools_CurveSet self) → std::string¶
-
property
thisown¶ The membership flag
-
class
BinTools_LocationSet(*args)¶ Bases:
object- Returns an empty set of locations.
- rtype
None
-
Add()¶ - Incorporate a new Location in the set and returns its index.
- param L
- type L
TopLoc_Location &
- rtype
int
-
Clear()¶ - Clears the content of the set.
- rtype
None
-
Index()¶ - Returns the index of <L>.
- param L
- type L
TopLoc_Location &
- rtype
int
-
Location()¶ - Returns the location of index <I>.
- param I
- type I
int
- rtype
TopLoc_Location
-
NbLocations()¶ - Returns number of locations.
- rtype
int
-
ReadFromString(BinTools_LocationSet self, std::string src)¶
-
WriteToString(BinTools_LocationSet self) → std::string¶
-
property
thisown¶ The membership flag
-
class
BinTools_ShapeSet(*args)¶ Bases:
object- Builds an empty ShapeSet. Parameter <isWithTriangles> is added for XML Persistence
- param isWithTriangles
default value is Standard_False
- type isWithTriangles
bool
- rtype
None
-
Add()¶ - Stores <S> and its sub-shape. Returns the index of <S>. The method AddGeometry is called on each sub-shape.
- param S
- type S
TopoDS_Shape &
- rtype
int
-
AddGeometry()¶ - Stores the goemetry of <S>.
- param S
- type S
TopoDS_Shape &
- rtype
void
-
AddShapes()¶ - Inserts the shape <S2> in the shape <S1>.
- param S1
- type S1
TopoDS_Shape &
- param S2
- type S2
TopoDS_Shape &
- rtype
void
-
ChangeLocations()¶ - Return type
-
Clear()¶ - Clears the content of the set.
- rtype
void
-
FormatNb()¶ - two formats available for the moment: First: does not write CurveOnSurface UV Points into the file on reading calls Check() method. Second: stores CurveOnSurface UV Points. On reading format is recognized from Version string.
- rtype
int
-
Index()¶ - Returns the index of <S>.
- param S
- type S
TopoDS_Shape &
- rtype
int
-
IsWithTriangles()¶ - Return true if shape should be stored with triangles.
- rtype
bool
-
Locations()¶ - Return type
-
NbShapes()¶ - Returns number of shapes read from file.
- rtype
int
-
Read()¶ - Reads from <IS> a shape and returns it in S. <NbShapes> is the number of tshapes in the set.
- param S
- type S
TopoDS_Shape &
- param IS
- type IS
Standard_IStream &
- param NbShapes
- type NbShapes
int
- rtype
void
-
ReadFromString(BinTools_ShapeSet self, std::string src)¶
-
ReadGeometry()¶ - Reads the geometry of a shape of type <T> from the stream <IS> and returns it in <S>.
- param T
- type T
TopAbs_ShapeEnum
- param IS
- type IS
Standard_IStream &
- param S
- type S
TopoDS_Shape &
- rtype
void
-
ReadGeometryFromString(BinTools_ShapeSet self, std::string src)¶
-
ReadPolygon3DFromString(BinTools_ShapeSet self, std::string src)¶
-
ReadPolygonOnTriangulationFromString(BinTools_ShapeSet self, std::string src)¶
-
ReadTriangulationFromString(BinTools_ShapeSet self, std::string src)¶
-
SetFormatNb()¶ - Parameters
theFormatNb –
- type theFormatNb
int
- rtype
None
-
SetWithTriangles()¶ - Define if shape will be stored with triangles. Ignored (always written) if face defines only triangulation (no surface).
- param isWithTriangles
- type isWithTriangles
bool
- rtype
None
-
Shape()¶ - Returns the sub-shape of index <I>.
- param I
- type I
int
- rtype
TopoDS_Shape
-
Write()¶ - Writes on <OS> the shape <S>. Writes the orientation, the index of the TShape and the index of the Location.
- param S
- type S
TopoDS_Shape &
- param OS
- type OS
Standard_OStream &
- rtype
void
-
WriteGeometry()¶ - Writes the geometry of <S> on the stream <OS> in a binary format that can be read back by Read.
- param S
- type S
TopoDS_Shape &
- param OS
- type OS
Standard_OStream &
- rtype
void
-
WriteGeometryToString(BinTools_ShapeSet self) → std::string¶
-
WritePolygon3DToString(BinTools_ShapeSet self) → std::string¶
-
WritePolygonOnTriangulationToString(BinTools_ShapeSet self) → std::string¶
-
WriteToString(BinTools_ShapeSet self) → std::string¶
-
WriteTriangulationToString(BinTools_ShapeSet self) → std::string¶
-
property
thisown¶ The membership flag
-
class
BinTools_SurfaceSet(*args)¶ Bases:
object- Returns an empty set of Surfaces.
- rtype
None
-
Add()¶ - Incorporate a new Surface in the set and returns its index.
- param S
- type S
opencascade::handle<Geom_Surface> &
- rtype
int
-
Clear()¶ - Clears the content of the set.
- rtype
None
-
Index()¶ - Returns the index of <L>.
- param S
- type S
opencascade::handle<Geom_Surface> &
- rtype
int
-
ReadFromString(BinTools_SurfaceSet self, std::string src)¶
-
static
ReadSurface()¶ - Reads the surface from the stream. The surface is assumed to have been written with the Write method.
- param IS
- type IS
Standard_IStream &
- param S
- type S
opencascade::handle<Geom_Surface> &
- rtype
Standard_IStream
-
Surface()¶ - Returns the Surface of index <I>.
- param I
- type I
int
- rtype
opencascade::handle<Geom_Surface>
-
static
WriteSurface()¶ - Dumps the surface on the stream in binary format that can be read back.
- param S
- type S
opencascade::handle<Geom_Surface> &
- param OS
- type OS
Standard_OStream &
- rtype
void
-
WriteToString(BinTools_SurfaceSet self) → std::string¶
-
property
thisown¶ The membership flag
-
class
SwigPyIterator(*args, **kwargs)¶ Bases:
object-
advance()¶
-
copy()¶
-
decr()¶
-
distance()¶
-
equal()¶
-
incr()¶
-
next()¶
-
previous()¶
-
property
thisown¶ The membership flag
-
value()¶
-
-
class
bintools¶ Bases:
object-
static
GetBool()¶ - Parameters
IS –
- type IS
Standard_IStream &
- param theValue
- type theValue
bool
- rtype
Standard_IStream
-
static
GetExtChar()¶ - Parameters
IS –
- type IS
Standard_IStream &
- param theValue
- type theValue
Standard_ExtCharacter &
- rtype
Standard_IStream
-
static
GetInteger()¶ - Parameters
IS –
- type IS
Standard_IStream &
- param theValue
- type theValue
int &
- rtype
Standard_IStream
-
static
GetReal()¶ - Parameters
IS –
- type IS
Standard_IStream &
- param theValue
- type theValue
float &
- rtype
Standard_IStream
-
static
PutBool()¶ - Parameters
OS –
- type OS
Standard_OStream &
- param theValue
- type theValue
bool
- rtype
Standard_OStream
-
static
PutExtChar()¶ - Parameters
OS –
- type OS
Standard_OStream &
- param theValue
- type theValue
Standard_ExtCharacter
- rtype
Standard_OStream
-
static
PutInteger()¶ - Parameters
OS –
- type OS
Standard_OStream &
- param theValue
- type theValue
int
- rtype
Standard_OStream
-
static
PutReal()¶ - Parameters
OS –
- type OS
Standard_OStream &
- param theValue
- type theValue
float
- rtype
Standard_OStream
-
static
Read()¶ - Reads a shape from <theStream> and returns it in <theShape>.
- param theShape
- type theShape
TopoDS_Shape &
- param theStream
- type theStream
Standard_IStream &
- rtype
void* Reads a shape from <theFile> and returns it in <theShape>.
- param theShape
- type theShape
TopoDS_Shape &
- param theFile
- type theFile
char *
- rtype
bool
-
static
Write()¶ - Writes <theShape> on <theStream> in binary format.
- param theShape
- type theShape
TopoDS_Shape &
- param theStream
- type theStream
Standard_OStream &
- rtype
void* Writes <theShape> in <theFile>.
- param theShape
- type theShape
TopoDS_Shape &
- param theFile
- type theFile
char *
- rtype
bool
-
property
thisown¶ The membership flag
-
static