Cyclone 3DR Script
from Technodigit, part of Hexagon. Copyright 1997-2024.
Loading...
Searching...
No Matches
SSurveying Namespace Reference

Provide various methods of analysis for SCloud, SPoly and SMultiline. More...

Enumerations

enum  InspectionType { TunnelType = 0 , RoadType = 1 }
 The type of inspection for cross sections. More...
 
enum  TunnelComputedObj { TunnelMesh = 1 , TunnelCloud = 2 , TunnelNoiseCloud = 4 }
 The objects to extract with SSurveying.ExtractTunnel. More...
 
enum  TunnelMeshingStrategy { FastMesh = 0 , RegularResampling = 1 , RefineMesh = 2 }
 The tunnel meshing strategy. More...
 

Functions

Object CompareCrossSections (Array< SComp > tblDComp, InspectionType inspectionType, SVector direction2D, string referenceName, Object options={}, SReportData reportData=null)
 Compare sections by pair. To keep the compatibility between sections, they should be generated using the command Create along axis or the script function SSurveying.CreateCrossSections. This function gives new lines with colorized segments, showing the differences between two profiles. These differences may have positive or negative values. More...
 
Object ComputeDsm (Array< SCloud > clouds, number step=0)
 Compute the Digital Surface Model of one (or several) SCloud. More...
 
Object ContourLinesCloud (SCloud cloud, SVector normalAxis, number step, number heightStart, number heightEnd=0, number planeThickness=1, number chainingDist=1, boolean checkNoise=true, Object renderingOption={}, number filterLength=0)
 Create contour lines on a SCloud. More...
 
Object ContourLinesPoly (SPoly poly, SVector normalAxis, number step, number heightStart, number heightEnd=0, Object renderingOption={}, number filterLength=0)
 Create contour lines on a SPoly. More...
 
Object CreateCrossSections (SComp firstComp, SComp secondComp, SComp neutralAxis, Array< number > distanceList=[], Object sections={}, Object options={})
 Create cross sections on an object (SPoly or SCloud) along a SMultiline. More...
 
Object EstimateScanDirFromTrajectory (SCloud cloud, STrajectory trajectory)
 Compute the scanning directions of a SCloud using a STrajectory. A new SCloud with scanning directions is returned. More...
 
Object ExtractGround (SCloud cloud, number step, number angleDeg, SVector direction, number groundExtractionStrategy, number meshingStrategy)
 Extract points on the ground (in a grid) and create a SPoly corresponding to the terrain in the SCloud. More...
 
Object ExtractTunnel (SCloud initialCloud, SMultiline neutralAxis, number step, TunnelComputedObj computedObjects=SSurveying.TunnelMesh, TunnelMeshingStrategy meshingStrategy=SSurveying.FastMesh, boolean tryToKeepDetails=false)
 Extract points on exterior layer of the tunnel and create a SPoly from those points. More...
 
Object FilterFeatureLines (SSetMultiline ridgeLines, SSetMultiline ravineLines, number length, number pertinence)
 Filter feature lines according to their length/pertinence. More...
 
Object FlattenCylindricCloud (SCloud cloudToFlatten, SMultiline axis, number radius, boolean withRelief=false, SVector direction=SVector(), Object gridOptions={})
 Flatten a SCloud representing a tubular shape (for example a tunnel) More...
 
Object FlattenCylindricPoly (SPoly polyToFlatten, SMultiline axis, number radius, boolean withRelief=false, SVector direction=SVector(), Object gridOptions={})
 Flatten a SPoly representing a tubular shape (for example a tunnel) More...
 
Object FloorFlatness (Array< SComp > compsToTreat, SVector direction, number rulerLength, number tolerance)
 Compute a floor flatness analysis on SPoly or SCloud. More...
 
Object SlopeAnalysis (Array< SComp > compsToTreat, number slopeTolerance, boolean isPercentage, number neighborsDistance=0, SVector upVector=SVector())
 Get the slope on each point of the object. More...
 
Object SurfaceLevelness (Array< SComp > compsToTreat, SVector direction, SPoint planePosition)
 Compute a surface levelness analysis on SPoly or SCloud. More...
 
Object UnrollAlong (Array< SMultiline > multisToUnroll, SMultiline axis, number altiRef)
 Unroll SMultiline along an axis. More...
 
