KinectMocap4Blender icon indicating copy to clipboard operation
KinectMocap4Blender copied to clipboard

Update KinectMocap4Blender to work in version 2.93 of blender

Open Fredy-1422 opened this issue 4 years ago • 21 comments

after updating blender the .py file no longer functions as it errors out with unable to find .dll files to load

-error

Fredy-1422 avatar Jul 21 '21 23:07 Fredy-1422

Same issue. I'm willing to commission this, since it is part of my work.

thelabcat avatar Oct 09 '21 18:10 thelabcat

I'm also hitting this

blakedgross avatar Dec 22 '21 21:12 blakedgross

Same issue. I'm willing to commission this, since it is part of my work.

Did you manage to do anything with this error, I get the same issue even if I go back to an older version of blender (2.83 to be exact)

ReadieFur avatar Jan 11 '22 22:01 ReadieFur

Same issue. Anyone made it work?

@moraell, au secours :)

j2l avatar Jun 16 '22 19:06 j2l

I think it is safe to say this project has died. We must now find an alternative for motion capture.

thelabcat avatar Jun 19 '22 04:06 thelabcat

Well, guess I have no choice but to roll my own :p

gingershaped avatar Jun 19 '22 10:06 gingershaped

Yes, please, go for it :) @GingerIndustries

j2l avatar Jun 19 '22 19:06 j2l

This fix worked for me -- you just need to copy the .pyd to the right place.

  1. Do the install as normal.

  2. Click the Activate checkbox and the error will tell you what directory is being searched for the .pyd. For me, it was: C:\Users\USERNAME\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons

  3. Open this directory in Windows Explorer and you should see the main plugin (kinect_mocap.py). Copy the .pyd to that directory (kinectMocap4Blender.pyd)

  4. Click the Activate checkbox and it will check this time

I tried this on both 2.82 and 2.91 and it works. Note that the KinectMocap4Blender addon panel only shows when you're in Pose mode in Blender.

drahmel avatar Jun 27 '22 18:06 drahmel

I tried this on both 2.82 and 2.91 and it works. Note that the KinectMocap4Blender addon panel only shows when you're in Pose mode in Blender.

The issue started in 2.93 as stated in the title, so this is not relevant/not the same issue.

thelabcat avatar Jun 28 '22 15:06 thelabcat

Interesting. You are correct -- this is a 2.93 version problem. Turns out the folks at Blender upgraded the version of Python from 3.7 to 3.9 in that version. I did a dump of the .pyd dependencies and it looks like this:

File Type: DLL

Image has the following dependencies:

**python37.dll**
Kinect20.dll
MSVCP140.dll
VCRUNTIME140.dll
api-ms-win-crt-heap-l1-1-0.dll
api-ms-win-crt-runtime-l1-1-0.dll
KERNEL32.dll
api-ms-win-crt-math-l1-1-0.dll

Note the "python3.7" dependency in the DLL. I'm haven't been a Visual Studio guy for a number of years, but I'll look into compiling with a 3.9 dependency. Meanwhile, you can do a workaround of running Blender 2.91 portable version, do your motion capture there, save the .blend file, and then use it with the new version of Blender.

This is such a great addon, it seems worth the extra trouble until we get a new compile.

drahmel avatar Jun 28 '22 18:06 drahmel

I had a suspicion it might be a compilation issue. I'm going to recompile it ASAP and if it works I'll put it here.

gingershaped avatar Jun 28 '22 18:06 gingershaped

Great! Is there a more generic Python DLL that can be used in case they upgrade Python again?

Also, although I think the Python version is the problem, it might be a change to Python itself. When I was looking for the solution last night, I thought it might be the issue specified in this SO (https://stackoverflow.com/questions/20201868/importerror-dll-load-failed-the-specified-module-could-not-be-found):

"Since Python 3.8, it is possible that Dependencies or dumpbin /dependents reports no dependency issue, but one still gets the error "The specified module could not be found". This is because the PATH variable is no longer used for resolving DLLs of binary modules!"

I tried using the "os.add_dll_directory(r"C:\path\to\your\dll\directory")" and it didn't seem to fix the problem, so I figured it was the Python version change.

drahmel avatar Jun 28 '22 20:06 drahmel

@drahmel have you tried affecting "sys.path" in some way like here? https://github.com/PierceLBrooks/Buildster/blob/pip/buildster/main.py#L13

PierceLBrooks avatar Jul 08 '22 16:07 PierceLBrooks

@PierceLBrooks No. I think the problem is that I don't know WHICH dll it isn't finding -- that's not in the error. I installed the Visual Studio Community edition and I'm going to try to compile it with that. I'm hoping that will show me the locations. Once I know, I will retry the add_dll_ method and I'll also try the one your suggested. Thanks!

drahmel avatar Jul 09 '22 21:07 drahmel

Interesting.

gingershaped avatar Oct 11 '22 06:10 gingershaped

Did this ever get solved? I just remembered about it :p

gingershaped avatar Nov 15 '22 17:11 gingershaped

I'm trying to make it work right now but I'm having this issue in all the 2.8X versions I have tried.

After reviewing the files, it looks like the file kinectMocap4Blender.pyd is not in the .zip uploaded here. Could that be the issue?

Bebecu avatar Nov 28 '22 19:11 Bebecu

I've asked some friends for help

gingershaped avatar Nov 28 '22 20:11 gingershaped

I've asked some friends for help

I'm subscribed so I'll be notified when you comment anything! Hope they can help :)

Bebecu avatar Dec 12 '22 16:12 Bebecu