Collada Importer tS7.61

free scripts, plugins, models, textures
User avatar
clintonman
Captain
Posts: 5438
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California
Contact:

Re: Collada Importer tS7.61

Post by clintonman »

trueBlue wrote: 31 Jul 2023, 00:57 Cool you did it!
That was quick! :bananathumb:
I noticed that the dae has 3 or 4 animation cycles
I suppose you are not able to add those as tS Clips?
Nope, nothing in the dae to indicate clips.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

clintonman wrote: 31 Jul 2023, 00:03 DogNoTextures.jpgDogWithTextures.jpg

Fully skinned dog and with manual texture adjustments.
The animation is only OK. Truespace has rotation limits before animation goes off and the values of the dog are pushing those limits. The plugin can compensate for this if the collada file has decomposed matrices.

If you look inside the collda file you can see the Decomposed(scale, rotate, translate) looks something like this:

Code: Select all

<scale sid="scale">1 1 1</scale>
<rotate sid="rotationZ">0 0 1 -38.16324</rotate>
<rotate sid="rotationY">0 1 0 1.11555e-6</rotate>
<rotate sid="rotationX">1 0 0 -1.11422e-6</rotate>
<translate sid="location">-0.02635133 0.06681956 -0.001072281</translate>
and matrix looks like this:

Code: Select all

<matrix sid="transform">0.9915332 -0.08842832 -0.09509131 -0.05837 -0.06898616 0.2616895 -0.9626836 0.05429986 0.1100129 0.9610925 0.2533735 0.01153174 0 0 0 1</matrix>
This skinning is also off, because of the problem mentioned earlier with some bones not bound to the skeleton. tS is adding some skinning of it's own automatically. I think I can compensate for that though, so at least one more fix coming in the future. Maybe something can be done for the matrix rotation limitations too.
How did you apply the fur?
User avatar
clintonman
Captain
Posts: 5438
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California
Contact:

Re: Collada Importer tS7.61

Post by clintonman »

trueBlue wrote: 02 Aug 2023, 22:40
clintonman wrote: 31 Jul 2023, 00:03 DogNoTextures.jpgDogWithTextures.jpg

Fully skinned dog and with manual texture adjustments.
The animation is only OK. Truespace has rotation limits before animation goes off and the values of the dog are pushing those limits. The plugin can compensate for this if the collada file has decomposed matrices.

If you look inside the collda file you can see the Decomposed(scale, rotate, translate) looks something like this:

Code: Select all

<scale sid="scale">1 1 1</scale>
<rotate sid="rotationZ">0 0 1 -38.16324</rotate>
<rotate sid="rotationY">0 1 0 1.11555e-6</rotate>
<rotate sid="rotationX">1 0 0 -1.11422e-6</rotate>
<translate sid="location">-0.02635133 0.06681956 -0.001072281</translate>
and matrix looks like this:

Code: Select all

<matrix sid="transform">0.9915332 -0.08842832 -0.09509131 -0.05837 -0.06898616 0.2616895 -0.9626836 0.05429986 0.1100129 0.9610925 0.2533735 0.01153174 0 0 0 1</matrix>
This skinning is also off, because of the problem mentioned earlier with some bones not bound to the skeleton. tS is adding some skinning of it's own automatically. I think I can compensate for that though, so at least one more fix coming in the future. Maybe something can be done for the matrix rotation limitations too.
How did you apply the fur?
WolfFur.jpg
Add a texture alpha shader and add InputFloat and Subtract nodes as shown.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

Testing Enhanced Collada Export and Collada Importer
Using the Horse from the Characters library
Converted the Horse's Material to D3D and to Scene Material Instancing
Note: Name = horsebody
Note: Vray is loaded so includes LW Material
Selected the Horse and Material
Saved as DAE 'Enhanced'
Tried Copy textures enabled and disabled
Not seeing any textures either way
Note: Dae
<material id="horsebody" name="horsebody">

Collada Importer
Import the Horse.dae
Clean Hierarchy
Process Actors
Error

Code: Select all

ERR   Source object: /Scripts/CustomCommands/colladagroup/mesh_bind_transform Error: Microsoft JScript runtime error Description: Invalid procedure call or argument Error code: 0x800a0005 - (null) Line: 47, Char: 1 Script text:  var scene_transform = Node.Value(colladaEncaps + "/" + geoNode + "_DELETE_ME", "WldMatrix"); 
Attachments
Horse.RsScn
(1.81 MiB) Downloaded 54 times
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

I started over with the Horse.RsScn
Unloaded Vray and removed the Vray node
Converted the material without LW material
I am now able to get the textures in the Enhansed Collada Export
Enhansed Collada Export.png
.
So, it looks like LW materials was the issue
Dae file shows the images but the Collada Importer does not import the images
Still get the error
User avatar
clintonman
Captain
Posts: 5438
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California
Contact:

Re: Collada Importer tS7.61

Post by clintonman »

trueBlue wrote: 04 Aug 2023, 16:54 I started over with the Horse.RsScn
Unloaded Vray and removed the Vray node
Converted the material without LW material
I am now able to get the textures in the Enhansed Collada Export
Enhansed Collada Export.png
.
So, it looks like LW materials was the issue
Dae file shows the images but the Collada Importer does not import the images
Still get the error
Been sick, so slow to answer.
Yep, I had the same findings with the Lightworks material. It was probably created for tS7.5. My solution was to select the material with the "Edit picked material directly" unchecked and then paint the object. That seemed to update the LW so it exports correctly.

I found the source of the error in the rsx plugin. I feel better now so maybe have a fix by the end of the day.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

Hope you feel better!

Have you seen Euclidean Space?
https://www.euclideanspace.com/maths/al ... /index.htm
stan
Master Chief Petty Officer
Posts: 580
Joined: 21 May 2009, 17:20

Re: Collada Importer tS7.61

Post by stan »

That site is a great source of knowledge trueBlue
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

stan wrote: 07 Aug 2023, 17:57 That site is a great source of knowledge trueBlue
tomasb44.png
tomasb44.png (17.86 KiB) Viewed 597 times
Nobody will hear you scream in Hilbert Space :mrgreen:
User avatar
trueBlue
Captain
Posts: 5228
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Collada Importer tS7.61

Post by trueBlue »

Another thing I noticed is when you select the scene [ Space.Select(Space.CurrentScene()) ] before Exporting with the Enhansed Collada Exporter is does not work
You have to select all of the objects manually
It does work with trueSpace's Collada Exporter

Both set Spotlights to show Shadows regardless, if it is checked or not
Post Reply