Start work on full body inverse kinematic animation system

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Re: Start work on full body inverse kinematic animation syst

Postby JernejL » Sat Jan 26, 2019 3:49 pm

Dave Gravel wrote:Hi JernejL thanks.
-
do you have working skinned animations done via assimp?

Yes : It's not my final version it is my first implementation test it need a good cleanup.
https://www.youtube.com/watch?v=bTJKEX2Znnc
Here the animations
https://www.youtube.com/watch?v=8F1wR9kXnvM
-
About assimp, When you download the assimp sdk you can find in the zip the pascal header.
I have already test this header and assimp working the same it as with c++ under lazarus.


So, wait.. assimp pascal is actually up to date, and it works with lazarus properly - including animations with fbx models?

Dave Gravel wrote:
About pascal yes and no, What you see in the video is only my editor part.
The main project is a plugin write in c++, This plugin initialize GL context, Lua, ImGui, Newton and more..
I have write all my dll export's for use assimp, lua, imgui, newton customjoint and more...
With my plugin it is not a obligation to use my c++ class and object pointer, I can exemple only init the plugin and use my plugin callback from lazarus project and use directly pure gl or newton commands or just write totally new class from lazarus compatible with the plugin.
-
I can use my plugin with 3 method.
Method 1: I can use my plugin and my c++ class and object.
Method 2: I can use my plugin only for initialize tools like gl, newton, imgui... and I can use my callback for do puregl or newton commands directly in lazarus.
Method 3: I can use a mix of both first methods.
The good thing for me with this plugin, When I write a new demo or project I don't need to rewrite all initialization parts from all tools. The plugin do it for me and I can start to code directly without redo all work again and again.
Or I can use all my class from Lua script too and build the scene via lua.


This is an interesting approach with plugins, i'm curious tho, why you don't use newton, opengl and the rest directly in fpc? is there a design choice why this works better? I'm compiling myself newton dlls and link to those with freepascal, i make my own headers with an automated newton-header converter.

Dave Gravel wrote:
I have already seen some bero's works in the pass, If i'm not wrong he coding only in pascal objects.
He seen to have done a lot good works, Just I don't very like the code structuration it look like spaghetti code for me :? :oops:
Here I coding only in delphi mode and I prefered write my personal things or logics, The delphi class use more ressources system but it is a lot more readable and easy to use for me.
It's not very a good idea to mix pascal object, delphi and c++ It can become quickly a mess about the pointer the 3 languages use different class and pointer method.
Many of my code is write in lazarus delphi mode but it is c++ translation, I have some fun to reproduce c++ code under lazarus delphi mode.
I very love lazarus ide, I very love c++ too but my knowledge is better under delphi coding.


Bero's work is really crazy, but he has a principle that he sticks to - his stuff is made to "just work" - and that in any project as drop-in units, he lacks examples, but i've figured out how his stuff works, and managed to integrate besen scripting and pasmp threads into my game, so in essence, i have javascript scripting in the game, and that's surely going to be an interesting approach - even tho it might turn out to be a bad choice down the road, i think accesibility of javascript might make up for it.
Help improving the Newton Game Dynamics WIKI
User avatar
JernejL
 
Posts: 1578
Joined: Mon Dec 06, 2004 2:00 pm
Location: Slovenia

Re: Start work on full body inverse kinematic animation syst

Postby Julio Jerez » Sat Jan 26, 2019 5:07 pm

remember Newton is not a graphic engine, loading a file is just so that people can check oput hwo teh asset are set up in a modeling package like blender of Max.
All I need is a popular file formal supported by many package and game engines I do no nee all files formal loader.

if you are going to use a free loader, Assimp seems very complete and powerful.
I know if I was make a game engine I would use it. it is just that is not for a physic engine.

BTW I just commit the loader that can properly convert any FBX to an NGD file. now the sking pose is assigned to the mesh regardless of what model is been loaded.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Start work on full body inverse kinematic animation syst

Postby Dave Gravel » Sat Jan 26, 2019 7:27 pm

Hi JernejL,
So, wait.. assimp pascal is actually up to date, and it works with lazarus properly - including animations with fbx models?


I can't say if it is all up-to-date about the header and assimp.
Here I use it from far in time...
https://www.youtube.com/watch?v=wdkPHt72x2I
I have older projects with assimp but I don't have video for alls.
The only thing I can say I never have get problem to use the header with old and newer dll.
Assimp is really good if you like to reduce your coding times when you need to load many mesh format.

This is an interesting approach with plugins, i'm curious tho, why you don't use newton, opengl and the rest directly in fpc? is there a design choice why this works better? I'm compiling myself newton dlls and link to those with freepascal, i make my own headers with an automated newton-header converter.


Maybe for you my method is not better at all, I have no idea.
For me this method is better because I have many projects pascal delphi mode and c++ too.
With my plugin I can reuse my old code from my old project delphi or c++.
The plugin work in both side pascal delphi mode and in c++ too.
I don't make this project for money or anythings like this.
I programming only for my pleasure it is only a pastime for me.
I'm open to share my work when people is able to ask it correctly hehe.
This current plugin project is for me first, but I share it with some friends too.
I think to make it totally public soon just i'm not ready to make the big cleanup for the public release.
For me it is only a way to save a lot of times and when something is not available for use with pascal I can access to it from c++ side.
With the plugin I can use newton, opengl directly with fpc and I can use it directly with c++ too.
I just do the initialization from the plugin, For use newton in fpc I need the normal header same about opengl too.
When I have say I use my exports I talk about my plugin tools only, For the other things I use the normal headers and exports.