Object WallsAndFloors (Array< SCloud > cloudsToTreat, Object options)
 Segment walls, floors and ceilings from a SCloud. More...
 

Detailed Description

Provide various methods of analysis for SCloud, SPoly and SMultiline.

Enumeration Type Documentation

◆ InspectionType

The type of inspection for cross sections.

Enumerator
TunnelType 

Make a 3D inspection.

RoadType 

Make a 2D inspection.

◆ TunnelComputedObj

The objects to extract with SSurveying.ExtractTunnel.

Enumerator
TunnelMesh 

To extract the SPoly corresponding to the tunnel shape.

TunnelCloud 

To extract the SCloud containing the points on the tunnel.

TunnelNoiseCloud 

To extract the SCloud containing the points that are INSIDE or OUTSIDE the tunnel and suspected to be noise.

◆ TunnelMeshingStrategy

The tunnel meshing strategy.

Enumerator
FastMesh 

Raw mesh: mesh vertices come from the lines extracted from slices.

RegularResampling 

Regular resampling: vertices of the mesh are regularly located according to the input cloud.

RefineMesh 

Refine the mesh (could be very time consuming)

Function Documentation

◆ CompareCrossSections()

Object SSurveying::CompareCrossSections ( Array< SComp tblDComp,
InspectionType  inspectionType,
SVector  direction2D,
string  referenceName,
Object  options = {},
SReportData  reportData = null 
)

Compare sections by pair. To keep the compatibility between sections, they should be generated using the command Create along axis or the script function SSurveying.CreateCrossSections. This function gives new lines with colorized segments, showing the differences between two profiles. These differences may have positive or negative values.

License
This function requires the license Survey or AEC.
Note
Example of the data structures that you can use to specify the options parameter
var comps = SComp.FromSel();
var dir = SVector.New(0, 0, 1);
var options = {RemovePtsMoreThan: true, RemovePtsMoreThanValue: 10, RemovePtsLessThan: true, RemovePtsLessThanValue: 0.5, IgnoreRoad: true,
IgnoreRoadValue: 0.75, CompareWithStep: true, CompareWithStepValue: 2, CompareWithStepUnit: 1};
var result = SSurveying.CompareCrossSections(comps, SSurveying.TunnelType, dir, "Theoretical tunnel", options, null);
Abstract class storing methods available on most 3D objects.
Definition: Reshaper.h:1192
static Array< SComp > FromSel()
Get all the selected SComp.
Allow the use of the mathematical vector object.
Definition: Reshaper.h:2531
static SVector New()
Empty constructor.
Provide various methods of analysis for SCloud, SPoly and SMultiline.
Definition: Reshaper.h:12235
Parameters
tblDComp(Array<SComp>) The table of SComp containing the SSetMultiline and the SPoint
inspectionType(InspectionType) The inspection type
direction2D(SVector) The direction for 2D inspection. If 3D inspection choose Z direction
referenceName(string) The name of the reference SSetMultiline
options(Object) The data structure containing filtering options
  • RemovePtsMoreThan: [Boolean] Activate the option "Remove points distant of more than"
  • RemovePtsMoreThanValue: [Number] : The value corresponding to the option "RemovePtsMoreThan". If false, choose 0
  • RemovePtsLessThan: [Boolean] Activate the option "Remove points distant of less than"
  • RemovePtsLessThanValue: [Number] The value corresponding to the option "RemovePtsLessThan". If false, choose 0
  • IgnoreRoad: [Boolean] Activate the option "Ignore the road". If inspection 2D choose false
  • IgnoreRoadValue: [Number] The value corresponding to the option "IgnoreRoad". If false, choose 0
  • CompareWithStep: [Boolean] Activate the option "Compare with regular step"
  • CompareWithStepValue: [Number] The value corresponding to the option "CompareWithStep". If false, choose 0
  • CompareWithStepUnit: [Number] The value corresponding to the unit for the option "CompareWithStep". Choose 0: metric unit in meter or 1: angle unit in radian. For 2D inspection, only metric unit is available; for 3D inspection, you can choose metric or angle unit
reportData(SReportData) The SReportData to fill with compared sections data, view set, ...
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
  • 2: The name of the reference is not correct
  • 3: A problem occurred during the computation
