Grasshopper

algorithmic modeling for Rhino

ghpythonlib.components.GraftTree not working?, Some other questions

I was just wondering why the GraftTree and FlattenTree components were not working inside python. 

Other Tree components were working fine.

I was also wondering about this statement by Steve Baer "You will need to have used the component in grasshopper at least once. We will fix the “at least once” issue in a future release of ghPython."

Does this hold true till now?

Does choosing an access type have any effect when using ghpythonlib.components?, i.e. i noticed that whether or not I used Item Access, List or Tree, the results remained the same. Or does this have any hidden effects?

-----

Also, is there any available documentation on ghdoc? 

I was also playing around with some of the available imports, I noticed GhPython.

Specifically, I noticed that ghenv and GhPython.Component.PythonEnvironment had exactly the same attributes and methods, although their returns were different, i.e.

GhPython.Component.PythonEnvironment returned things like <property# Component on PythonEnvironment> could it be that ghenv is an instance of GhPython.Component.PythonEnvironment?

Could someone explain this in a bit more detail?

 

Is there any documentation on GhPython as well? and how it's used?

Thanks in advance.

Views: 550

Attachments:

Replies to This Discussion

Hi!components does not have a founction named GraftTree() or FlattenTree().

Attachments:

Thanks. I had no idea there were built-in Graft and Flatten functions.

About the second question, you are right: ghenv is an instance of PythonEnvironment. It is part of the GhPython assembly, for which we are not providing documentation at this time because it's the source of the component itself, but its reference implementation for V5 is on GitHub.

I see, that makes sense, thanks!

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service