Plugin

[=aialexander;168709]
By the way, earlier in the thread when you guys mentioned you were using “feel good” variables, what did you mean by that?
[/]

Just means these are values with no basis to a proper model. Instead of deriving proper values that are based on model or user dynamics, they are values that are determined experimentally and may not be valid for a wide range of use cases. If you know the values are valid over their expected use case, then they are accurate, but if, for example, they were just calibrated only to how my real body moves, then they may not be valid for a wider set of users.

In sum it means, use those values with care as they may work now for the current setup, but may not be valid for every use case.

To put it another way the values are “tuned” to the particular character and player that we’ve been testing with (in my case, my game’s character and my body parameters (height/arm reach)), but there is no generalized system for determining those values - they’re just hardcoded.

So what needs to happen is a more in depth calibration step where those hardcoded values are calculated based only on the available parameters. One reason I haven’t set that up yet is that the Oculus profile height is not exposed to UE4. Shouldn’t be hard to add a console command for it, but that’s more time spent compiling and stuff for a minor change.

So I have the FABRIK nodes set up in the anim graph for my character, but I seem to be having some issues with the IK. For some reason by arms are completely stiff to the point where when I move them in both the z and the y axis, if the arm is facing forward, it will translate on the z axis instead of the y axis. So translating on the z axis and the y axis will sometimes do the same thing. Does anyone happen to know what could be causing this?

So I realize it might be a little forward of me to ask this, but if anyone has working to some degree the way it should, would you mind sharing your project? I would like to see how you put everything together to get the hydra working with the hands moving in the right direction and the elbows bending properly. It would be very helpful to me as I also learning more and more about Blueprints while working on this.

@anonymous_user_2f683c8e, I’ve had several requests of an example recently, but don’t have anything that’s readily shareable, so I’m going to try and get what I have ported over into the VR game template so that there’s something I can point to. Hopefully by sometime tomorrow or maybe early in the week.

Thank you very much! You are awesome!

Hello ! I’m just starting out on creating a project utilizing my hydra’s but I’ve been running into some problems that I just can’t seem to figure out. I tried following along the video that posted on how to use the plugin inside ue4 and I’m stuck on the part where you draw the debug sphere’s utilizing the positional data and trigger pull event onto the screen. I started a brand new 3rd person blueprint project and copied over the plugin and binaries folder to the project root and everything seems to function correctly except for the debug drawing node. I’m able to print out the coordinates for the hydra positional data but just can’t seem to get past that. Also as a side note, not sure if the latest update took away one of the blueprint functions or not but for some reason I can’t seem to get the Hydra Get Latest Data function to come up no matter where I put it. If anyone could help me get past that would be awesome!! I’ll have to grab some screenshots of what I have setup but I’ve done about 10 times straight now and I haven’t had any changes so far in getting the debug spheres to work correctly. Much appreciated!

[=;169725]
@anonymous_user_2f683c8e, I’ve had several requests of an example recently, but don’t have anything that’s readily shareable, so I’m going to try and get what I have ported over into the VR game template so that there’s something I can point to. Hopefully by sometime tomorrow or maybe early in the week.
[/]

thanks mate :smiley:

[=cleerusher123;170788]
Hello ! I’m just starting out on creating a project utilizing my hydra’s but I’ve been running into some problems that I just can’t seem to figure out. I tried following along the video that posted on how to use the plugin inside ue4 and I’m stuck on the part where you draw the debug sphere’s utilizing the positional data and trigger pull event onto the screen. I started a brand new 3rd person blueprint project and copied over the plugin and binaries folder to the project root and everything seems to function correctly except for the debug drawing node. I’m able to print out the coordinates for the hydra positional data but just can’t seem to get past that. Also as a side note, not sure if the latest update took away one of the blueprint functions or not but for some reason I can’t seem to get the Hydra Get Latest Data function to come up no matter where I put it. If anyone could help me get past that would be awesome!! I’ll have to grab some screenshots of what I have setup but I’ve done about 10 times straight now and I haven’t had any changes so far in getting the debug spheres to work correctly. Much appreciated!
[/]

The plugin has had a fairly major change, I recommend using the component setup as is considered the standard form since 0.7. Please follow the 0.7 postfor setup.

That said the other convenience actors do work the same, but instead of ‘latest data’ it is now called ‘latest frame’.


You can pull up all available functions/events by typing in ‘Hydra’ when you right click. If you’re using the component system remember that the function calls happen on the component not on the parent blueprint.

[=cleerusher123;170788]
Hello ! I’m just starting out on creating a project utilizing my hydra’s but I’ve been running into some problems that I just can’t seem to figure out. I tried following along the video that posted on how to use the plugin inside ue4 and I’m stuck on the part where you draw the debug sphere’s utilizing the positional data and trigger pull event onto the screen. I started a brand new 3rd person blueprint project and copied over the plugin and binaries folder to the project root and everything seems to function correctly except for the debug drawing node. I’m able to print out the coordinates for the hydra positional data but just can’t seem to get past that. Also as a side note, not sure if the latest update took away one of the blueprint functions or not but for some reason I can’t seem to get the Hydra Get Latest Data function to come up no matter where I put it. If anyone could help me get past that would be awesome!! I’ll have to grab some screenshots of what I have setup but I’ve done about 10 times straight now and I haven’t had any changes so far in getting the debug spheres to work correctly. Much appreciated!
[/]

I’ve had similar problems with drawing the debug spheres, I can only get them to work in a reasonable fashion after I’ve multiplied the position vector data by 50 or 100. I’m not sure why that is but I’ve gotten it to work that way. How are you setting the radius of the debug spheres? Are you using a static variable or do you have it mapped to the trigger buttons’ axis value? You might have to raise that value as well just to be able to see your spheres.