ret.CompTbl(Array<SComp>) The table containing the inspected SSetMultiline. The defined colors are: blue for underbreak and red for overbreak

◆ ComputeDsm()

Object SSurveying::ComputeDsm ( Array< SCloud clouds,
number  step = 0 
)

Compute the Digital Surface Model of one (or several) SCloud.

License
This function requires the license Survey.
Parameters
clouds(Array<SCloud>) The initial SCloud table used to create the DSM
step(number) The step used for the grid size (auto if <= 0)
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.Poly(SPoly) The SPoly of the computed DSM

◆ ContourLinesCloud()

Object SSurveying::ContourLinesCloud ( SCloud  cloud,
SVector  normalAxis,
number  step,
number  heightStart,
number  heightEnd = 0,
number  planeThickness = 1,
number  chainingDist = 1,
boolean  checkNoise = true,
Object  renderingOption = {},
number  filterLength = 0 
)

Create contour lines on a SCloud.

License
This function requires the license Survey.
Note
Example of the data structure that you can use to specify the renderingOptions parameter
var cloud = SCloud.FromName("Cloud")[0];
var renderingOptions = {intermNormalLineNb: 4, colorNormal: [0, 255, 255], colorMajor: [255, 255, 0],
displayText: 1, widthNormal: 2, widthMajor: 4};
var result = SSurveying.ContourLinesCloud(cloud, SVector.New(0, 0, 1), 10, 50, 100, 1, 5, true, renderingOptions);
Provide point cloud edition and creation methods.
Definition: Reshaper.h:3306
static Array< SCloud > FromName(string name)
Search all the SCloud with the given name.
Parameters
cloud(SCloud) The SCloud on which to create the contour lines
normalAxis(SVector) The normal vector of the contour lines
step(number) The step between contour lines
heightStart(number) The starting height - Major lines, if any, will be located at this height
heightEnd(number) The ending height; or 0 if contour lines all over
planeThickness(number) The plane thickness. All the points between two parallel planes distant from this value are taken into account to create the contour line. Half of the thickness is taken on each side of each plane
chainingDist(number) If the distance between two neighbor points is less than this value, a segment is created
checkNoise(boolean) Should noise reduction be activated?
renderingOption(Object) The data structure containing rendering options
  • intermNormalLineNb: [Number] The number of step(s) between major lines; if 0 no major lines are emphasized (default value: 1)
  • colorNormal: [Array<Number>] The color of normal lines (values between 0 and 255) (default color: blue [0, 0, 255])
  • colorMajor: [Array<Number>] The color of major lines (values between 0 and 255) (default color: red [255, 0, 0])
  • displayText: [Number] 0: display no text; 1: display texts only on major; 2: display texts on all (default value: 2)
  • widthNormal: [Number] The width of normal lines (between 1 and 11) (default value: 1)
  • widthMajor: [Number] The width of major lines (between 1 and 11) (default value: 2)
filterLength(number) Delete contour lines whose length is smaller than this value
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.SetMulti(SSetMultiline) The created SSetMultiline

◆ ContourLinesPoly()

Object SSurveying::ContourLinesPoly ( SPoly  poly,
SVector  normalAxis,
number  step,
number  heightStart,
number  heightEnd = 0,
Object  renderingOption = {},
number  filterLength = 0 
)

Create contour lines on a SPoly.

License
This function requires the license Survey.
Note
Example of the data structure that you can use to specify the renderingOptions parameter
var mesh = SPoly.FromName("Mesh")[0];
var renderingOptions = {intermNormalLineNb: 4, colorNormal: [0, 255, 255], colorMajor: [255, 255, 0],
displayText: 1, widthNormal: 2, widthMajor: 4};
var result = SSurveying.ContourLinesPoly(mesh, SVector.New(0, 0, 1), 10, 50, 100, renderingOptions);
Provide triangular mesh edition and creation methods.
Definition: Reshaper.h:6993
static Array< SPoly > FromName(string name)
Search all the SPoly with the given name.
Parameters
poly(SPoly) The SPoly on which to create the contour lines
normalAxis(SVector) The normal vector of the contour lines
step(number) The step between contour lines
heightStart(number) The starting height - Major lines, if any, will be located at this height
heightEnd(number) The ending height; or 0 if contour lines all over
renderingOption(Object) The data structure containing rendering options
  • intermNormalLineNb: [Number] The number of step(s) between major lines; if 0 no major lines are emphasized (default value: 1)
  • colorNormal: [Array<Number>] The color of normal lines (values between 0 and 255) (default color: blue [0, 0, 255])
  • colorMajor: [Array<Number>] The color of major lines (values between 0 and 255) (default color: red [255, 0, 0])
  • displayText: [Number] 0: display no text; 1: display texts only on major; 2: display texts on all (default value: 2)
  • widthNormal: [Number] The width of normal lines (between 1 and 11) (default value: 1)
  • widthMajor: [Number] The width of major lines (between 1 and 11) (default value: 2)
