Auto Scripted 3D rig. Files and Video Tutorial

Have you come up with a good Moho trick? Need help solving an animation problem? Come on in.

Moderators: Víctor Paredes, Belgarath, slowtiger

User avatar
Víctor Paredes
Site Admin
Posts: 5658
Joined: Wed Jan 26, 2005 12:18 am
Location: Barcelona/Chile
Contact:

Post by Víctor Paredes »

genete! Heyvern!
this is great. wow. it escapes of my brain.
i'm now playing whit the script, it is so easy and useful and perfect. thank you thank you thank you!. e-frontier should finance every new thread you open.
wow. i hope lostmarble be seeing this.

you both are genius!!
and i will come late to university because i'm praising you.


thank you again!
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

selgin wrote:genete! Heyvern!
this is great. wow. it escapes of my brain.
i'm now playing whit the script, it is so easy and useful and perfect. thank you thank you thank you!. e-frontier should finance every new thread you open.
wow. i hope lostmarble be seeing this.

you both are genius!!
and i will come late to university because i'm praising you.


thank you again!
You're always welcome dear selgin.
Please! use those tools to create any of your smart-beauty-sensible-funny animations!!!
:)
-G
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

I have to say it would have taken 10 times as long to get to this point if it was just me writing the lua scripts.

I kept thinking in my head in the beginning of this thing how hard it would be to do the bone generation scripting, and shape ordering.

Then suddenly... Genete turns into a lua programmer!!! ;) I fell off my chair when I saw that.

What a relief that was! He did most of the hard work with auto bone generation and shape ordering. That part is the true power of the technique (and I plan to steal that cool trick for my own custom rigs AND for the copy/paste bone script).

I breathed a sigh of relief when he started producing his own lua code.

I am very proud to have been a part of this and also to BENEFIT from it!!! It's so much easier to learn these techniques when you help to develop them. ;)

I would like to think of you Genete as a friend and a wonderful collaborator.

I think we make a pretty good team! And your english has improved 1000%... not that that is really important... it does help us lazy one language people. ;)

-vern
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

heyvern wrote:I would like to think of you Genete as a friend and a wonderful collaborator.
Same feeling Vern, same feeling.

Now the limits are only in your imagination..

http://www.darthfurby.com/genete/Other/ ... pepino.zip
http://www.darthfurby.com/genete/Other/ ... pepino.swf

:wink:
-G
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

Holly cow!!!! :shock: :shock:

Try doing THAT with an imported .obj file!!!!

Amazing! Yeeeehaaaa!

Oh good grief... Genete! We just turned AS into a 3D application!! ;)

-vern
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

I just had a really scary thought... this one will keep me up tonight with scary dreams.

Theoretically... you could design a head turn that includes THE BACK of the head in one file!

Imagine, any angle of a head turn including the top and back. I will have to play around with this. It would requiring breaking up the head shape into a "grid" like your crazy spinning... thingy.

There is one other thing I must attempt... my hairy brush technique. I have to make a fuzzy hair thing that spins around like that just to see what happens. ;)

I'm getting sleepy already. ;)

-vern
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

heyvern wrote:
Holly cow!!!! :shock: :shock:

Try doing THAT with an imported .obj file!!!!

Amazing! Yeeeehaaaa!

Oh good grief... Genete! We just turned AS into a 3D application!! ;)

-vern
I insist: It is only a tool... We (I) don't want to convert Anime Studio into a 3D application but ... But if you if you're in a hurry and need some sort of 3D stuff... here are the tools... :wink:
I just had a really scary thought... this one will keep me up tonight with scary dreams.

Theoretically... you could design a head turn that includes THE BACK of the head in one file!

Imagine, any angle of a head turn including the top and back. I will have to play around with this. It would requiring breaking up the head shape into a "grid" like your crazy spinning... thingy.

There is one other thing I must attempt... my hairy brush technique. I have to make a fuzzy hair thing that spins around like that just to see what happens. Wink

I'm getting sleepy already.

-vern
Not theoretically... you can do it in practice!!.
BTW, pepino == cucumber :lol:
I'm sorry if I steal your sleep :wink:
I prognostic a nightmare made of hunting cucumbers with fuzzy 3D hair spinning around...

LOL!!
-G
User avatar
Víctor Paredes
Site Admin
Posts: 5658
Joined: Wed Jan 26, 2005 12:18 am
Location: Barcelona/Chile
Contact:

Post by Víctor Paredes »

am I the only one who saw a Pepino and not a "spinning thingy"? :wink:
you are so close of the complete head turn. this is exciting.
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

Genete,

When you get a chance... just for fun. If you have any "magic math" for doing that "canonical" projection or "3D" distortion.

I am reading up on this and I think it is possible. I am going to play around on my own. It could be fun for doing chairs, and tables, and other props. I don't think it's needed for heads and things like that but you never know.

If you have any specific web links or general formulas I could tinker around with that would be cool.

-vern
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

No idea about math and perspective conic (I did not study it in my career - Only studied conic projection but from the point of view of drawing it by hand (compasses and set squares) and not mathematically).
But I think all the job should be done by this LM tool
void Perspective(alpha, near, far, aspect)

Prepend a perspective transform onto the current matrix.
alpha (float): the field of view angle (in radians) near (float): distance from the virtual eye to the near clipping plane far (float): distance from the virtual eye to the far clipping plane aspect (float): aspect ratio of the final viewing plane Return value: none
I'm working on refining the scripts for the moment. :wink:

How was the night? did you have any nightmare?
-G
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

void Perspective(alpha, near, far, aspect)
Unfortunately i don't think this will work for us. It is for transformation matrices within in AS itself... like a layer has a translation matrix and a rotation matrix etc.

I haven't had much luck figuring those out and the scripting help doesn't explain really how to use them.

A bone does have a fMovedMatrix but I wouldn't know how to apply the perspective to the bone and get it to move the way it should. the bone fMovedMatrix has only an x and y value... not sure what would happen to it if you applied a perspective transformation to it. Can't hurt to try.

My parents have a family friend who is a retired computer sciences professor and a serious math wizard (he was doing experimental 3D vector stuff on the computer with his students in the 70's). I might give him a call.

I think he makes fun of me because I use a "GUI" on my computer instead of "machine language". ;)

-vern
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

heyvern wrote:
void Perspective(alpha, near, far, aspect)
Unfortunately i don't think this will work for us. It is for transformation matrices within in AS itself... like a layer has a translation matrix and a rotation matrix etc.

I haven't had much luck figuring those out and the scripting help doesn't explain really how to use them.

A bone does have a fMovedMatrix but I wouldn't know how to apply the perspective to the bone and get it to move the way it should. the bone fMovedMatrix has only an x and y value... not sure what would happen to it if you applied a perspective transformation to it. Can't hurt to try.
-vern
But don't think on bones... think on points...
Every point is linked to its pt bone. Every pt bone have x, y AND now Z!!!. You virtually can create a mesh of LM_Vector3 with those (x,y, and z) values from the pt bones and apply them to a mesh of points of the copy of an unbinded front view... Then you could transform a mesh of points (outside the bonelayer even) based on the bones "3D" movements...
Glup... :shock:

Did you get it? :roll:
-G
Last edited by Genete on Tue Jun 19, 2007 9:21 am, edited 1 time in total.
animationkolhapur
Posts: 39
Joined: Tue May 22, 2007 6:18 am

Post by animationkolhapur »

Genete.. now you are giving complex to ordinary ppl like us .. .thanks a lot for the script and its wonderful ability to do the work in a simplified manner. Amazing work brother .. too good..
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

Did you get it?
I think I do get it which is why it is so frustrating...

I found this page:

http://www.math.utah.edu/~treiberg/Pers ... rspect.htm

Which I am almost sure has what I need... but... I can't figure out how to turn those freaky equations into lua code!!

We have x,y,z. I can figure out a way to come up with the "eye point" and "near plane" and "far plane" and "rotation point".... but I just don't know how to convert to lua code.

I can see this will probably require using some sort of matrix... but I don't even know if or how I can create that matrix to do a perspective transformation or what to do with the results...

I wish I wish I had paid more attention in high school math class... why didn't anyone tell me this would be so important! ;)

-vern
Genete
Posts: 3483
Joined: Tue Oct 17, 2006 3:27 pm
Location: España / Spain

Post by Genete »

I can see this will probably require using some sort of matrix... but I don't even know if or how I can create that matrix to do a perspective transformation or what to do with the results...
To create it just call the mentioned function of the matrix and the matrix will be a perspective transformation matrix.
To use it just call the transform function with a LM_Vector3 as argument. You will luckily obtain a LM_Vector3 where its x and y coordinates are the projected ones. Just convert it to LM_Vector2 and apply to a point. Repeat this procedure to every point and you'll have a 3D perspective mesh.
...
I think...

It seems to so easy to be true... glup... :shock:

-G
Post Reply