KeyShot Forum

Gallery => Amazing Shots => Topic started by: TpwUK on June 11, 2015, 06:14:55 AM

Title: Deformations !! At last :)
Post by: TpwUK on June 11, 2015, 06:14:55 AM
Done some scripting and needed a rescue from Morten (Thanks Morten) but here it goes ...

1 Dump a simple rigged character example from Cheetah3D as an OBJ Sequence
2 Use the python editor that KS6 now supports and customise the Encode Video script to make it work as an import OBJ / export BIP
3 Customise Render Images script provided with KS6 to render the individual frames of the new BIP sequence
4 Used the free ImageJ to convert the PNG frames to an avi

I can see much and plenty use for this :)

Martin
Title: Re: Deformations !! At last :)
Post by: Josh3D on June 11, 2015, 08:43:38 AM
Glad to see this is working for you Martin! Looks like some interesting stuff ahead.
Title: Re: Deformations !! At last :)
Post by: Despot on June 11, 2015, 08:51:54 AM
Nice one Martin...

Although I think he needs some Motion Blur...

Joke  ;)
Title: Re: Deformations !! At last :)
Post by: LM6 on June 11, 2015, 09:05:17 AM
Just got animated camera and material animations working so will check motion blur, but i don't think it will work
Title: Re: Deformations !! At last :)
Post by: Despot on June 11, 2015, 09:10:03 AM
Come on then Martin, share the script, don't be a meanie !! ;)

Or the propeller heads at Luxion, please share the script so other people can have a crack at this !!

:'(  :'(  :'(  :'(  :'(  :'(  :'(  :'(
Title: Re: Deformations !! At last :)
Post by: TpwUK on June 11, 2015, 09:34:10 AM
There ya go J

Martin
Title: Re: Deformations !! At last :)
Post by: jt_pedersen on June 12, 2015, 05:03:55 AM
I have been working on something similar for Maya.

The importer is now able to have to import a specific frame, which means that that frame with its deformed geometry is imported as a static scene. Then scripting makes it possible to import and update geometry for all frames and then stitch the frames together in an animation.

The basic work flow i was considering was.
A. Import a specific frame from the animated file, edit the materials, scene setup etc.
B. Save as bip. (base file)
C. Invoke script to create the animation.

The animation attached clearly indicates that I am more of a programmer than an artist. But it does contain a deformed mesh, with KeyShot materials and an animated camera. (correct import of cameras is in tomorrows build)

The script will probably in some form be part of the distributed script examples.

Title: Re: Deformations !! At last :)
Post by: TpwUK on June 12, 2015, 06:25:41 AM
Much cleaner python code than mine JT - lol

L plates on me back :)

Martin
Title: Re: Deformations !! At last :)
Post by: Andyjonescreative on June 12, 2015, 01:10:21 PM
man thats impressive.  Im gonna need you to take me through this real slow sometime......great work mate.
Title: Re: Deformations !! At last :)
Post by: Justin M on November 14, 2015, 08:39:50 PM
Quote from: jt_pedersen on June 12, 2015, 05:03:55 AM
I have been working on something similar for Maya.

The importer is now able to have to import a specific frame, which means that that frame with its deformed geometry is imported as a static scene. Then scripting makes it possible to import and update geometry for all frames and then stitch the frames together in an animation.

The basic work flow i was considering was.
A. Import a specific frame from the animated file, edit the materials, scene setup etc.
B. Save as bip. (base file)
C. Invoke script to create the animation.

The animation attached clearly indicates that I am more of a programmer than an artist. But it does contain a deformed mesh, with KeyShot materials and an animated camera. (correct import of cameras is in tomorrows build)

The script will probably in some form be part of the distributed script examples.


Your script works good. Thanks for sharing!  Is this the only way to render out deformations in keyshot as of now? There isn't a way to load the animation so you can scrub through it in the viewport?
Title: Re: Deformations !! At last :)
Post by: Despot on November 14, 2015, 11:45:17 PM
Yes, this is the only way to render out an animation containing deformable geometry. So scrubbing the timeline is not possible at the moment.

Although, I think I did hear a vicious rumour that this might change in the future... :)

J
Title: Re: Deformations !! At last :)
Post by: sim_on_006@yahoo.co.in on March 11, 2016, 10:42:11 AM
any tut video is there..? i wnats to know..how to import maya rig animation file to keyshot 6
Title: Re: Deformations !! At last :)
Post by: TpwUK on March 11, 2016, 02:03:28 PM
I never got round to testing *.mb *.ma files with KS6 beta, I would assume you would bake FBX for non deforming geometry and/or camera paths. For deformations, then you would probably need to export/bake as *.ABC or a Sequential OBJ.

Of the three methods i favour Alembic Cache so I would suggest you find a tutorial on how to bake animations to alembic cache using Maya.