filterLength(number) Delete contour lines whose length is smaller than this value
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.SetMulti(SSetMultiline) The created SSetMultiline

◆ CreateCrossSections()

Object SSurveying::CreateCrossSections ( SComp  firstComp,
SComp  secondComp,
SComp  neutralAxis,
Array< number >  distanceList = [],
Object  sections = {},
Object  options = {} 
)

Create cross sections on an object (SPoly or SCloud) along a SMultiline.

License
This function requires the license Survey or AEC.
Note
Example of the data structures that you can use to specify the sections and options parameters
var firstComp = SComp.FromName("Measured")[0];
var secondComp = SComp.FromName("Theoretical")[0];
var axis = SMultiline.FromName("Neutral axis")[0];
// To use the list of distances option
var list = [10, 20, 30, 40, 50];
var result = SSurveying.CreateCrossSections(firstComp, secondComp, axis, list);
// To use the step option
var options = {sectionOrientation: 1, isIn2D: false, prefix: "MP", offset: 0, removePtsValue: 0,
activeNoiseReduction: true, planeThickness: 1.5, chainingDistance: 2};
var sections = {step: 4, begin: 10, end: 30};
var result = SSurveying.CreateCrossSections(firstComp, secondComp, axis, [], sections, options);
static Array< SComp > FromName(string name)
Search all the SComp with the given name.
Provide polyline edition and creation methods.
Definition: Reshaper.h:6133
static Array< SMultiline > FromName(string name)
Search all the SMultiline with the given name.
Parameters
firstComp(SComp) The first comp (could be a SPoly or a SCloud)
secondComp(SComp) The second comp, if any (could be a SPoly or a SCloud)
neutralAxis(SComp) The neutral axis along which sections are created
distanceList(Array<number>) The first option to create sections: define a list of distances
sections(Object) The second option to create sections: with a regular step
  • step: [Number] The step to create the sections
  • begin: [Number] The start of the range of values
  • end: [Number] The end of the range of values
options(Object) The data structure containing rendering options
  • sectionOrientation: [Number] Sections could be created vertically (value = 0) or locally perpendicular (value = 1)
  • isIn2D: [Boolean] Define if the curvilinear distance is computed in 2D (x,y) or in 3D (x,y,z)
  • prefix: [String] The prefix for the distance information
  • offset: [Number] The value added to the position of the section
  • removePtsValue: [Number] Remove points distant of more than this value. Choose 0 to deactivate this filter
  • activeNoiseReduction: [Boolean] Activate or not noise reduction (ONLY for SCloud)
  • planeThickness: [Number] All the points between two parallel planes distant from this value are taken into account to create the section (ONLY for SCloud)
  • chainingDistance: [Number] If the distance between two neighbor points is less than this value, a segment is created (ONLY for SCloud)
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
  • 2: A problem occurred during the reading of the sections parameter
  • 3: A problem occurred during the computation
ret.CompTbl(Array<SComp>) The table containing the computed objects: the table of points and the computed sections
ret.ReportData(SReportData) The SReportData containing all sections data, view set, ...

◆ EstimateScanDirFromTrajectory()

Object SSurveying::EstimateScanDirFromTrajectory ( SCloud  cloud,
STrajectory  trajectory 
)

Compute the scanning directions of a SCloud using a STrajectory. A new SCloud with scanning directions is returned.

Parameters
cloud(SCloud) The SCloud to use to compute the scanning directions
trajectory(STrajectory) The STrajectory
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: The timestamps information on the SCloud is missing
  • 2: An error occurred during the computation of the scanning directions
  • 3: An error occurred
