Making a convincing looking plant

Discussions regarding modelling with SOFTIMAGE©
User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Making a convincing looking plant

Post by shushens » 27 Jul 2009, 01:52

Hey guys, I am here today with some questions on modelling.

Here is a small tree I made using one of the Onyx softwares:

Image

As you can see, the leaves are so low-poly, that it's impossible to make them look convincing. I can raise resolution of the leaves, of course, but that doesn't help at all, because I cannot apply the fold/bend/twist modifiers to individual polygon islands but only on the whole object. So how to I add some randomness in the shape of the leaves and add some curl to those at random? Is there a way to isolate all polygon islands as separate meshes? Will it work then?

The second question is, if I fail to do all this, and am forced to replace those leaves with my own, how do I do that? I have read 'Making Of's in the Evermotion website that spoke of such a total leaf replacement in a tree, but I cannot imagine how that is possible without manually putting every leaf in place or executing some fairly complex algorithm (which I also know nothing about).

Thanks in advance!

The suggestion does not essentially have to be about XSI. I can try to do it in some other software as well, if I must.
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 27 Jul 2009, 06:34

To isolate all polygon islands as separate meshes Helge Mathee posted a script @ XSIBlog a while back: follow this link

Hope it helps somewhat... ;)
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 27 Jul 2009, 07:50

Thank you very much Hirazi! I do visit XSIBlog often and did try it. But it's giving me many syntax errors. I do know Python, but JScript is not my strong suite. Can you test it yourself and tell me if it is running there perfectly? I am using XSI 7.5 32bit.
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 27 Jul 2009, 09:08

Seems to work just fine over here (i.e. no syntax errors)
Did you change the scripting language to jscript? Sorry I had to ask!!! :ymblushing:

I used the following workflow (but that may not be the way Helge Mathee intended it):
select all clusters
select members/components
extract polygons
run script

This leaves (no pun intended) the original extracted objects intact: you can delete it...

If it still doesn't work, please copy some of the error messages you get...
;)
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 27 Jul 2009, 15:23

I played around with this thing a little bit, and all the errors are being thrown at for loop statements. Ideally, a for loop statement should hold 3 clauses, Helge's have four. If I erase one and make it 3 again, it runs all the way, but nothing happens really.

Image
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 27 Jul 2009, 15:33

You're right: there is something wrong...
I took the version I used from another forum (xsiforum.de).
On XSIBlog something went wrong with the text formatting.
I'll send you a private message... ;)
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 27 Jul 2009, 17:23

Much appreciated, Hirazi! You read German? That's definitely a big advantage. I could not use a lot of very good forums because I could not read German or Russian. I will give this a go and see how I can make the leaves look a bit more convincing.

:)
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 28 Jul 2009, 02:34

This time the script did work, but unfortunately, I don't think it will serve my purpose. Simply because, while extracting, it only minded the geometry, did not take the UVs into consideration. So now the leaves have nice deformations, but no UVs. I tried 3 things. One is GATOR, which is giving horrible result. The other is Mudbox, which is not being able to display any added UVs. Zbrush finally could reclaim UVs from the original model. There are minor issues that can be manually fixed. But in the process, Zbrush totally ruined those nice deformations. After reprojecting higher subdiv, (good thing I made some just in case) I got a very very tiny bit of it back, but pretty much 80% of it is gone.

So, is there some other way I can make that tree more convincing? If I create some goodlooking leaves, is there a smart way to populate that tree with those leaves avoiding hair instancing or manual placement?

It does not have to be an XSI trick.
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 28 Jul 2009, 05:14

Well, I would have to look into it, but it must be possible to alter the script to consider UV's also. I don't know if my scripting abilities are sufficient to complete such a task. But I am willing to try (could take some time though!). ;)
Would you be willing to (privately) share your tree model, so I would have something to work with?
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 28 Jul 2009, 05:41

Absolutely! Would you be interested in a whole WiP thread? If you guys give me some good advice, it will mean so much to me! I have been an XSI enthusiast for years, but I live in a country that is oblivious to its existence.

I would love to share it in public, my friend. If anyone puts it to good use, I have no problem with that.

Code: Select all

http://www.mediafire.com/?sharekey=49d691727f4c602fc2b435915e8821d7e04e75f6e8ebb871
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 28 Jul 2009, 08:00

Okay, I looked into it for a while. But as I will be unable to look into it further until tonight, I thought it best to share what I've found out so far.

After some consideration (and luckily before I started my attempt at rewriting the aforementioned script #:-s ), I found a script that does the trick even better, as we aren't really interested in polygon islands, but in the whole cluster... It's part of the so-called "Legacy Netview Database" and is called "Polygon Cluster Detach" (found under "render / modify") by Olivier Ozoux
Description: Create a new object with each polygon cluster, preserving UV and materials.
The rest of this post has been deleted for reasons of extreme inaccuracy! (See next post)
Stay safe, sane & healthy!

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 28 Jul 2009, 18:00

Note to self: don't post whilst in a hurry!!!
After my initial reaction this morning, which I have partially deleted again (because my texturing knowwledge and skills turned out to be even poorer than I initially suspected :ymblushing: :D), I would propose the following, using two scripts from the aforementioned "Legacy Netview":

1 run the [legacy netview: model / create] "Polygon Separation Clusters" script to create individual clusters for every leaf
2 select all the clusters created in step 1
3 run the [legacy netview: model / create] "Polygon Cluster Detach" script to create individual objects for every leaf cluster
4 create a group of all the leaf-objects
5 apply the leaf-material to the group

No idea, if this helps in any way, but I sincerely hope so! :ympray:
As a side-effect, this all has made it abundantly clear to me,
I need to despately improve upon my texturing skills!!! %-(
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 28 Jul 2009, 21:58

Awwww man, you're too modest! You really don't have to say all that. Yeah I was gonna say that how do I define the islands as clusters first? hehehehe The thing is... I am like a person grown up in isolation. I never used netView, and I am not a big forumite either. I stayed home, kept tinkering with this and that... that's mostly how I learnt things... so my knowledge is often outdated and/or incomplete.

I really appreciate this effort you're making. Any suggestions on how to apply some convincing looking deformations on the leaves once they are all separated? I used Fold deformer last time. But with these deformers, no matter which axis you choose, a decent percentage of the leaves will always be in parallel with the same. I just accepted it because who would check the leaves one by one anyway?

And may I know if you would like to watch a full WiP thread? It probably won't be a long one, since the shot I planned is rather simple.
My ill-maintained blog: http://visualdeceptions.info/blogger

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 29 Jul 2009, 05:34

The deformations are something I wanted to look into myself also, so I'll get back to you on this. To me this is a nice learning experience or at least a welcome refresher to stuff I already mostly forgot... :D

WIP-Thread? Sounds like a great idea to me!!! :-bd

BTW: The old Netview is a part of XSI/Softimage that is often overlooked, while there you can still find a lot of very useful stuff in there...
Stay safe, sane & healthy!

User avatar
Hirazi Blue
Administrator
Posts: 5113
Joined: 04 Jun 2009, 10:15

Re: Making a convincing looking plant

Post by Hirazi Blue » 29 Jul 2009, 11:10

Tiny update, things that came up while playing with your plant/tree. Don't know if this is useful, but I wanted to add it anyway:
Every leaf has the same point order, so selecting individual points on every leaf is just a matter of good use of the "*"-wildcard while relatively easy that way...

In my test (after subdividing twice!) there were four vertices that made up the top corner of a leaf, called "pnt[0,4,9,58,69]", my leaves were called "Polygon_Fragment1" till "Polygon_Fragment506", grouped under a group named "leaveme". Selecting all the vertices at the top of the leaves would require the following simple select command: Application.SelectObj("leaveme.Polygon*.pnt[0,4,9,58,69]")
Creating named clusters obviously improves usability even more... I called the these point clusters "top" and selected them with "Application.SelectObj("leaveme.Polygon*.cls.top") and then used "Select Members/Components" to actually select all individual points.


Pinning the leaves into place before deforming seems to be a good idea and moving the object centers of every leaf to the "top"-point cluster vertices before pinning probably is too. And freezing the transforms after moving the center helps too!!!
Stay safe, sane & healthy!

User avatar
shushens
Posts: 192
Joined: 13 Jun 2009, 05:34
Skype: shushens
Location: Paderborn, Germany

Re: Making a convincing looking plant

Post by shushens » 29 Jul 2009, 14:26

Man, you're my hero! You know, I used to be a Python developer, but I never tried to write scripts for any 3D app. You are inspiring me a great deal to learn this seriously. If this is not too off topic, where should I begin with XSI scripting? There used to be a scripting DVD from 3DTutorials which later got released for free by Letterbox studios. Do you think it is a good place to start?

I absolutely agree, pinning them down is the first step that makes sense :) Will look into it right now. Sorry for being so slow in response. I have been having some trouble with Mudbox.

I shall post the WiP thread now :) and then work on the tree :)
My ill-maintained blog: http://visualdeceptions.info/blogger