change gestures

1 post / 0 new
Alain
Alain's picture
change gestures

1 - Change gestures in your avatar

You have an avatar made with AvatarStudio : myavatar.wrl

Edit it with vrmlpad

Find an avatar witch has a  gesture you want to use, "swimming" for instance.
Open it with vrmlpad.
Find witch gesture it is , i.e  gesture 10

Select all the  DEF *** PositionInterpolator {
and DEF *** OrientationInterpolator {
of  this right gesture

Copy and then paste them  replacing all the
DEF *** PositionInterpolator {
and
DEF *** OrientationInterpolator {
of your gesture 10 in your  "myavatar.wrl"

You will have to copy paste the ROUTES too .

ROUTE TS10.fraction_changed TO PI10_1.set_fraction
etc etc

If I remember well ( I don't) it is OK if all is matching .
May be corrections will be needed.

Anyways it is that sort of way ...

 

2 - Change gestures in your avatar ( way inverse )

One  give you  an avatar with a gesture you like , i.e swiming...
But you own avatar hasn't.

Edit it with vrmlpad.
Copy the shape of your avatar  and replace the shape of the first one .
You will have too  to replace all that , in the welder script :

     field MFVec3f P [
         0 -1.7400 0,-0.0015 ...ect ect ect...-0.4203 -0.0364,0.00-0.0037 0 0
]
     field MFRotation R0 [
         0 1 0 0,0 1 0 0,0.6385 ...ect ect ect...0 0,0 1 0 0,0 1 0 0
]
     field MFRotation R[]
     field MFInt32 vgroups[
         0 0 0 1 0 0 2 0 28 ...ect ect ect...411296 797 817 7 817 823 6 823 831
     ]
by the values of your shape.

And also , to replace , in the Welder's function VtxTransform(){

 var i;
m0=new VrmlMatrix();
m0.setTransform(P[0],R[0]);
m1=new VrmlMatrix();
m1.setTransform(P[1],R[1]);
m1=m1.multRight(m0);
m2=new VrmlMatrix();
m2.setTransform(P[2],R[2]);
m2=m2.multRight(m1);
for(i=0;i<28;i++){W[i]=m2.multVecMatrix(V[i]);}
m3=new VrmlMatrix();
m3.
ectectectectee...................................
for(i=797;i<817;i++){W[i]=m6.multVecMatrix(V[i]);}
m7.setTransform(P[50],R[50]);
m7=m7.multRight(m6);
for(i=817;i<823;i++){W[i]=m7.multVecMatrix(V[i]);}
m6.setTransform(P[51],R[51]);
m6=m6.multRight(m5);
for(i=823;i<831;i++){W[i]=m6.multVecMatrix(V[i]);}
       Vtx.point=W;

all that by your own values

It is that sort of way ...+ Some corrections sometimes needed

 

Visibility: 
Private - accessible only to group members
Edited by: PauloNunes on 2015/02/02 - 23:46