-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from joe-warren/migrate-to-finalizers
Migrate to Finalizers, Add Queries
- Loading branch information
Showing
63 changed files
with
1,065 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#include <BRepBndLib.hxx> | ||
#include "hs_BRepBndLib.h" | ||
|
||
void hs_BRepBndLib_add(TopoDS_Shape * shape, Bnd_Box * box, bool useTriangulation){ | ||
BRepBndLib::Add(*shape, *box, useTriangulation); | ||
} | ||
|
||
void hs_BRepBndLib_addOptimal(TopoDS_Shape * shape, Bnd_Box * box, bool useTriangulation, bool useShapeTolerance){ | ||
BRepBndLib::AddOptimal(*shape, *box, useTriangulation, useShapeTolerance); | ||
} | ||
|
||
void hs_BRepBndLib_addOBB(TopoDS_Shape *shape, Bnd_OBB * obb, bool isTriangulationUsed, bool isOptimal, bool isShapeToleranceUsed){ | ||
BRepBndLib::AddOBB(*shape, *obb, isTriangulationUsed, isOptimal, isShapeToleranceUsed); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#ifndef HS_BREPBNDLIB_H | ||
#define HS_BREPBNDLIB_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
void hs_BRepBndLib_add(TopoDS_Shape * shape, Bnd_Box * box, bool useTriangulation); | ||
|
||
void hs_BRepBndLib_addOptimal(TopoDS_Shape * shape, Bnd_Box * box, bool useTriangulation, bool useShapeTolerance); | ||
|
||
void hs_BRepBndLib_addOBB(TopoDS_Shape *shape, Bnd_OBB * obb, bool isTriangulationUsed, bool isOptimal, bool isShapeToleranceUsed); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_BREPBNDLIB_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <BRepGProp.hxx> | ||
#include "hs_BRepGProp.h" | ||
|
||
void hs_BRepGProp_VolumeProperties(TopoDS_Shape *shape, GProp_GProps *props, bool onlyClosed, bool skipShared, bool useTriangulation ){ | ||
BRepGProp::VolumeProperties(*shape, *props, onlyClosed, skipShared, useTriangulation); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#ifndef HS_BREPGPROP_H | ||
#define HS_BREPGPROP_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
void hs_BRepGProp_VolumeProperties(TopoDS_Shape * shape, GProp_GProps * props, bool onlyClosed, bool skipShared, bool useTriangulation ); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_BREPGPROP_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#include <Bnd_Box.hxx> | ||
#include "hs_Bnd_Box.h" | ||
|
||
Bnd_Box * hs_new_Bnd_Box(){ | ||
return new Bnd_Box(); | ||
} | ||
|
||
void hs_delete_Bnd_Box(Bnd_Box * box){ | ||
delete box; | ||
} | ||
|
||
gp_Pnt * hs_Bnd_Box_cornerMin(Bnd_Box * box){ | ||
return new gp_Pnt(box->CornerMin()); | ||
} | ||
|
||
gp_Pnt * hs_Bnd_Box_cornerMax(Bnd_Box * box){ | ||
return new gp_Pnt(box->CornerMax()); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#ifndef HS_BND_BOX_H | ||
#define HS_BND_BOX_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
Bnd_Box * hs_new_Bnd_Box(); | ||
|
||
void hs_delete_Bnd_Box(Bnd_Box * box); | ||
|
||
gp_Pnt * hs_Bnd_Box_cornerMin(Bnd_Box * box); | ||
|
||
gp_Pnt * hs_Bnd_Box_cornerMax(Bnd_Box * box); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_BND_BOX_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
#include <Bnd_OBB.hxx> | ||
#include "hs_Bnd_OBB.h" | ||
|
||
Bnd_OBB * hs_new_Bnd_OBB() { | ||
return new Bnd_OBB(); | ||
} | ||
|
||
void hs_delete_Bnd_OBB(Bnd_OBB * obb){ | ||
delete obb; | ||
} | ||
|
||
gp_XYZ * hs_Bnd_OBB_center(Bnd_OBB * obb){ | ||
return new gp_XYZ(obb->Center()); | ||
} | ||
|
||
gp_XYZ * hs_Bnd_OBB_xDirection(Bnd_OBB * obb){ | ||
return new gp_XYZ(obb->XDirection()); | ||
} | ||
|
||
gp_XYZ * hs_Bnd_OBB_yDirection(Bnd_OBB * obb){ | ||
return new gp_XYZ(obb->YDirection()); | ||
} | ||
|
||
gp_XYZ * hs_Bnd_OBB_zDirection(Bnd_OBB * obb){ | ||
return new gp_XYZ(obb->ZDirection()); | ||
} | ||
|
||
double hs_Bnd_OBB_xHSize(Bnd_OBB *obb){ | ||
return obb->XHSize(); | ||
} | ||
|
||
double hs_Bnd_OBB_yHSize(Bnd_OBB *obb){ | ||
return obb->YHSize(); | ||
} | ||
|
||
double hs_Bnd_OBB_zHSize(Bnd_OBB *obb){ | ||
return obb->ZHSize(); | ||
} | ||
|
||
gp_Ax3 * hs_Bnd_OBB_position(Bnd_OBB *obb){ | ||
return new gp_Ax3(obb->Position()); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#ifndef HS_BND_OBB_H | ||
#define HS_BND_OBB_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
Bnd_OBB * hs_new_Bnd_OBB(); | ||
|
||
void hs_delete_Bnd_OBB(Bnd_OBB * obb); | ||
|
||
gp_XYZ * hs_Bnd_OBB_center(Bnd_OBB * obb); | ||
|
||
gp_XYZ * hs_Bnd_OBB_xDirection(Bnd_OBB * obb); | ||
|
||
gp_XYZ * hs_Bnd_OBB_yDirection(Bnd_OBB * obb); | ||
|
||
gp_XYZ * hs_Bnd_OBB_zDirection(Bnd_OBB * obb); | ||
|
||
double hs_Bnd_OBB_xHSize(Bnd_OBB *obb); | ||
|
||
double hs_Bnd_OBB_yHSize(Bnd_OBB *obb); | ||
|
||
double hs_Bnd_OBB_zHSize(Bnd_OBB *obb); | ||
|
||
gp_Ax3 * hs_Bnd_OBB_position(Bnd_OBB *obb); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_BND_OBB_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#include <GProp_GProps.hxx> | ||
#include "hs_GProp_GProps.h" | ||
|
||
GProp_GProps * hs_new_GProp_GProps(){ | ||
return new GProp_GProps(); | ||
} | ||
|
||
GProp_GProps * hs_new_GProp_GProps_fromSystemLocation(gp_Pnt * pnt){ | ||
return new GProp_GProps(*pnt); | ||
} | ||
|
||
void hs_delete_GProp_GProps(GProp_GProps * props){ | ||
delete props; | ||
} | ||
|
||
double hs_GProp_GProps_mass(GProp_GProps * props){ | ||
return props->Mass(); | ||
} | ||
|
||
gp_Pnt * hs_GProp_GProps_centreOfMass(GProp_GProps * props){ | ||
return new gp_Pnt(props->CentreOfMass()); | ||
} | ||
|
||
double hs_GProp_GProps_momentOfInertia(GProp_GProps * props, gp_Ax1 * ax){ | ||
return props->MomentOfInertia(*ax); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#ifndef HS_GPROP_GPROPS_H | ||
#define HS_GPROP_GPROPS_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
GProp_GProps * hs_new_GProp_GProps(); | ||
|
||
GProp_GProps * hs_new_GProp_GProps_fromSystemLocation(gp_Pnt * pnt); | ||
|
||
void hs_delete_GProp_GProps(GProp_GProps * props); | ||
|
||
double hs_GProp_GProps_mass(GProp_GProps * props); | ||
|
||
gp_Pnt * hs_GProp_GProps_centreOfMass(GProp_GProps * props); | ||
|
||
double hs_GProp_GProps_momentOfInertia(GProp_GProps * props, gp_Ax1 * ax); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_GPROP_GPROPS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#include <gp_XYZ.hxx> | ||
#include "hs_gp_XYZ.h" | ||
|
||
gp_XYZ * hs_new_gp_XYZ(){ | ||
return new gp_XYZ(); | ||
} | ||
|
||
gp_XYZ * hs_new_gp_XYZ_fromDoubles(double x, double y, double z){ | ||
return new gp_XYZ(x, y, z); | ||
} | ||
|
||
void hs_delete_gp_XYZ(gp_XYZ * xyz){ | ||
delete xyz; | ||
} | ||
|
||
void hs_gp_XYZ_setX(gp_XYZ * xyz, double x){ | ||
xyz->SetX(x); | ||
} | ||
|
||
void hs_gp_XYZ_setY(gp_XYZ * xyz, double y){ | ||
xyz->SetY(y); | ||
} | ||
|
||
void hs_gp_XYZ_setZ(gp_XYZ * xyz, double z){ | ||
xyz->SetZ(z); | ||
} | ||
|
||
double hs_gp_XYZ_x(gp_XYZ * xyz){ | ||
return xyz->X(); | ||
} | ||
|
||
double hs_gp_XYZ_y(gp_XYZ * xyz){ | ||
return xyz->Y(); | ||
} | ||
|
||
double hs_gp_XYZ_z(gp_XYZ * xyz){ | ||
return xyz->Z(); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#ifndef HS_GP_XYZ_H | ||
#define HS_GP_XYZ_H | ||
|
||
#include "hs_types.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
gp_XYZ * hs_new_gp_XYZ(); | ||
|
||
gp_XYZ * hs_new_gp_XYZ_fromDoubles(double x, double y, double z); | ||
|
||
void hs_delete_gp_XYZ(gp_XYZ * xyz); | ||
|
||
void hs_gp_XYZ_setX(gp_XYZ * xyz, double x); | ||
|
||
void hs_gp_XYZ_setY(gp_XYZ * xyz, double y); | ||
|
||
void hs_gp_XYZ_setZ(gp_XYZ * xyz, double z); | ||
|
||
double hs_gp_XYZ_x(gp_XYZ * xyz); | ||
|
||
double hs_gp_XYZ_y(gp_XYZ * xyz); | ||
|
||
double hs_gp_XYZ_z(gp_XYZ * xyz); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // HS_GP_XYZ_H | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.