Willem
(Willem Derks)
October 20, 2018, 6:56pm
2
Hi revink,
Not a specific answer to you question but rather a few links to guide you into RhinoCommon. This way you know how to see how methods like ObjectsByLayer use RhinoCommon
Also to format python code in a post use this wrapper:
```python
code here
```
Translates to:
code here
The links:
Yes,
Have a look at these screenshots from the editor.
You can click at the position of the red dot to insert a breakpoint.
This will halt the script at that point and you can inspect the content of the current variables:
[image]
[image]
[image]
More to find on rhinocommon:
https://developer.rhino3d.com/api/RhinoCommon/html/N_Rhino.htm# !
search for plane for example:
[image]
[image]
A good way to explore working with rhino common in python is to insert breakpoints before a rhino…
Continuing the discussion from Is this the best way to automatically update linked blocks? :
Hi Jorgen,
Below a description on how I find my way in RhinoCommon through Python:
starting with the code:
import rhinoscriptsyntax as rs
blockList=rs.BlockNames()
I put a debug breakpoint at the last line:
[image]
Run the code with the green arrow (F5).
The script stops at line 2 and you get options to continue, StepInto SetOver over …etc
Choose StepInto
[image]
The script will step into the …
Hello all,
I’ve inherited some ghPython code which is being used to convert a number of different geometry types to meshes. Right at the start of the code there’s a call to “rs.coercegeometry”. After some poking around, it looks like the documentation for the rs.coerceX functions hasn’t been published yet. This leaves me in a slightly uncomfortable position - I’ve got a big black box right at the start of a piece of code which I’m refactoring, and only the vaguest idea of what it does.
This…
Let us know if you have more questions.
-Willem