ret.Cloud(SCloud) The SCloud with estimated scan dir

◆ ExtractGround()

Object SSurveying::ExtractGround ( SCloud  cloud,
number  step,
number  angleDeg,
SVector  direction,
number  groundExtractionStrategy,
number  meshingStrategy 
)

Extract points on the ground (in a grid) and create a SPoly corresponding to the terrain in the SCloud.

License
This function requires the license Survey.
Parameters
cloud(SCloud) The SCloud on which to extract ground
step(number) The dimension of the squares inside the SPoly
angleDeg(number) The max slope angle (in degree) of the terrain that can be seen on the ground. 0 means a terrain perfectly flat, in other words, perfectly perpendicular to the horizontal plane normal vector
direction(SVector) The normalized normal vector of the horizontal plane. Most of the time, this vector is (0, 0, 1)
groundExtractionStrategy(number) The ground extraction strategy
  • 0: Fast no noise filter
  • 1: Noise elimination
  • 2: Noise elimination and try to extend the extraction in the abrupt slopes
meshingStrategy(number) The meshing strategy
  • 0: Meshing a grid
  • 1: Meshing with the points of the original cloud
  • 2: Make a smooth mesh. This option is not compatible with the fast strategy extraction
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
  • 3: Invalid value for the Step or not enough memory for this value of the step
ret.PolyGround(SPoly) The SPoly representing the extracted ground
ret.GroundCloud(SCloud) The SCloud containing the points on the ground
ret.CloudNotOnGround(SCloud) The SCloud containing the points not on the ground
ret.CloudNoisy(SCloud) The SCloud containing the noisy points

◆ ExtractTunnel()

Object SSurveying::ExtractTunnel ( SCloud  initialCloud,
SMultiline  neutralAxis,
number  step,
TunnelComputedObj  computedObjects = SSurveying.TunnelMesh,
TunnelMeshingStrategy  meshingStrategy = SSurveying.FastMesh,
boolean  tryToKeepDetails = false 
)

Extract points on exterior layer of the tunnel and create a SPoly from those points.

License
This function requires the license Survey or AEC.
Parameters
initialCloud(SCloud) The initial SCloud of the tunnel
neutralAxis(SMultiline) The neutral axis of the tunnel
step(number) The step to travel along the neutral axis. This value directly implies: output mesh density and number of slices
computedObjects(TunnelComputedObj) Choose the objects to extract
meshingStrategy(TunnelMeshingStrategy) The meshing strategy
tryToKeepDetails(boolean) The options of tunnel extraction processing
  • false: Simple SCloud extraction using distance
  • true: SCloud extraction using distance and normal continuity (=try to keep details)
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: A problem occurred during mesh extraction
  • 2: A problem occurred during cloud split
  • 3: Invalid value for the Step or not enough memory for this value of the step
  • 4: An error occurred
  • 5: An escape exception occurred
ret.Poly(SPoly) The SPoly corresponding to the tunnel shape
ret.Cloud(SCloud) The SCloud containing the points on the tunnel
ret.CloudNoisy(SCloud) The SCloud containing the points that are not on the tunnel

◆ FilterFeatureLines()

Object SSurveying::FilterFeatureLines ( SSetMultiline  ridgeLines,
SSetMultiline  ravineLines,
number  length,
number  pertinence 
)

Filter feature lines according to their length/pertinence.

Parameters
ridgeLines(SSetMultiline) The convex lines to filter
ravineLines(SSetMultiline) The concave lines to filter
length(number) The minimal length threshold
pertinence(number) The minimal pertinence threshold (between 0 and 1)
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.SetMultiTbl(Array<SSetMultiline>) The table of SSetMultiline containing successively the filtered convex (item 0) and concave lines (item 1)

◆ FlattenCylindricCloud()

Object SSurveying::FlattenCylindricCloud ( SCloud  cloudToFlatten,
SMultiline  axis,
number  radius,
boolean  withRelief = false,
SVector  direction = SVector(),
Object  gridOptions = {} 
)

Flatten a SCloud representing a tubular shape (for example a tunnel)