[=aialexander;171045]
I’ve had similar problems with drawing the debug spheres, I can only get them to work in a reasonable fashion after I’ve multiplied the position vector data by 50 or 100. I’m not sure why that is but I’ve gotten it to work that way. How are you setting the radius of the debug spheres? Are you using a static variable or do you have it mapped to the trigger buttons’ axis value? You might have to raise that value as well just to be able to see your spheres.
[/]

Thanks for the quick reply! Yeah, I was using the trigger pull values to adjust the sphere radius just like how he had them set up in the video and I increased my value all the way from 50 -> 10,000 and still couldn’t see the spheres anywhere. I didn’t try multiplying my positional data for the controllers so I’ll have to give that a try later on tomorrow when I get the to see if that makes any difference. I’ll reply again if I get it working with that and hopefully someone in my position will see as the solution for while testing stuff out :slight_smile:

[=;170964]
The plugin has had a fairly major change, I recommend using the component setup as is considered the standard form since 0.7. Please follow the 0.7 postfor setup.

That said the other convenience actors do work the same, but instead of ‘latest data’ it is now called ‘latest frame’.


You can pull up all available functions/events by typing in ‘Hydra’ when you right click. If you’re using the component system remember that the function calls happen on the component not on the parent blueprint.
[/]

I tried using that before but it’s different from how I see most of the other screenshots on here look. There isn’t the huge list of functions on the right side like how it looks in screenshot here and I’m wondering if it was broken up into smaller chunks to help clean some of the blueprints up. Also I did follow along the new 0.7 instructions on my test project and still no difference in getting stuff to work. I’ll have to try multiplying the positional data like aialexander suggested to see if that works at all with the draw debug sphere.


Just thought I would bring up while posting since I haven’t read anywhere that it’s been taken out or separated out is all which was confusing while I was trying to follow along some examples people have posted.

[=cleerusher123;171366]
I tried using that before but it’s different from how I see most of the other screenshots on here look. There isn’t the huge list of functions on the right side like how it looks in screenshot here and I’m wondering if it was broken up into smaller chunks to help clean some of the blueprints up. Also I did follow along the new 0.7 instructions on my test project and still no difference in getting stuff to work. I’ll have to try multiplying the positional data like aialexander suggested to see if that works at all with the draw debug sphere.

Just thought I would bring up while posting since I haven’t read anywhere that it’s been taken out or separated out is all which was confusing while I was trying to follow along some examples people have posted.
[/]

You make a good point, problem is the video and the old reference images are still useful in terms of getting a good snapshot of how blueprint interaction works and, importantly, the IK setup, but the video in particular doesn’t have what I consider best practice anymore. Let me elaborate:

The following is what I consider best practice in terms of debugging your hydra positions. Use the event driven Event Hydra Controller Moved,


where Draw Hydra Debug Box is given by


gives the following result on the third person template when you undock your hydras:


Noticed that only one event is needed to draw both of the hydras. The positions being debugged are the Hydra Base -> Hydra Position in cm (which is UE default), but placed to follow the actor around with his orientation. If you then want to know which hand the user is currently holding their hydra (to for example forward positions to left/right hand), simply branch the HydraSingleController reference (blue node) and call is Left/Right Hand like so


In contrast using the polling method (latest frame) you need to specify a controller id (0 for left hardwire, 1 for right hardwire). But a user can displace the controllers and the hand in which they hold them will update based on where they last docked, if you use polling you will not catch by default. Here is the above example using polling:


Notice the duplication of work and you can’t confidently say that controller 0 is left hand and 1 is right hand, which would require double the branching logic compared to the event driven version to confirm. In addition unlike the event version, the positions will report even when docked, which is usually unnecessary.

Also note the difference in API since 0.7, latest frame (which used to be latest data) now emits a HydraSingleController, from which you branch to get the information you want to have


exact reference is emitted from every event so you can check other things from within the event context without resorting to any polling. The reason for change is mainly adding the whole controller relevant information in events, which also includes the ability to check which hand the controller is in from any context while still to providing the same functionality as before. also makes the plugin upstream maintenance easier.

Armed with knowledge I would follow 's guide for IK setup in thread, but use an event driven source. You could also have the IK setup turn off (alpha =0 in animgraph) whenever you dock, which would default the character to regular animation whenever the hydra isn’t available.

Remember that all Hydra properties and functions are categorized under ‘Hydra’ prefix so that you can see what is available from the node you drag by typing hydra and it will filter all your functions down to the plugin relevant ones.

Edit: updated the post, containing updated example.

So I heard that is almost ready to post a tutorial for stuff just as soon as he’s done ironing it out! I’m excited!

Update to 0.7.4
-Changed AnyButtonPressed event into ButtonPressed(enum
HydraControllerButton) and ButtonReleased(enum HydraControllerButton)
allowing for a single event to handle all buttons if desired.
-Reduced controller lag by 1 frame, was introduced in 0.7 due to a
bug from blueprint controller class extension

Example using new events

Thanks for the update , works great!

Is there a 4.6 version of the plugin ? Thanks

[=Mrob76u;189088]
Is there a 4.6 version of the plugin ? Thanks
[/]

Working on next, expect an updated version by tomorrow.

[=;189155]
Working on next, expect an updated version by tomorrow.
[/]

Thanks . Your work on input plugins is really great. Especially of the VR developers out there like myself. We owe you a lot of drinks :slight_smile:

On a side note I’m also a backer of the new STEM system from Sixence, The vitualizer and the full body capture suit from Perception Neuron. Does anyone else here have any of these devices on order as well?

I did not personally back them but wish I could have, however, I have my boss very interested in the virtualizer, and a definite buy when perception nueron is available…we have the legacy mocap suit on order now.