PrismCarveParameterData: Difference between revisions

From SDK
Jump to navigation Jump to search
(Created page with "right|50px|link=Toolpaths Category:SDK This object is used to hold the settings for a prism carving toolpath. ==Constructor== ===PrismCarveParameterD...")
 
No edit summary
 
Line 21: Line 21:
'''Interaction:''' Read and Write
'''Interaction:''' Read and Write


'''Returns:''' (double) Final cutting depth below start depth
'''Returns:''' (double) Final cutting depth below start depth




===.CutDepthFormula===
===.CutDepthFormula===
'''Interaction:''' '''Interaction:''' Read and Write
'''Interaction:''' Read and Write
'''Returns:''' (string) Formula for cut depth below start depth
 
'''Returns:''' (string) Formula for cut depth below start depth




Line 32: Line 33:
'''Interaction:''' Read and Write
'''Interaction:''' Read and Write


'''Returns:''' (integer) Cutting direction for toolpath.  
'''Returns:''' (integer) Cutting direction for toolpath. Valid values are:
 
ProfileParameterData.CLIMB_DIRECTION
::''Valid values are: ''
ProfileParameterData.CONVENTIONAL_DIRECTION
:::::''ProfileParameterData.CLIMB_DIRECTION''
:::::''ProfileParameterData.CONVENTIONAL_DIRECTION''




Line 44: Line 43:
'''Interaction:''' Read and Write
'''Interaction:''' Read and Write


'''Returns:''' (string) The name for the toolpath
'''Returns:''' (string) The name for the toolpath




Line 52: Line 51:
'''Interaction:''' Read and Write
'''Interaction:''' Read and Write


'''Returns:''' (double) Start depth for toolpath below material surface
'''Returns:''' (double) Start depth for toolpath below material surface




Line 58: Line 57:
'''Interaction:''' '''Interaction:''' Read and Write
'''Interaction:''' '''Interaction:''' Read and Write


'''Returns:''' (string) Formula for start depth for toolpath below material surface
'''Returns:''' (string) Formula for start depth for toolpath below material surface
 
''Note: Direction constants use ProfileParameterData. NOT PrismCarveParameterData.''
''Note: Direction constants use ProfileParameterData. NOT PrismCarveParameterData.''


Line 66: Line 66:


===:CalculateMinimumBevelDepth(Tool tool, bool show_warnings)===
===:CalculateMinimumBevelDepth(Tool tool, bool show_warnings)===
'''Returns:''' (the minimum cut depth required with the passed tool for the currently selected vectors.  Tool (Tool) Tool to use for the toolpath
'''Returns:''' (the minimum cut depth required with the passed tool for the currently selected vectors.  Tool (Tool) Tool to use for the toolpath
show_warnings (bool) if true display warning to user if tool not suitable of vectors not selected
show_warnings (bool) if true display warning to user if tool not suitable of vectors not selected

Latest revision as of 18:37, 1 May 2024

Back.jpg

This object is used to hold the settings for a prism carving toolpath.


Constructor

PrismCarveParameterData()

Create a new object ready to have its parameters set


For Example:

 local prism_data = PrismCarveParameterData() 

Properties

.CutDepth

Interaction: Read and Write

Returns: (double) Final cutting depth below start depth


.CutDepthFormula

Interaction: Read and Write

Returns: (string) Formula for cut depth below start depth


.CutDirection

Interaction: Read and Write

Returns: (integer) Cutting direction for toolpath. Valid values are:
ProfileParameterData.CLIMB_DIRECTION
ProfileParameterData.CONVENTIONAL_DIRECTION



.Name

Interaction: Read and Write

Returns: (string) The name for the toolpath



.StartDepth

Interaction: Read and Write

Returns: (double) Start depth for toolpath below material surface


.StartDepthFormula

Interaction: Interaction: Read and Write

Returns: (string) Formula for start depth for toolpath below material surface

Note: Direction constants use ProfileParameterData. NOT PrismCarveParameterData.


Methods

:CalculateMinimumBevelDepth(Tool tool, bool show_warnings)

Returns: (the minimum cut depth required with the passed tool for the currently selected vectors. Tool (Tool) Tool to use for the toolpath show_warnings (bool) if true display warning to user if tool not suitable of vectors not selected


For Example:

 -- Create  object used to pass toolpath options
local prism_data = PrismCarveParameterData()
 -- start depth for toolpath
prism_data.StartDepth = start_depth

 -- cut depth for toolpath this is depth below start depth
prism_data.CutDepth = cut_depth

 -- direction of cut for offet clearance ProfileParameterData.CLIMB_DIRECTION or
 -- ProfileParameterData.CONVENTIONAL_DIRECTION. NOTE: enum from ProfileParameterData
prism_data.CutDirection = ProfileParameterData.CLIMB_DIRECTION
 -- calculate the minimum cut depth to fully form the bevel on the current selection
 -- with the current tool
local min_bevel_depth = prism_data:CalculateMinimumBevelDepth(tool, true)
if min_bevel_depth > cut_depth then
DisplayMessageBox("A prism will not be fully formed with a depth of "   cut_depth    "\r\n"
"A depth of "   min_bevel_depth   " is required to fully form the prism"  ) 


Back.jpg

References

Please Note: The base material for the contents found in this WiKi was sourced from Vectric Lua Interface for Gadgets, version 2.05, published September 12, 2018. by Vectric Ltd. Most current document from Vertric can be downloaded at Vertric Developer Information