License
This function requires the license Survey or Tank or Plant.
Note
Example to fill the gridOptions array:
var cloud = SCloud.FromSel()[0];
var neutralAxis = SMultiline.FromClick().Multi;
var gridOptions = {SizeOfRow: 10, SizeOfCol: 5, NumberOfSubRow: 2, NumberOfSubCol: 2, ShowGraduation: true};
var result = SSurveying.FlattenCylindricPoly(cloud, neutralAxis, 10, true, SVector.New(0, 0, 1), gridOptions);
static Array< SCloud > FromSel()
Get all the selected SCloud.
static Object FromClick()
Launch an interaction to select a SMultiline in the scene.
Parameters
cloudToFlatten(SCloud) The SCloud to flatten
axis(SMultiline) The neutral axis of the SCloud
radius(number) The mean radius of the SCloud
withRelief(boolean) Should the relief be preserved?
direction(SVector) The direction to project the axis
gridOptions(Object) The array of grid options
  • SizeOfRow: [Number] The size of the rows
  • SizeOfCol: [Number] The size of the columns
  • NumberOfSubRow: [Number] The number of sub rows
  • NumberOfSubCol: [Number] The number of sub columns
  • ShowGraduation: [Boolean] Should graduations be shown?
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.Cloud(SCloud) The flattened SCloud
ret.ReportData(SReportData) The SReportData containing the unroll data

◆ FlattenCylindricPoly()

Object SSurveying::FlattenCylindricPoly ( SPoly  polyToFlatten,
SMultiline  axis,
number  radius,
boolean  withRelief = false,
SVector  direction = SVector(),
Object  gridOptions = {} 
)

Flatten a SPoly representing a tubular shape (for example a tunnel)

License
This function requires the license Survey or Tank or Plant.
Note
Example to fill the gridOptions array:
var poly = SPoly.FromSel()[0];
var neutralAxis = SMultiline.FromClick().Multi;
var gridOptions = {SizeOfRow: 10, SizeOfCol: 5, NumberOfSubRow: 2, NumberOfSubCol: 2, ShowGraduation: true};
var result = SSurveying.FlattenCylindricPoly(poly, neutralAxis, 10, true, SVector.New(0, 0, 1), gridOptions);
static Array< SPoly > FromSel()
Get all the selected SPoly.
Parameters
polyToFlatten(SPoly) The SPoly to flatten
axis(SMultiline) The neutral axis of the SPoly
radius(number) The mean radius of the SPoly
withRelief(boolean) Should the relief be preserved?
direction(SVector) The direction to project the axis
gridOptions(Object) The array of grid options
  • SizeOfRow: [Number] The size of the rows
  • SizeOfCol: [Number] The size of the columns
  • NumberOfSubRow: [Number] The number of sub rows
  • NumberOfSubCol: [Number] The number of sub columns
  • ShowGraduation: [Boolean] Should graduations be shown?
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.Poly(SPoly) The flattened SPoly
ret.ReportData(SReportData) The SReportData containing the unroll data

◆ FloorFlatness()

Object SSurveying::FloorFlatness ( Array< SComp compsToTreat,
SVector  direction,
number  rulerLength,
number  tolerance 
)

Compute a floor flatness analysis on SPoly or SCloud.

License
This function requires the license Survey or AEC.
Parameters
compsToTreat(Array<SComp>) The objects to use (only SPoly or SCloud are processed)
direction(SVector) The normalized normal vector of the horizontal plane. Most of the time, this vector is (0, 0, 1)
rulerLength(number) The ruler length
tolerance(number) The tolerance
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred during the slope computation
  • 2: An error occurred
ret.PolyTbl(Array<SPoly>) The table containing the new colored SPoly representing flatness on input SPoly
ret.CloudTbl(Array<SCloud>) The table containing the new colored SCloud representing flatness on input SCloud
ret.ReportData(SReportData) The SReportdata containing the floor flatness data

◆ SlopeAnalysis()

Object SSurveying::SlopeAnalysis ( Array< SComp compsToTreat,
number  slopeTolerance,
boolean  isPercentage,
number  neighborsDistance = 0,
SVector  upVector = SVector() 
)

Get the slope on each point of the object.

License
This function requires the license Survey or AEC.
Parameters
compsToTreat(Array<SComp>) The objects to use (only SPoly or SCloud are processed)
slopeTolerance(number) The slope tolerance, in degrees
isPercentage(boolean) Should the results be displayed in percentage?
neighborsDistance(number) This distance will be used to approximate the normal ( > 0) (searching the neighbors at this distance). If neighborsDistance <= 0 then neighborsDistance = cloud.GetMeanDistance()*2.0;
upVector(SVector) The vector used as Up vector for slope computation
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred during the slope computation
  • 2: An error occurred
ret.PolyTbl(Array<SPoly>) The table containing the new colored SPoly representing slope on input SPoly
ret.CloudTbl(Array<SCloud>) The table containing the new colored SCloud representing slope on input SCloud
ret.ReportData(SReportData) The SReportData containing the slope analysis data

◆ SurfaceLevelness()

Object SSurveying::SurfaceLevelness ( Array< SComp compsToTreat,
SVector  direction,
SPoint  planePosition 
)

Compute a surface levelness analysis on SPoly or SCloud.

License
This function requires the license Survey or AEC.
Parameters
compsToTreat(Array<SComp>) The objects to use (only SPoly or SCloud are processed)
direction(SVector) The normal direction of the analysis
planePosition(SPoint) The point to define the origin
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred during the cloud computation
  • 2: An error occurred during the mesh computation
  • 3: An error occurred
ret.PolyTbl(Array<SPoly>) The table containing the new colored SPoly representing levelness on input SPoly
ret.CloudTbl(Array<SCloud>) The table containing the new colored SCloud representing levelness on input SCloud
ret.ReportData(SReportData) The SReportData containing surface levelness data

◆ UnrollAlong()

Object SSurveying::UnrollAlong ( Array< SMultiline multisToUnroll,
SMultiline  axis,
number  altiRef 
)

Unroll SMultiline along an axis.

License
This function requires the license Survey.
Parameters
multisToUnroll(Array<SMultiline>) The SMultiline to unroll
axis(SMultiline) The axis for the unroll
altiRef(number) The reference altitude to use for the unroll
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: An error occurred
ret.SetMulti(SSetMultiline) The SSetMultiline of unrolled SMultiline
ret.ReportData(SReportData) The SReportData containing the unroll along axis data

◆ WallsAndFloors()

Object SSurveying::WallsAndFloors ( Array< SCloud cloudsToTreat,
Object  options 
)

Segment walls, floors and ceilings from a SCloud.

License
This function requires the license Survey or AEC.
Note
Example to fill the options array:
var clouds = SCloud.FromSel();
var options = { segmentWalls: true, segmentFloorsAndCeilings: true, segmentOther: false,
wallsTolerance: 5, floorsTolerance: 5, localNormalSmoothing: 0.125 };
var result = SSurveying.WallsAndFloors(clouds, options);
Parameters
cloudsToTreat(Array<SCloud>) The SCloud to use
options(Object) The data structure containing computation options
  • segmentWalls: [Boolean] Segment walls, or not
  • segmentFloorsAndCeilings: [Boolean] Segment floors and ceilings, or not. If the scanning directions are available, the floors and the ceilings will be separated, otherwise they will be merged
  • segmentOther: [Boolean] Segment other points, or not
  • wallsTolerance: [Number] The angular tolerance for walls segmentation, between 0 and 10 degrees
  • floorsTolerance: [Number] The angular tolerance for floors segmentation between, 0 and 10 degrees
  • localNormalSmoothing: [Number] The radius of the influence zone on the SCloud, between 0 and 1
Return values
ret.ErrorCode(number) The error code
  • 0: No error
  • 1: The wall angle is too low/high (must be between 0 and 10)
  • 2: The floor angle is too low/high (must be between 0 and 10)
  • 3: The local normal smoothing is too low/high (must be between 0 and 1)
  • 4: An error occurred
ret.WallsTbl(Array<SCloud>) The table containing the computed SCloud corresponding to walls
ret.FloorsTbl(Array<SCloud>) The table containing the computed SCloud corresponding to the floors (if scanning directions are available)
ret.CeilingsTbl(Array<SCloud>) The table containing the computed SCloud corresponding to ceilings (if scanning directions are available)
ret.FloorsCeilingsTbl(Array<SCloud>) The table containing the computed SCloud corresponding to both floors and ceilings (if scanning directions are not available)
ret.OtherTbl(Array<SCloud>) The table containing the computed SCloud corresponding to other points