Individual Bake Name (Elefront) - with python?

Hi there,

i use Elefront to bake my objects with bake names. I love that it replaces the objects with same bake name that already exist.

But - when I don’t want to bake again all the objects, just a selection, all the others are gone.

Now I want to give the objects bake names by a list. But with the bake process, I can give all baked objects only the same name.

Does anyone know how to access bake names with python maybe? Or have another solution to generate a loop for baking objects?

Thanks

I’m using Elefront a lot in my projects. I would split the objects in multiple lists or trees according to bake names. Use not just one Elefront bake component but a few. You will have to use separate buttons to bake geometry.

Thanks for your response.
My intent is a Tool for Grasshopper Player. So every time, there might be choosen different Lines - just the ones which were changed last.

I included my files to show my intent.

Thats why I would need something to loop through the names of my objects (curves) to give every bake object an individual bakename.

mirror_bakename.gh (13.6 KB)
mirror_bakeName_lines.3dm (43.1 KB)

You can create your own delete tool with a simple python script and I think you could use Object Names to do this. Not sure how you could select objects based on User Attributes.

21_11_30_delete_objects.gh (4.8 KB)

Thanks Martin,
That works for me :slight_smile:

Need to dive deeper into Python - there’s so much potential there!

Definitely. I’ve been using simple scripts I found online and should learn more

Python is a great skill to have under your belt, even beyond Rhino and Grasshopper.

Sounds like you got your solution! But, if there’s interest in trying to figure out how to do this with Elefront, I’m curious to understand a bit better what you’re trying to do.

It seems you want to bake some geometry that has the same bakename, but without losing the old geometry.

The way I would usually approach something like that, if I wanted to “replace” a subset of items that share a bakename, is:

  • I would use Reference by BakeName to bring the geometry in
  • Create some logic to separate the items you want to keep, and items you want to modify
  • Do whatever modifications you want
  • Merge the two streams back together, going into the Bake Component
  • Hit “Bake”, and then you will have both the new items, and the old items get “rebaked” at the same time.

Would that work, or are you trying to do something different?

3 Likes

Hi Krahimzadeh,

Think you got it pretty much what my intention is.

I created a tool for GHPlayer to create, for example some new geometry with bakename x using a source geometry.
Now some parts of the source geometry have changed and the changed part is now chosen to be adapted by my tool. But if the partial geometry receives the same bakename x, all of the not chosen geometry is lost.

So your plan should work pretty good with using just elefront! Will try on Monday. Sounds promising to me :grinning_face_with_smiling_eyes: