I have been learning C# over the past few years and am now developing a set of custom components that will produce GCode for a specialized 5 AXIS CNC machine. The CAM step - that of reducing a block of raw material to a desired shape, requires parameters and computations that produce tool path instructions. The generation of tool paths is an expensive computation that includes large volumes of data - points, transforms, offsets, meshes, etc.
Based on my Forum research, it is suggested that the custom component(s) should be kept light as far as processing burden, and push the heavy lifting to a separate DLL. In my case, GH_Components better serve to visualize/evaluate the results of intermediate steps and not be required to input or output the massive computational data needed for the final GCode.
My initial question involves passing a number of component input values by first packaging the data within a class. Later, I would like to pass class(s) from an external DLL back into custom components allowing for visualization of processed data. Initial tests show that when a class definition resides in an external DLL and that DLL is referenced to the Validate component, an instance of the jobparams class is created as a local variable in the component. VS debugging shows that this works fine. My goal is to forward jobparams for use by the DLL in subsequent processing without the inefficiencies of outputs.
Declaring a public GetData jobpararms; outside the SolveInstance() method does not make jobparams available to the DLL.
I have tried outputting the jobparams instance to a DA.SetData(), but that kind of defeats the purpose. The receiver is a DLL and not another GH_Component.
I have also tried using the OnPingDocument() method suggest in the Forum but get the following error.
Thanks ahead for your advice.