Skip to main content
Up and Coming
October 15, 2014

Leap Motion Plugin

Recently finished an event-driven Leap Motion plugin for UE4.

Using components and interfaces it's as easy as adding the LeapController Component and subscribing to the LeapEventInterface in any blueprint.

Adding the LeapEventInterface


Adding a LeapController Component, if you're using it with an HMD, it even gives you an option to auto correct for hmd position and direction.


from there you can do something like



and you'll get

.

Check out the unreal engine plugin thread or github for downloads, comments, and documentation.

Feedback is always welcome, let me know if this helps anyone :)


Other relevant UE4 Plugins: Razer Hydra Plugin, Thalmic Myo Plugin.
    This topic has been closed for replies.

    6 replies

    Up and Coming
    October 15, 2014
    This is awesome -- we've had a lot of interest in UE4, and with this now available it can only grow from here :D
    Head writer @ Leap Motion
    Up and Coming
    October 15, 2014
    First the Hydra Plugin, now this. You're on fire getnamo!

    Great work! :o
    Up and Coming
    October 15, 2014
    Awesome! I've wanted to get a Leap for a while but was put off but the lack of Unreal support. Looking forward to hopefully using this in the near future.
    @elysebk | elysebk.com Oculus Launchpad Project: Mail Snail
    Up and Coming
    October 15, 2014
    All right! Now we just need a good way to write the raw images to rendertargets...
    getnamoAuthor
    Up and Coming
    October 16, 2014
    "zalo" wrote:
    All right! Now we just need a good way to write the raw images to rendertargets...


    Yeah still getting some runtime errors from allocating mipdata which prevents the plugin from supporting leap image api at the moment.
    uint8* MipData = (uint8*)(LeapTexture->PlatformData->Mips[0].BulkData.Lock(LOCK_READ_WRITE));
    I suspect it has something to do with where I call this rather than the actual code, unfortunately I've got a couple other pressing things at the moment so I can't spend the time needed, but the source is available at the github repo, just uncomment leapimage->get texture to experiment with it. If anyone gets this working make a pull request :P !

    "PatimPatam" wrote:
    First the Hydra Plugin, now this. You're on fire getnamo!

    Great work! :o


    Thanks! Converting the Myo plugin to component and interface api now; hoping these will get people experimenting with more novel input as all the plugins are component-based and you should be able to mix and match them. Personally, I think a myo and leap will go well together, both reinforce eachother's finger/pose detection, and the myo helps tracking the arm for leap tracking edge cases and when it is off-screen.
    Current Project: Skycall
    getnamoAuthor
    Up and Coming
    October 18, 2014
    "zalo" wrote:
    All right! Now we just need a good way to write the raw images to rendertargets...


    and I've got image api to work properly now. I was careful to do this in a way that required the least copying possible and the performance impact of running this every tick is minimal so you can use the api in real-time 8-) !

    Example nodes, remember to enable image support from your Leap Controller object at beginplay in order for this to work


    Result (left side, right side is a distortion map, which you can also drag out)


    Until oculus fixes their image resizing, you can see the full images at the unreal plugin thread :P
    Current Project: Skycall