Any graphics artist looking for something different? Why not join us and create 8-bit graphics in the C64 scene! Click here for more info.
Join also our Discord channel! Click here.

[Help] Weights issue in Noesis script

Post questions about game models here, or help out others!
jayn23
veteran
Posts: 102
Joined: Sun Jul 17, 2011 9:30 pm
Has thanked: 25 times
Been thanked: 89 times

Re: [Help] Weights issue in Noesis script

Post by jayn23 » Sun Feb 16, 2020 10:12 pm

I try to mimic the script in the thread provided. Unfortunately, the result is still a mess :[ . Could you help to take a glance if I need to modify something? Here is the full version:
unfortunately i am not sure where the problem is, my TempMat is in world space so i guess that should be converted as well, but when i tried converting it didn't work for me, maybe someone with a bit more experience can step in and help us? :D

User avatar
srbvn
n00b
Posts: 16
Joined: Thu Oct 03, 2019 11:10 am
Has thanked: 13 times
Been thanked: 1 time

Re: [Help] Weights issue in Noesis script

Post by srbvn » Mon Feb 17, 2020 10:12 am

Yes, hope someone could help us a hand. Also, do you have any idea about the matrix (parentMat) below every bone matrix? We are currently not using it. Hope to hear your advise.

Code: Select all

	# read 4x4 bone matrix
        boneMat = NoeMat44.fromBytes( bs.readBytes(0x40), NOE_LITTLEENDIAN )
        # convert and inverse to 4x3 matrix
        boneMat43 = boneMat.toMat43().inverse()
        # read 4x4 parent bone matrix
        parentMat = NoeMat44.fromBytes( bs.readBytes(0x40), NOE_LITTLEENDIAN )
        # convert and inverse to 4x3 matrix
        parentMat43 = parentMat.toMat43().inverse()
I had thought it is the maxtrix of parent bone so I named it parentMat, but it seem not true.

jayn23
veteran
Posts: 102
Joined: Sun Jul 17, 2011 9:30 pm
Has thanked: 25 times
Been thanked: 89 times

Re: [Help] Weights issue in Noesis script

Post by jayn23 » Mon Feb 17, 2020 11:08 pm

well i tried something very simple to check if the extra matrix is the locale space:

i extracted the skeleton to collada (.dae) which stores the matrix in locale space as far as i know, printed out the matrix in noesis and compared
they were not the same. so still no clue, but if its not the locale space it not very helpful anyway.

User avatar
srbvn
n00b
Posts: 16
Joined: Thu Oct 03, 2019 11:10 am
Has thanked: 13 times
Been thanked: 1 time

Re: [Help] Weights issue in Noesis script

Post by srbvn » Sat Feb 22, 2020 6:20 pm

Hi jayn23,
I still could not know how the matrices in animation files work, but I could now found the animation file that has the same numbers of bone with the model. So, hope you could try again if your algorithm work. In game, this is a fox being jump and bite.

To be honest, I have tried to read about matrices in 3D graphics, DirectX (the game use DirectX), local space and world space but still have no clue T.T.
Also, here is my curent script (new lines added but still not work): https://pastebin.com/4sgQwuJR

Kindly refer to the attachments
Example file has 5 animations inside and model has 41 bones.
You do not have the required permissions to view the files attached to this post.

Post Reply