I am trying to create a scene in which I want to add 3d models of humans and control their motion through keyboard and/or automated.
However I am having trouble starting off as I'm not sure what exactly to do. This is what I've done so far:
1) I looked at the DOF node and tutorial and figured that I would need a human model with DOF nodes at the hands and legs linkages. I looked at http://www.makehuman.org/ but was not sure if this was the way to go to obtain 3d human models with DOF nodes in them.
2) So far the models of other vehiclces I'm using in my scene are composed of a number of .lwo files that I link using PAT nodes and can move each part individually. But I believe that with models having DOF nodes, I would get a single file but with those nodes specified in them. Is my understanding correct ?
3) I tried to convert a .flt model to .osg from the tutorials dataset using osgconv but got this message:
C:\tools\OpenSceneGraph-2.8.2_Release\bin>osgconv.exe C:\Users\Sanat\Desktop\CE
M_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\t72-tank_des.
flt C:\Users\Sanat\Desktop\CEM_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\
Models\t72-tank\tank.osg
Warning: Could not find plugin to read objects from file "C:\Users\Sanat\Desktop
\CEM_Res_Software\OSG".
Error no data loaded.
------------------------------------------------------------------------------------
So I was hoping to get some pointers as to how I can proceed ? (I have my 3d scene ready but just finding it hard to figure out how to get a human model to move)
Thanks
Regards,
Sanat
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29781#29781
_______________________________________________
osg-users mailing list
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
You can check out Delta3D (www.delta3d.org).
It is a game engine based on OSG that has a lot of functionality for
controlling animated persons. The animations use the Cal3D format btw.
In the examples/ folder of the delta3d distro there are some examples on how to create and control animations.
Thank you!
Cheers,
Martin
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29783#29783
Hi,
I am trying to create a scene in which I want to add 3d models of humans and control their motion through keyboard and/or automated.
However I am having trouble starting off as I'm not sure what exactly to do. This is what I've done so far:
1) I looked at the DOF node and tutorial and figured that I would need a human model with DOF nodes at the hands and legs linkages. I looked at http://www.makehuman.org/ but was not sure if this was the way to go to obtain 3d human models with DOF nodes in them.
2) So far the models of other vehiclces I'm using in my scene are composed of a number of .lwo files that I link using PAT nodes and can move each part individually. But I believe that with models having DOF nodes, I would get a single file but with those nodes specified in them. Is my understanding correct ?
3) I tried to convert a .flt model to .osg from the tutorials dataset using osgconv but got this message:
C:\tools\OpenSceneGraph-2.8.2_Release\bin>osgconv.exe C:\Users\Sanat\Desktop\CE
M_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\t72-tank_des.
flt C:\Users\Sanat\Desktop\CEM_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\
Models\t72-tank\tank.osg
Warning: Could not find plugin to read objects from file "C:\Users\Sanat\Desktop
\CEM_Res_Software\OSG".
Error no data loaded.
------------------------------------------------------------------------------------
So I was hoping to get some pointers as to how I can proceed ? (I have my 3d scene ready but just finding it hard to figure out how to get a human model to move)
Thanks
Regards,
Sanat
> I am trying to create a scene in which I want to add 3d models of humans and control their motion through keyboard and/or automated.
>
> However I am having trouble starting off as I'm not sure what exactly to do.
You should look into osgAnimation. It is a sub-library of OSG (node kit)
which provides animation functionality, and in particular it can animate
skinned human meshes.
Before you can do anything with osgAnimation you need some human model
it can work with. For this you can go two ways: either get a model that
is rigged and animated already, or create one in a modeling tool
(Blender is open source and can save Collada files, Softimage XSI Mod
Tool can be used for non-commercial uses and can export Collada and FBX
files, and then there are commercial modeling tools like XSI, Maya, 3DS
Max etc). Then you would use one of the OSG plugins that supports
animation to load it (the FBX and Collada plugins can load animations,
not sure if others can too).
On the other hand, if you already have a human 3D model, you could
either load it up in a modeling program to add bones and skinning to it,
or do it programmatically based on any kind of transform nodes your
model has (note that DOF nodes are not really different than other
transform nodes (PAT, MatrixTransform, etc), the way you work with them
is different but they're all transforms, their goal is to specify a
local coordinate system).
Once your data can be loaded (you can use the osganimationviewer example
to test if OSG and the plugin can load your model and animations
correctly) you can programmatically start animations when events happen,
such as input or some AI routines you would write.
It looks daunting, many things to do, but take it one step at a time and
you'll get there :-)
Another thing:
> 3) I tried to convert a .flt model to .osg from the tutorials dataset using osgconv but got this message:
>
> C:\tools\OpenSceneGraph-2.8.2_Release\bin>osgconv.exe C:\Users\Sanat\Desktop\CE
> M_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\t72-tank_des.
> flt C:\Users\Sanat\Desktop\CEM_Res_Software\OSG Code\NPS_Tutorials_src\NPS_Data\
> Models\t72-tank\tank.osg
> Warning: Could not find plugin to read objects from file "C:\Users\Sanat\Desktop
> \CEM_Res_Software\OSG".
> Error no data loaded.
> ------------------------------------------------------------------------------------
As klortho would say: "Look at the error message" (though he'd be less
polite about it, and would probably type it in all caps because he yells
a lot). You can see that OSG tried to load
C:\Users\Sanat\Desktop\CEM_Res_Software\OSG
and not
C:\Users\Sanat\Desktop\CEM_Res_Software\OSG
Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\t72-tank_des.flt
which is the path you specified. It stopped at the space character...
You need to quote the path so that the Windows command line interpreter
doesn't cut your path at spaces. Try this:
osgconv.exe "C:\Users\Sanat\Desktop\CEM_Res_Software\OSG
Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\t72-tank_des.flt"
"C:\Users\Sanat\Desktop\CEM_Res_Software\OSG
Code\NPS_Tutorials_src\NPS_Data\Models\t72-tank\tank.osg"
That should give you an .osg file.
Hope this helps,
J-S
--
______________________________________________________
Jean-Sebastien Guay jean-seba...@cm-labs.com
http://www.cm-labs.com/
http://whitestar02.webhop.org/
Thanks for your suggestion. I took a look at its website and I have one question about Delta3D. I am already working with an osg application in visual studio. So if I decide to go the Delta3D way, can I can continue using osg primarily and Delta3D for just certain aspects that make it more convenient to use than osg ?
I am just beginning to get friendly with the osg api and wanted to know if Delta 3D would once again give me a new learning curve to scale ?
Thanks
Sanat.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29795#29795
Yes, that helped. I have a .osg file of the tank now. Thanks for catching that out.
-Sanat
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29796#29796
As you mentioned, it is a lot of steps. But it got me thinking:
In one of the examples/tutorials, using a keyboard handler, the user can change which type of tank is being viewed i.e. whether a good (intact) one or a destroyed (bad) one.
Using a similar mechanism, can one also use 2 states of a model- a static one and a rigged/walking one when the model is made to move ?
Also, do you recommend any sources where to find 3d-models ?
Thanks,
Sanat.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29797#29797
> Using a similar mechanism, can one also use 2 states of a model- a static one and a rigged/walking one when the model is made to move ?
Yes of course, I don't know what tutorial you're talking about but
generally you do that with node masks or Switch nodes, and that will
work on any type of node, whether or not the node contains animation.
> Also, do you recommend any sources where to find 3d-models ?
Not really, search the web or get some contractor to make some for you...
J-S
--
______________________________________________________
Jean-Sebastien Guay jean-seba...@cm-labs.com
http://www.cm-labs.com/
http://whitestar02.webhop.org/
I Don't know if this is just a side project or something more serious, but when I worked at Playnet I used a package from RAD tools called Granny2 (now called Granny 3D). This was OpenGL based so I know it can be added to OSG.
This is a professional tool that uses 3D Studio Max for models and animation but costs $$$$, so if your a hobbyist or student, I'm not sure if this is for you, but otherwise...! Grin!
What would be nice if there where a way to use Poser Objects and animation. Hint Hint!
Poser is a more down to earth, human figure development tool that is user friendly and includes animation. It was made more for hobbyist to explore human figure design!
There is also some premade figures that you can get for the Poser format. Check out DAZ on Google. DAZ even has a Poser model of "The Girl"!
Oh, yea for the hobbyist, you can't beat Deta3D! One of the people that thought me all that I know about human figure animation went to the Naval Graduate School and I’m sure he added a bit or two to that project. I’ve never used it on a project myself, but I’ve reviewed it for my current project.
Well, I just thought I would cram my 2 cents worth in anyway!
Hope I'm not a bother, but working human simulation programs was a job of mine before joined the NAVY and started dealing in Fighter Jets and Top Gun for a living! Not as fun but pay's better!
...
Enjoy Ya All!
D Glenn
------------------------
D Glenn (a.k.a David Glenn) - Join the Navy and See the World ... from your Desk!
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29941#29941
As if now, I was hoping to use open source tools for at least the conversion to osg part.
I did some reading following Jean's and Martin's post and I kind of followed the following:
1) Since I am trying to use models in my simulation, I wouldn't want to spend too much time on creating rigged+animated models in blender/3ds etc. I would want to buy/use already rigged+animated models.
2)In Blender, to export, I presume Collada 1.4 is the best format to pick in order to preserve animations and skins.
3) The part I am having trouble getting figured out is this: Assuming I have a model in dae format (collada). I didn't find any example where this can be used in a simulation straight away taking advantage of the animation already present in the model.
I am already working on an osg app using visual studio and was not sure if I can use just the character animation part of delta 3d as osg satisfies my other requirements so far.
Thanks,
Sanat.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29975#29975
If you want to use blender the best way to export is to use osgexport
for blender IMO. I did osgAnimation and osgexport for blender at the
same time. If you plan to use 3dsmax or other I guess the best is to use
collada.
You can get osgexport here http://hg.plopbyte.net/osgexport/ with
mercurial like this:
hg clone http://hg.plopbyte.net/osgexport/
You will find some 'template' data in the repository as example ready to
export and usable in osg.
Cheers,
Cedric
--
Provide OpenGL, WebGL and OpenSceneGraph services
+33 659 598 614 Cedric Pinson mailto:cedric...@plopbyte.net
http://www.plopbyte.net
> 1) Since I am trying to use models in my simulation, I wouldn't want to spend too much time on creating rigged+animated models in blender/3ds etc. I would want to buy/use already rigged+animated models.
I did a bit of looking around and didn't find a good source of models
with some common animations (walk, run, etc.) available on the web.
TurboSquid sells models that are rigged, but you have to do the
animations yourself (or find some motion capture data you can use, or do
some motion capture yourself). Maybe you'll have more luck in your
search, I hope so anyways.
> 2)In Blender, to export, I presume Collada 1.4 is the best format to pick in order to preserve animations and skins.
As Cedric said from Blender your best bet is osgExport which will export
in OSG-native format. Other options include Collada (for Blender,
3DSMax, XSI, Maya, etc.) or FBX (for 3DSMax, XSI, Maya, etc.), you just
have to build OSG with the required 3rd party dependencies and it will
load those formats with the animation.
> 3) The part I am having trouble getting figured out is this: Assuming I have a model in dae format (collada). I didn't find any example where this can be used in a simulation straight away taking advantage of the animation already present in the model.
See the osganimationviewer example, if you give it a model file with one
or many animation clips in it, it will allow you to play them (even play
multiple clips at the same time blending the animation). For example I
had done some tests with XSI (exporting in Collada and FBX format) and
had a character with two animations: a walk cycle and an animation of
his head turning left and right. I could start both at the same time and
he'd walk while turning his head.
> I am already working on an osg app using visual studio and was not sure if I can use just the character animation part of delta 3d as osg satisfies my other requirements so far.
If you want character animation and can use the above formats/tools, I
would personally just go with OSG since it will fulfill your needs
without any additional external dependencies (like osgCal + Cal3D).
Hope this helps,
J-S
--
______________________________________________________
Jean-Sebastien Guay jean-seba...@cm-labs.com
http://www.cm-labs.com/
http://whitestar02.webhop.org/
We export them from Max to Cal3D, works nicely.
Cheers,
Martin
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29993#29993
Thanks for your previous post, it cleared quite a few things for me.
For the osgAnimationViewer example, what is the data that we need to use?
I am runnng the example from VisualStudio, so it comes to the line in bold below and exits with 1.
Code:
osg::Group* node = dynamic_cast<osg::Group*>(osgDB::readNodeFiles(arguments)); //dynamic_cast<osgAnimation::AnimationManager*>(osgDB::readNodeFile(psr[1]));
if(!node)
{
[b]std::cout << arguments.getApplicationName() <<": No data loaded" << std::endl;[/b]
return 1;
}
I want to study this example thoroughly to understand how the animation works in an osg scene.
Thanks,
Sanat.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=30006#30006
> For the osgAnimationViewer example, what is the data that we need to use?
> I am runnng the example from VisualStudio, so it comes to the line in bold below and exits with 1.
Like osgviewer, you need to give it a file to load. It will load any 3D
model file that OSG can load, but of course it will only be able to play
animation if the file contains animation data and the loader is able to
load that.
If you just want an example, the OpenSceneGraph-Data distribution
contains a file called "nathan.osg" which contains a few animations. If
you don't already have OpenSceneGraph-Data, you can download it from here:
http://www.openscenegraph.org/projects/osg/wiki/Downloads/SampleDatasets
(it also contains other good example data you can learn from)
You can start animations by pressing the "eject" button (the rightmost
one) to show the list, then clicking on one of the animation names in
the list. Press "stop" (the button with the square) to stop the
animation before starting a new one, else the two will play and blend
together which is sometimes not what you want.
If you ever make your own models with animation and export to .osg (with
OSGExport from Blender) or Collada or FBX, you can load those in
osganimationviewer too to see them. This page has a sample skinned model
in FBX format you can use to test with.
http://creators.xna.com/en-GB/sample/skinnedmodel
You will need to compile the OSG FBX plugin to be able to load it, and
for that you need to download the FBX SDK from Autodesk's site. For
Collada, see the OSG Wiki for instructions on how to build the plugin to
load that format.
Hope this helps,
J-S
--
______________________________________________________
Jean-Sebastien Guay jean-seba...@cm-labs.com
http://www.cm-labs.com/
http://whitestar02.webhop.org/
Thanks, that helped. I'll take a look at the FBX plugin too.
Best,
Sanat.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=30043#30043
I've some more questions:
- 3ds max -> fbx -> osg(Animation) - That modeling workflow is working, right?
- Is it possible to control the animationspeed (of single animations)?
- What about LOD? We're also using the rocketbox characters that come with 3 LODs and it would be nice to use them.
Thanks much!
Cheers,
rob
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=30062#30062