WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   Reverse Animations (https://forum.worldviz.com/showthread.php?t=5129)

kerscha 08-06-2014 09:39 AM

Reverse Animations
 
I have looked all over the internet, documentation and forums and cannot find the answer to my question:

Is it possible to have an avatar animation run in reverse? I would like my avatar to be in a 'walk' animation, but walk in REVERSE.

I have tried setting the animation speed to -1 but that does not work. The only thing I could find about this in the forums was at the link below, which was never given an answer:

http://forum.worldviz.com/showthread...hlight=reverse

Thanks in advance!

Frank Verberne 08-06-2014 11:49 AM

Hi Kerscha,

The only way to make an avatar run in reverse realistically is to create the custom animation yourself. You can do so with motion capture devices, or with keyframe animations. See http://docs.worldviz.com/vizard/Tuto...s_manually.htm for some more information.

kerscha 08-06-2014 12:56 PM

I understand that, but we purchased the Complete Character HD set and don't have access to the MAX files. We are limited by the animations that are already built in. I'm a little upset that there's not an easy way to just reverse the animations that already exist...

Frank Verberne 08-06-2014 01:35 PM

As far as I know, you can buy the .max files for the Complete Character HD set separately, but that still is not an easy fix. In vizard, there is not much you can do to change the animations. One cumbersome way of reversing existing animations is to run the normal animation and save the rotation of every bone & the position of the pelvis bone of your Complete Character in a list. Reverse the list, and apply the rotation & position data to the corresponding bone of your Complete Character. See the code in the thread http://forum.worldviz.com/showthread.php?t=4948 for some info on that.

On a side note: I cannot easily imagine that reversing a running forward animation will create a realistic looking running backwards animation. Could you maybe elaborate what you're trying to achieve in general? Perhaps there are other (simpler) ways.

kerscha 08-06-2014 01:43 PM

What I want to do is create a type of "tour". I have created a path in 3DS MAX through my worlds that I link the Avatar to. I have the avatar facing the user and I need her to walk backwards in order to speak with the user, exactly as tour guides do.

Frank Verberne 08-06-2014 01:56 PM

One option would be to put the avatar om a small platform, with her facing the user. That platform can follow the path you made in 3DS MAX, and the avatar can be linked to the platform.

Another solution could involve the avatar walking to a certain spot, then turning to the user to give the tour. The avatar could keep on talking with its back towards the user, although it is quite common for tour guides to not talk about the tour while walking.

A last option would be to record the leg movements of the standard walking motion, keep the orientation and position in a list, reverse the list and apply this reversed list to the leg bones. I don't know if it will result in a realistically looking backwards walking avatar though.

kerscha 08-06-2014 02:05 PM

I was able to reverse the walk in a simplistic way and it looks ok. Not great, but it will suffice for what we are doing. Thanks for your help, it might come in handy later on. For future reference, here's the code I came up with:

walkTime = 1.1853300333

def walkBackwards():
global walkTime
avatar.setAnimationTime(0,walkTime)
walkTime-=0.01 #change for speed
if walkTime <= 0:
walkTime = 1.1853300333
vizact.ontimer2(0.01,viz.FOREVER,walkBackwards)


All times are GMT -7. The time now is 11:19 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC