WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   Regarding .FBX exported model with animation not played in Vizard (https://forum.worldviz.com/showthread.php?t=5931)

rajnishv 01-04-2017 01:54 AM

Regarding .FBX exported model with animation not played in Vizard
 
2 Attachment(s)
Hi Jeff,
I am preparing a demo,which i am loading a 3D model(Heart with cardiovascular) with animations having extension .FBX.

But when i load the 3D Model,the model gets loaded in the inspector and when i select state 1 of the model in the animation tab ,the animation gets played in the inspector but the animation doesnt play in Vizard(Renderer).

I also followed the link in the post,but no breakthrough.
link:
http://forum.worldviz.com/showthread.php?t=5548

Also i tested with the a simple code by loading .FBX exported animated model,here also no breakthrough:

Code:
import viz
viz.go()

male2 = viz.addChild('Heart_new_Anim.fbx')
joint=male2.getChild('heart_piece')



I also applied "node3D.state(1)",but there is no animation played in Vizard.

PFA the screenshot of the inspector view and the vizard (renderer) view.

Pls do check the hierarchy in the .FBX model screenshot and if any issues pls do reply.

Note:The RED circled marked(Heart) only have animation in the .FBX exported 3D Model.

Thanx&Regards

Mr.Rajnish Vishwakarma

Jeff 01-04-2017 04:37 PM

Try using the following code to load the FBX model with animation in Vizard. Replace 'model.fbx' with the name of your model in both lines of code:

Code:

model = viz.addChild('model.fbx')
model.setAnimationState(0, node='model.fbx::Take 001')


rajnishv 01-05-2017 12:00 AM

2 Attachment(s)
Hi Jeff,
Thanx for ur reply.
I tested and written the code as mentioned above in your last reply to this post,but the animations is not played in vizard renderer:

Code:
import viz
viz.go()

male2 = viz.addChild('Heat_Anim_FullBody.FBX')
male2.setAnimationState(viz.PLAY, node='Heat_Anim_FullBody.FBX::Windpipe')


And also saw and floolowed the link with the concept written down:

http://kb.worldviz.com/articles/2087

Some Questions:
1)I am not clear about the node to pass which have animation?.
2)Whether the node is from the ANIMATION section or from SCENE GRAPH Section?.
3)Which is the correct node i have to pass inside "model.setAnimationState(viz.PLAY,node='model.fbx:: Take 001')" in the place of "Take 001"?(Pls refer Screen shot attcahed for nodes.
4)After exporting models from both 3Ds Max and Maya,why there is [empty] node with no name is viewed in INSPECTOR.
5)Do i have to write ?
(Pls see screen shot to get the view of which node i have write)

6)When i select the NAMES from the animation from inspector,that is when i select "0 - [none]",no animation is played in inspector and when i select "1 - Take 001",the animations is played,i dont knw why such behaviour.

"male2.setAnimationState(viz.PLAY,node='Heat_Anim_F ullBody.FBX::Take 001')"

or

"male2.setAnimationState(viz.PLAY,node='Heat_Anim_F ullBody.FBX::Heart_01')"






I am also attaching the screen shot of the INSPECTOR with the nodes.
Pls assist me further.

Thanx & Regards:

Mr.Rajnish Vishwakarma

Veleno 01-05-2017 02:32 PM

2 Attachment(s)
Quote:

4)After exporting models from both 3Ds Max and Maya,why there is [empty] node with no name is viewed in INSPECTOR.
At the time of this post, all imported files display their structures as specified in the file, so the extra nodes appearing in the FBX file would have either been something that either existed in the source file or were put in place by the exporter for one reason or another.

-----

Speaking generally, for the most reliable results and greatest amount of control we recommend exporting props and environments to Vizard's native format (OSGB) using our 3ds Max exporter using the attached preset file, with other options modified as needed. Once unzipped, the preset file can be loaded from the lower left dropdown menu in the export window (see attached image).

For skinned animation (i.e. characters), we recommend using our Cal3D exporter.

rajnishv 01-05-2017 10:03 PM

Thanx Veleno,for ur reply to the post.

Also we are using Cal3D Exporter to export models.

Is it possible to get the solution for .FBX exported animation and the issues i am getting which i have written above ur reply.

Pls assist me further on the issues related to .FBX models.

Note:Pls go thru the issues mentioned above ur reply and why animation is not played using .FBX model into Vizard.

Thanx&Regards
Mr.Rajnish Vishwakarma

Veleno 01-06-2017 02:00 PM

Hi Rajnish,

Skinned FBX avatars are not currently supported in Vizard, but this is something we're interested in adding in a later release. General full-file animation based off move/scale/rotation should work correctly and be controllable through code.

All internal projects at WorldViz (custom dev work + demo scenes) are created almost exclusively though OSGB and Cal3D, so the amount of support we can give to FBX-specific questions is comparatively limited. OSG and CAL3D also give greater control over individual node animations than FBX.

> 1) I am not clear about the node to pass which have animation?

I'm also unable to find any clear answer on whether there is currently a way to enable animation on just one specific subnode in an FBX file. Since our support for FBX animation is currently limited, it's entirely possible that node specific control is not implemented for FBX at this time.

As a workaround, you could:
A. Export that each node that needs individual animation as a separate FBX and re-link it through code.

B. If you find a way to get the FBX exporter to recognize each animation as an individual track this may allow individual control as well, but I'm not sure how you'd go about doing that. As far as I know Max has no way to set that up.

C. If only one animation needs to play at a time, you could also split them up by putting each on unique animation frames. E.g. 1st animation frame 0-15, second on frame 20-30, etc.

> 2) Whether the node is from the ANIMATION section or from SCENE GRAPH Section?
The format is male2.setAnimationState(viz.PLAY, node='Heat_Anim_FullBody.FBX::Take 001'), where Take 001 is taken from the animation list.

> 3) Which is the correct node i have to pass inside "model.setAnimationState(viz.PLAY,node='model.fbx: :Take 001')" in the place of "Take 001"?

Animation for FBX is only partially supported, so only animating specific subnodes may not be possible with FBX at this time.

> 4) After exporting models from both 3Ds Max and Maya,why there is [empty] node with no name is viewed in INSPECTOR.
> 5) Do i have to write ?


See previous post for 4 and 5.

> 6)When i select the NAMES from the animation from inspector,that is when i select "0 - [none]",no animation is played in inspector and when i select "1 - Take 001",the animations is played,i dont knw why such behaviour.

"0 - [none]" is empty animation that allows the current animation to be set to "no animation" when an actual animation is no longer needed.


All times are GMT -7. The time now is 01:26 PM.

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