Delicode / NI-mate-plugins

This repository holds the plugins for NI mate.
http://www.ni-mate.com
17 stars 7 forks source link

I5 - 2.8 Changes to NI-Mate plugin #6

Closed plachenko closed 5 years ago

plachenko commented 5 years ago

This pull request adds needed changes to work with NI-Mate and Blender 2.8. I've changed some code based on this comment: https://github.com/Delicode/NI-mate-plugins/issues/5#issuecomment-447692701 This also removes blender game engine functionality since the bge is now deprecated and the new blender 'interactive mode' has yet to come.

I've only done light testing so I can't attest that all code works fine, but the purpose was to get this up and running with 2.8.

resolves #5

SirDifferential commented 5 years ago

Thanks for this - I'll go through this once we have a moment to look at this stuff.

plachenko commented 5 years ago

Would you mind if I expanded a bit on this branch? I've been reading up on blender's gpu api and think I could send the sensor feed to the view port display through a shader. I'm not fully sure if I could set the feed as a texture on a material yet though but I believe at least displaying feed data is possible.

I would really like to capture point cloud data but I'm not sure about how you would do that with ni mate-- my understanding is that it only sends skeletal tracking info over the port, not depth data.

SirDifferential commented 5 years ago

NI mate only sends the skeleton data over OSC. The Spout/Syphon feeds include the depth feed which can be used to extract point cloud information.

SirDifferential commented 5 years ago

I'm accepting this pull request as it is and then submitting a few changes on top of it later. Thank for your valuable contribution.

plachenko commented 5 years ago

No problem! I still think the new gpu module should be able to draw on screen to replicate the BGE feed textures but I honestly haven't gotten to the point of parsing OSC data yet.

SirDifferential commented 5 years ago

I took a look at this https://docs.blender.org/api/blender2.8/gpu.html#d-image but the general consensus around the office was that without the game engine, the feeds themselves are of questionable value. The feeds were mostly useful when you had something approaching a full screen game in Blender, but with the feeds just existing in the viewport, they aren't all that useful. Technically Eevee is trying to be a game engine of sorts on its own, though.