Jump to content

L-system Local Variable (g vs t)


kidsreturnjj

Recommended Posts

There is a subtle but important difference. There are probably better L-system experts than me, but hopefully I won't spread misinformation here...

First thing to know is that (at least this is what I concluded) for each letter in the generated L-system string, Houdini seems to store the number of iteration when the letter is added to the final string. So Houdini knows when each letter was generated.

Now, the difference between g and t is that one refers to this stored iteration value, the other refers to the current iteration value (I don't recall which is which, though).

I ran into this when I wanted to build a tree, where for the first few iterations only the trunk was created -- with letters in it that started to grow branches after a given generation count (so instead of growing a tree with shorter branches at the top, I wanted equal-length ones, hopefully I'm making some sense here...). In other words, I wrote a rule to expand the branch letters after the L-system ran for say 10 iterations (that allowed only the trunk to grow.)

It could be done using one of the letters (g/t) but not the other. Don't remember which but it takes only 2 tries to find out. ;) L-systems can be mind-bending, and there are some features that not even documented or just hinted in the docs.

(I really wouldn't like to spread stupidity, though, so please anyone correct me if I'm wrong. This was quite some time ago.)

cheers,

imre

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...