Main > Lightguns
VR lighthouse based tracking for lightguns
<< < (2/11) > >>
greymatr:
It's been a while since I played with it but I used version 04 of the software you linked in your first post in the reddit thread. Which I found by changing the URL to:

http://olli.wtf/vive/

so it is this one:

http://olli.wtf/vive/vive_mouse_v04.zip

So I run the config app I think and then I think I chose the option where you put the tracker in the corners of the screen. Being careful to do it in the order that it wants them being done, top, left, right etc, whatever it says.

Pretty sure that gives the best calibration rather than the aiming one.

I also had to adjust the X axis or Y axis value or something by 90 or -90 degrees so that it wasn't aiming straight down.

I had a python program that could pick up the pogo pin keys, there is a library for it. I had to manually map a key for a game but I was going to make it scriptable.

I had it working on a 86 inch tv and was like 4 feet away or something and it was accurate.

If you want I can dig out the gun and setup the light houses and do it again. Record a video or whatever.

You are right about the hyperkin gun though, the iron sights thing isn't good.
Toasty833:

--- Quote from: greymatr on April 20, 2024, 11:20:18 am ---So I run the config app I think and then I think I chose the option where you put the tracker in the corners of the screen. Being careful to do it in the order that it wants them being done, top, left, right etc, whatever it says.

Pretty sure that gives the best calibration rather than the aiming one.

--- End quote ---
I gave it another try with 04 and I've got a better calibration now, but it's still not ideal, out in a few places. I could probably try it a few times to get a good set where the tracking is more accurate (bringing my tracker that close to the screen creates tracking uncertainty due to the reflective nature of the display, so I just have to get lucky with the position being accurate 4 times), but I don't know if it's worth it.


--- Quote from: greymatr on April 20, 2024, 11:20:18 am ---I had a python program that could pick up the pogo pin keys, there is a library for it. I had to manually map a key for a game but I was going to make it scriptable.

--- End quote ---
This is one of the big issues with vive mouse that I can see, the trigger feels a bit weird like there's a delay for precision or the dragging function, there's no off-screen functionality, and it takes total control of the mouse cursor so you need either a kill script with AHK or something to end the program, or to sacrifice a button on your gun for the menu button that toggles the cursor tracking on and off, and you need a secondary program to do basic stuff like map right click. I think ultimately virtual desktop just feels a little better in the cursor even though you have to set it up each time, because I still need to use input emulator to set my tracker coordinates in line with the gun barrel anyway (I can't seem to find a way to automate this through OVIE, you can save profiles but I don't think you can auto-apply them on boot). Vive mouse offers static calibration, but everything else just feels a little cumbersome. I think I'd have to use something like OpenVR2Key to remap the pogo pins, and that doesn't offer mouse clicks so I'd have to map to keyboard keys which brings a new host of incompatibilities.
greymatr:
I had a look at what I did and I remember now that I looked into the 04 exe file and I found that it sends the mouse clicks by hooking into USER32.DLL and accessing some windows functions.

So to stop it from doing that I used a C++ program to intercept the vive_mouse.exe process and redirect it to a dummy DLL file for the USER32.DLL calls. (I got AI to give me most of the source code to do it)

It has to be called after starting the vive_mouse exe.

If the calibration can be static (saved) could you put a sheet or something over the TV to stop the reflections just for the calibration phase?

I had a look at the default.config file that the vive_mouse_config.exe creates and it is a text file. The x,y,z co-ords could be adjusted manually or copy pasted from better calibrations.

This is the python library ( triad_openvr ) I used to access the data of the tracker (x,y,z positions, triggers and other pogo pins i.e. buttons of hyperkin):

https://github.com/TriadSemi/triad_openvr

Once I detected the trigger, I made my own calls to user32 dll using python. I don't think I got to doing the other buttons but I could see them being pressed. Right click and keyboard should be available through user32 as well.

I remember I did this for that same reason you were saying, pulling the trigger felt bad and would sometimes be dragging causing issues.

I was trying to write my own calibration and screen co-ordinate system in python but ending up finding that way to make vive_mouse 04 work.

If you want any source code I can send it but it may be a little rough.

By the way, what VR headset are you using Virtual Desktop with?


Toasty833:

--- Quote from: greymatr on April 21, 2024, 02:36:59 pm ---If the calibration can be static (saved) could you put a sheet or something over the TV to stop the reflections just for the calibration phase?

--- End quote ---
This is a smart idea, I hadn't considered it.


--- Quote from: greymatr on April 21, 2024, 02:36:59 pm ---I had a look at the default.config file that the vive_mouse_config.exe creates and it is a text file. The x,y,z co-ords could be adjusted manually or copy pasted from better calibrations.

--- End quote ---
Yeah, but it's a lot of fiddling. Ultimately, even if I could get a perfect calibration through Vive Mouse it feels like a little more trouble than it's worth. OpenVR2Key works well for remapping additional buttons to keypresses, and I imagine I could just use JoyToKey if I need right click for a game. I've also changed my tracker to be recognised as a controller, which is more useful, so some things that apply to trackers might not work with a spoofed controller.


--- Quote from: greymatr on April 21, 2024, 02:36:59 pm ---If you want any source code I can send it but it may be a little rough.

--- End quote ---
I could take a look at it maybe, but I'm pretty incompetent when it comes to coding. It might be useful to have up anyway in case anyone else is interested in this kind of thing in the future and can make more use of it than me.


--- Quote from: greymatr on April 21, 2024, 02:36:59 pm ---By the way, what VR headset are you using Virtual Desktop with?

--- End quote ---
At this point, an Index. I'm still using 1.0 base stations because they seemed to be better built and I can still use my Vive stuff.
greymatr:

--- Quote from: Toasty833 on April 22, 2024, 06:35:37 am ---Yeah, but it's a lot of fiddling. Ultimately, even if I could get a perfect calibration through Vive Mouse it feels like a little more trouble than it's worth. OpenVR2Key works well for remapping additional buttons to keypresses, and I imagine I could just use JoyToKey if I need right click for a game. I've also changed my tracker to be recognised as a controller, which is more useful, so some things that apply to trackers might not work with a spoofed controller.

--- End quote ---

Actually I think I may have changed my tracker to a controller as well, probably to get it to work with Vive Mouse or something else.

So what do you mean to use OpenVR2Key to work with, is that to use with Virtual Desktop?

I'm trying to think what would give the best setup for you. I'd be happy to help where I can with programming or testing. If you want to let me know what problems you are having at the moment with it?

I can understand the hesitancy with using Vive Mouse, it gave the best results for me with how far I got with the vive but it's a closed sourced program, if it could be modified it would be a lot better.

I was doing something similar with Virtual Desktop using a Meta Quest VR headset and there was a project posted here by NailBuster that did it with a custom program. You posted in the thread:

https://forum.arcadecontrols.com/index.php/topic,166078.msg1760535.html

I tried to do the same with a program on the quest where you had a 16:9 box and I would line it up with the screen and it could see where the controller intersect the screen and give mouse co-ords via wifi to a pc.

But it was a lot of peeking back and forth in the headset. If I went further with it then the controllers would allow the box to be moved around. But I didn't go that far before switching to the vive stuff.

I haven't tried Virtual Desktop with a vive headset though (I got the original one).
Navigation
Message Index
Next page
Previous page

Go to full version