Bero's work is really crazy


Yes for sure, I just don't need it at all.
I have already many similar projects about multithread, parallel or personal physics engine but all is coded from a very different method.
I have many old no public projects here, I have start to code at around 1999.
I have backups for pretty much all my old work.
I don't like the coding method from Bero's but I don't say it is wrong or bad work...
He seen to have very nice projects and it is surely very good but from what I have see nothing really interesting me for my project + the method used for code is not really compatible with my method.
I don't like when someone coding all in the same file, for me it look like spaghetti code and I just don't like it.

Edited:
About java in 1999 or maybe before I don't remember I have start to learn coding with java and C from linux.
In 1999 you can buy pc magazin with free borland c++ and java builder tool kits + free redhat linux distrib.
I have start to learn more about c, c++ and delphi from this pc magazin.
Java is very good but it is a other thing that I don't like to code.
I use it in my android projects by obligation but I have reduce the use at the maximum possible for my projects.
I'm very conservative I think I have again all my old pc magazin and cd-rom somewhere in the wardrobe + some old code project write on papers hehe.

Here a exemple with my personal physics engine based on many old c++ papers from google.
https://www.youtube.com/watch?v=ewyCKbDqXRw

I have many more work about physics impulse and verlet but I very love newton dynamics engine.
I like to learn and test anythings it have some good advantages and many disadvantages, It depend on how you see it after many years hehe.

Sorry about my bad english.
You search a nice physics solution, if you can read this message you're at the good place :wink:
OrionX3D Projects & Demos:
https://orionx3d.sytes.net
https://www.facebook.com/dave.gravel1
https://www.youtube.com/user/EvadLevarg/videos
User avatar
Dave Gravel
 
Posts: 800
Joined: Sat Apr 01, 2006 9:31 pm
Location: Quebec in Canada.

Re: Start work on full body inverse kinematic animation syst

Postby Julio Jerez » Mon Jan 28, 2019 10:19 pm

woohoo! final got the fbx to ngd tool working properly without having to touch the source file.
if anyone sync if can see two files loading without conflicts: the viper and the animated man.

It scales and apply proper coordinate system conversion.

Now I can for example export a car with diffrent alignment and test the vehicle model work correctly without having to do too much hacking in code. same apply to the skin.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Start work on full body inverse kinematic animation syst

Postby JoeJ » Tue Jan 29, 2019 7:35 am

User avatar
JoeJ
 
Posts: 1453
Joined: Tue Dec 21, 2010 6:18 pm

Re: Start work on full body inverse kinematic animation syst

Postby Julio Jerez » Tue Jan 29, 2019 8:34 am

Yes I read that about six month ago.
I Take it with a grain of salt. It is not what I expect I was going to be.
What is doing is that now they are adopting single assignment analysis to generate the intermediate code, not much different than what llvm does.
So what they with the other compilers is that is use as a front end to produce intermediate code than they translate VS intermediate language, then from there they run the visual studio optimizer.
Don't you believe for a second this option generates better optimized binary than VS,
for example with gcc the binary for VS is different than the binary for Linux and the same as the generated be visual studio using visual studio front end.
Basically they make visual studio better by making the competitors equal to visual studio.

These days this can be done with llvm if you can take the intermediate language and converted to some other intermediate language. People whiting scripting language are doing it.

What follows is what optimizer has better passes, an in my opinion llvm, Intel and gcc all have better and far richer optimization passes than vs. Visual studio is better at peephole optimization, but not at high level systematic passes like llvm.

It is still better than nothing. but essentially the output is identical or worse for the third party compilers.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Start work on full body inverse kinematic animation syst

Postby JoeJ » Tue Jan 29, 2019 8:59 am

uuuuh... i hear you :cry:

Maybe i'll give it a try anyways - my real actual problem is slow debug builds because stl usage for a preprocessing tool...
User avatar
JoeJ
 
Posts: 1453
Joined: Tue Dec 21, 2010 6:18 pm

Re: Start work on full body inverse kinematic animation syst

Postby Julio Jerez » Tue Jan 29, 2019 11:57 am

Oh I definitlly try.
there say the allow Clang to be use as a replacement of Visual Studio, what teh mean is that you can check your code for robustness with two diffrent compilers.
and who knows maybe my impterteation is wrong.

In any case thsi si alway the beginning and if I am correct, when people benchmark the different code, and realize the binary produce in open platform is different than other, Microsoft is going to have the entire open source community on their back and they will have to fix it.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Start work on full body inverse kinematic animation syst

Postby JernejL » Wed Jan 30, 2019 12:09 pm

If visual studio supported debugging binaries with drawf symbols, this would make it a lot more useful.
Help improving the Newton Game Dynamics WIKI
User avatar
JernejL
 
Posts: 1578
Joined: Mon Dec 06, 2004 2:00 pm
Location: Slovenia

Previous

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 10 guests

cron