Grasshopper

algorithmic modeling for Rhino

Hi everybody,

I’m trying to use Karamba through Node-in-Code. This seems to work right, but any components such as Supportkaramba, Loadskaramba, BeamViewkaramba, have radio button, flag or slider in the grasshopper canvas. How can I set these variables in the GhPython code?

Thanks,

Gianpaolo

Views: 461

Replies to This Discussion

Hi Gianpaolo,


It's definitely better to wait for Clemens to answer this question, but until then, you can't access those components through node-in-code functions. You could probably access it by importing karamba's assembly. Check the Karamba Hacker's Guide.

Thanks,

by Nonde-in-Code you can use all the grasshopper and related Add-on in GHpython or RhinoPython. For example you can analyze a model without "import karamba", "import feb" etc., using this simple code:

import ghpythonlib.components as gc

gc.karamba.AnalyzeThIkaramba(model)

Thanks again,

Gianpaolo

Hi Gianpaolo,

The fact that a certain grasshopper component can be called by node-in-code function, does not mean you can use it. An example for grasshopper native components are: "Text tag", "Custom preview", "Vector display" function.

An example for karamba components are those that can be used but with limited functionality. You can call the "Support" function but you can not define the support conditions. You can call the "Loads" function but you can not define the type of the load. And so on, like you have already noticed by yourself.
So no, there is no way to access these functionalities through node-in-code. You might be able to access them through referenced .gha file.
Please check the upper Hacker's guide I attached. It has a nice examples for a couple of languages, python being one of them.

Regards,
djordje

Thanks djordje,
I know the Hacker's guide, and I tried to access to Karamba directly through referenced .gha file. In this way I found few trouble (e.g. utilization not updated, difference in the utilization computation using gh and python, input model seems modified), so I was looking for an alternative.

Best,

g

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service