I do intend to return to animation via scripting with KS6.x but this is on hold until I have completed a model i am working on, then I will be switching OS again and then hopefully i will find time to revisit this subject

Martin
Title: Re: Deformations !! At last :)
Post by: sim_on_006@yahoo.co.in on March 12, 2016, 12:01:28 PM
Quote from: jt_pedersen on June 12, 2015, 05:03:55 AM
I have been working on something similar for Maya.

The importer is now able to have to import a specific frame, which means that that frame with its deformed geometry is imported as a static scene. Then scripting makes it possible to import and update geometry for all frames and then stitch the frames together in an animation.

The basic work flow i was considering was.
A. Import a specific frame from the animated file, edit the materials, scene setup etc.
B. Save as bip. (base file)
C. Invoke script to create the animation.

The animation attached clearly indicates that I am more of a programmer than an artist. But it does contain a deformed mesh, with KeyShot materials and an animated camera. (correct import of cameras is in tomorrows build)

The script will probably in some form be part of the distributed script examples.


how to work ? this script !
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on March 20, 2016, 08:09:59 AM
Thanks TpwUK is a useful and interesting script compliments.
I tried to use it but I imported the animation.
After using the script, I found myself with .bip files in the folder where is the sequence of obj animation.
So now I have the OBJ file and .bip what should I do?
What should I do to see the animation automatically KeyShot 6?
Thank you and congratulations again
Title: Re: Deformations !! At last :)
Post by: TpwUK on March 20, 2016, 08:43:18 AM
You can not see the animation in KeyShot with my script as it loads one OBJ at a time. I don't have KS installed at the moment because I am moving OS again, but i think i did it that way because there was/is another script that renders the bips to create the animation. if you're not on a deadline and if you can remind me in a few days i will look and see if i can find another script that might be more suitable for your needs.

Martin
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on March 21, 2016, 01:03:41 AM
Thanks Martin are very kind.
To me a script that would allow me to load the animation in KeyShot 6 and see her in it, apply materials etc. and render the work (animation) as in any other rendering engine. Keyshot is fantastic, but unfortunately still lacks important functions in 2016.
Thank you so much again, you're a big.
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on March 21, 2016, 01:09:35 AM
Unfortunately when KeyShot 6, is not even able to import an animation exported Alembic (.abc) like any other software / engine it is capable of doing. They are really important functions, and do not know why the KeyShot developers, do not take seriously. It ''s almost absurd that in 2016 such a fantastic engine, the only way to try to be able to automatically import an animation is a script.
Title: Re: Deformations !! At last :)
Post by: TpwUK on March 21, 2016, 02:25:01 AM
Quote from: sanchezmusics on March 21, 2016, 01:09:35 AM
Unfortunately when KeyShot 6, is not even able to import an animation exported Alembic (.abc) like any other software / engine it is capable of doing. They are really important functions, and do not know why the KeyShot developers, do not take seriously. It ''s almost absurd that in 2016 such a fantastic engine, the only way to try to be able to automatically import an animation is a script.

Give it time. KeyShot development seems to be customer driven. Alembic cache support was added to KeyShot 6 during the beta testing phase and as such it's still very early days for that particular feature of KeyShot. I know that this does not help you much, and I understand your frustration. Adding support via scripting makes sense when you are a multi-platform app otherwise you end up having to code link libraries for every OS you support. Again scripting support was only added in KS6 so it too is in its infancy. To be honest I don't think KeyShot was ever intended to be an animation and special effects rendering engine. The clue is in the name,  it was meant to be, and excels at being a digital photography studio.

Martin
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on March 21, 2016, 04:24:39 AM
I understand but expands and more will have new users and therefore successful. Today in computer graphics are done many animations and it would be great to do also with KeyShot which I find a really excellent engine. It 'a shame even to version 6 and in 2016, not is unable to do this.

I very much hope that you will help me with the script. I would be really very grateful. Thanks so much
Title: Re: Deformations !! At last :)
Post by: TpwUK on March 21, 2016, 05:24:02 AM
Quote from: sanchezmusics on March 21, 2016, 04:24:39 AM
I understand but expands and more will have new users and therefore successful. Today in computer graphics are done many animations and it would be great to do also with KeyShot which I find a really excellent engine. It 'a shame even to version 6 and in 2016, not is unable to do this.

I very much hope that you will help me with the script. I would be really very grateful. Thanks so much

Look up a user here called LM6, he does some cool stuff with X-Particles with C4D exported with Alembic Cache and the rendered with KeyShot. He might be able to help you quicker and probably more than myself.

Martin
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on March 29, 2016, 05:05:27 AM
if you can help me I thank you very much
Title: Re: Deformations !! At last :)
Post by: sanchezmusics on April 09, 2016, 02:33:31 AM
You do not want to help me? Thanks