GO2cam Javascript API  6.11
GO2SMesh Class Reference

Class managing mesh geometry. More...

Inheritance diagram for GO2SMesh:
T_GO2SSolid< TShape, TExtrusion, TRevol, TBool > GO2SSolidGeometry GO2SGeometry

Public Member Functions

GO2SEnum::GO2SError FromFile (String dir, String name)
 
GO2SEnum::GO2SError FromFile (String filename)
 
GO2SEnum::GO2SError Intersection (GO2SMesh other)
 
GO2SEnum::GO2SError MultiIntersection (Array< GO2SMesh > others)
 
GO2SEnum::GO2SError MultiSubtract (Array< GO2SMesh > others)
 
GO2SEnum::GO2SError MultiUnion (Array< GO2SMesh > others)
 
GO2SEnum::GO2SError Subtract (GO2SMesh other)
 
GO2SEnum::GO2SError ToFile (String dir, String name, Boolean binary=true)
 
GO2SEnum::GO2SError ToFile (String filename, Boolean binary=true)
 
GO2SEnum::GO2SError Union (GO2SMesh other)
 
- Public Member Functions inherited from T_GO2SSolid< TShape, TExtrusion, TRevol, TBool >
GO2SEnum::GO2SError CreateCuboid (GO2SXYZ Org, GO2SXYZ ptX, GO2SXYZ ptY, Number h)
 
GO2SEnum::GO2SError CreateCylinder (GO2SXYZ center, Number radius, Number height)
 
GO2SEnum::GO2SError CreateExtrusion (GO2SProfile profile, GO2SXYZ direction, Number height, Number taperAngle, Boolean surfacic)
 
GO2SEnum::GO2SError CreateMultiExtrusion (Array< GO2SProfile > profiles, GO2SXYZ direction, Number height, Number taperAngle, Boolean surfacic)
 
GO2SEnum::GO2SError CreateMultiRevolution (Array< GO2SProfile > profiles, GO2SXYZ axis, Number angle, Boolean surfacic)
 
GO2SEnum::GO2SError CreateRevolution (GO2SProfile profile, GO2SXYZ axis, Number angle, Boolean surfacic)
 
- Public Member Functions inherited from GO2SSolidGeometry
Number GetSurface ()
 
Number GetVolume ()
 
GO2SMesh ToMesh (Number tol=0.1)
 
- Public Member Functions inherited from GO2SGeometry
GO2SEnum::GO2SError ChangePlane (Number plane)
 
GO2SGeometry Copy ()
 
GO2SEnum::GO2SError Delete ()
 
Array< GO2SXYZDiscretize (Number accuracy=0.01)
 
Boolean Equals (GO2SGeometry other)
 
Array< GO2SXYZGetBoundingBox ()
 
Number GetColor ()
 
Array< GO2SEnum::GO2SParamGetEditableParams ()
 
Number GetLayer ()
 
Number GetLineType ()
 
Number GetLineWidth ()
 
String GetName ()
 
Number GetParam (GO2SEnum::GO2SParam param)
 
GO2SGeometry GetParent ()
 
Number GetPlane ()
 
GO2SXYZ GetPosition ()
 
Boolean IsCircular ()
 
Boolean IsLinear ()
 
Boolean IsParamEditable (GO2SEnum::GO2SParam param)
 
Boolean IsPoint ()
 
Boolean IsPositionEditable ()
 
Boolean IsSolid ()
 
Boolean IsValid ()
 
Boolean IsVisible ()
 
Boolean IsWireframe ()
 
GO2SGeometry Rotated (GO2SXYZ xyz, Number angle, Boolean xyzDir)
 
GO2SEnum::GO2SError SetColor (Number color)
 
GO2SEnum::GO2SError SetLayer (Number layer)
 
GO2SEnum::GO2SError SetLineType (ELineType type)
 
GO2SEnum::GO2SError SetLineWidth (Number width)
 
GO2SEnum::GO2SError SetName (String p1)
 
GO2SEnum::GO2SError SetParam (GO2SEnum::GO2SParam param, Number value)
 
GO2SEnum::GO2SError SetPlane (Number plane)
 
GO2SEnum::GO2SError SetPolarPosition (Number radius, Number angle, Number altitude=0)
 
GO2SEnum::GO2SError SetPosition (GO2SXYZpos)
 
GO2SEnum::GO2SError SetPosition (Number x, Number y, Number z)
 
GO2SEnum::GO2SError SetVisible (Boolean visibility)
 
String toString ()
 
GO2SEnum::GO2SError Transform (GO2SMatrix matrix)
 
GO2SGeometry Transformed (GO2SMatrix matrix)
 
GO2SGeometry Translated (GO2SXYZ origin, GO2SXYZ p)
 

Detailed Description

Class managing mesh geometry.

Member Function Documentation

◆ FromFile() [1/2]

GO2SEnum::GO2SError GO2SMesh::FromFile ( String dir,
String name )

Load a mesh from a file

Remarks
Supported format(s): STL
Parameters
[in]dirdirectory
[in]namefilename, must end with '.stl'

◆ FromFile() [2/2]

GO2SEnum::GO2SError GO2SMesh::FromFile ( String filename)

Load a mesh from a file

Remarks
Supported format(s): STL
Parameters
[in]filenameabsolute filename, must end with '.stl'

◆ Intersection()

GO2SEnum::GO2SError GO2SMesh::Intersection ( GO2SMesh other)
inline

Compute the intersection between 2 solid entities

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise

◆ MultiIntersection()

GO2SEnum::GO2SError GO2SMesh::MultiIntersection ( Array< GO2SMesh > others)
inline

Compute the intersection between several solids

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise

◆ MultiSubtract()

GO2SEnum::GO2SError GO2SMesh::MultiSubtract ( Array< GO2SMesh > others)
inline

Compute the subtraction between several solids

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise

◆ MultiUnion()

GO2SEnum::GO2SError GO2SMesh::MultiUnion ( Array< GO2SMesh > others)
inline

Compute the union between several solids

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise

◆ Subtract()

GO2SEnum::GO2SError GO2SMesh::Subtract ( GO2SMesh other)
inline

Compute the subtraction between 2 solid entities

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise

◆ ToFile() [1/2]

GO2SEnum::GO2SError GO2SMesh::ToFile ( String dir,
String name,
Boolean binary = true )

Save mesh in a file

Remarks
Supported format(s): STL
Parameters
[in]dirdirectory
[in]namefilename, must end with '.stl'
[in]binarysave as binary file if true, ascii otherwise (is the format is compatible)

◆ ToFile() [2/2]

GO2SEnum::GO2SError GO2SMesh::ToFile ( String filename,
Boolean binary = true )

Save the mesh to a file

Remarks
Supported format(s): STL
Parameters
[in]filenameabsolute filename, must end with '.stl'
[in]binarysave as binary file if true, ascii otherwise (is the format is compatible)

◆ Union()

GO2SEnum::GO2SError GO2SMesh::Union ( GO2SMesh other)
inline

Compute the union between 2 solid entities

Warning
operands will be deleted
Returns
GO2SError.success (0) if success, see GO2SError otherwise