stash icon indicating copy to clipboard operation
stash copied to clipboard

DeoVR Support

Open kermieisinthehouse opened this issue 3 years ago • 19 comments

This creates a button under scenes to open the scene in the DeoVR player, only on Android. This should complement nicely if we ever decide to do in-browser VR with videojs-vr, as we could have a vr button in the embedded video player, and have the json endpoints available for external apps to consume.

TODO:

  • [x] Make config option to disable
  • [x] Create a root /deovr endpoint so that you can browse your entire library natively

Caveats:

  • Requires HTTPS
  • Won't support funscript

Closes https://github.com/stashapp/stash/discussions/1735 Closes https://github.com/stashapp/stash/issues/318 Sort-of supercedes https://github.com/Tweeticoats/stash-deovr @Tweeticoats

kermieisinthehouse avatar Dec 11 '21 03:12 kermieisinthehouse

Thanks for working on this, really excited for this feature. I made a small change here so I could browse scenes from within the player. Thumbnails and hover previews both work.

  1. The button from the stash web UI needs stash to run with https but browsing within the player does not.
  2. Serving all the scenes to the player is a bit overwhelming. For 18k scenes this meant 4.5MBs of json. DeoVR paginates 12 at a time so this meant navigating over 1,500 pages.
  3. By default the deovr button was showing up on scenes. Turning the option on in settings disabled the button.
  4. This works in DeoVR but doesn't in HereSpere (separate player that also implements the DeoVR API) because video_url uses deovr://. Changing it to http:// makes it work in HereSphere as well.

Releck avatar Dec 27 '21 17:12 Releck

I identified the broken JSON but you beat me to the fix! Thanks a bunch, I'll merge this in today.

To my knowledge there's no working around sending the entire library, the API doesn't have pagination. My library comes out to 150MB, 30 seconds load time. I feel that's not unreasonable for a connection that's also expected to stream VR video.

kermieisinthehouse avatar Dec 27 '21 17:12 kermieisinthehouse

Yes you're right there's no way around sending that much data unless it were pre-filtered. Possibly something to tie-in with saved filters but that seems out of scope for this PR.

Releck avatar Dec 27 '21 20:12 Releck

Thanks for the review! Fixes pushed.

kermieisinthehouse avatar Dec 27 '21 23:12 kermieisinthehouse

Re-tested. Button config works as expected. DeoVR and HereSphere work out of the box. Looking good.

Releck avatar Dec 28 '21 06:12 Releck

Are you using the DeoVR API or browsing stash via the browser? The API works for me as well but it is mostly useless for me as I have much more 2D stuff than VR stuff in my stash and there is no way of filtering them. If you are using the stash site, have you set up https?

That being said I tried HereSphere and I am impressed. It looks like a very great player by itself. Much better than DeoVR imho. At least here you can search the DeoVR API by name (and tags if you set it up??).

HereIam80 avatar Dec 28 '21 09:12 HereIam80

Launching DeoVR via the button works but I haven't configured stash to use https so the browser in DeoVR loads and shows an error screen. Seems like any deovr:// url is interpreted as https by default and doesn't do anything when launching with HereSphere. I've been testing by navigating to the stash homepage inside the VR player.

With DeoVR navigation is going to be difficult as you'll have to dig through all of your scenes. HereSphere lets you search by title. If actors and categories were added to FullDeoScene that would enable tag searching too.

Releck avatar Dec 28 '21 10:12 Releck

I think the best way to solve the lack of filters in DeoVR is to display saved filters in stash as lists in DeoVR. That way people can display only VR videos or specific studios in DeoVR.

Caleripo avatar Dec 28 '21 11:12 Caleripo

So, we currently don't have a way of rendering those saved filters server-side.

I can make lists, but since the user has no input, I can't just send every possible filterable attribute. Ultimately, I can send a lit of performers, a list of tags, a list of studios, etc. Or just keep it as-is and send everything

kermieisinthehouse avatar Jan 08 '22 22:01 kermieisinthehouse

If it isn't possible to use saved filters could there be some opinionated lists? I'd propose a "Favorites" list for scenes rated 5 stars and one for scenes tagged "VR" if the tag exists.

If by list of performers you mean a permutation for every performer I don't think that's going to be viable. There's limited real estate to display lists so only a small amount make sense. 20220108233752_1 .

Releck avatar Jan 08 '22 23:01 Releck

Could you add interactive support if there is a script attached to the scene. To get this to work you need to add the following to the scene json

"isScripted":true, "fleshlight":[{"title":"something.funscript","url":"http://ip:9999/scene/1676/funscript"}],

Tweeticoats avatar Jan 22 '22 23:01 Tweeticoats

Sounds good, but where did you find this format? I can't find any docs around this

kermieisinthehouse avatar Jan 22 '22 23:01 kermieisinthehouse

Copied this from xbvr. I implemented it in my stash-vr-companion and it was tested by a user. I don't have a device to test myself.

Tweeticoats avatar Jan 22 '22 23:01 Tweeticoats

I'm planning on scoping the returned results to a tag called "VR" and all subtags, if one exists.

I'm also planning on adding the funscript changes. All next week.

kermieisinthehouse avatar Jan 28 '22 21:01 kermieisinthehouse

Could we get a config for serving the /deovr route as well? On the DeoVR app for Quest it always navigates to this even when a sub-path (e.g. /scenes) was entered in the URL input. I would hate to lose the stash UI for that DeoVR list. Also it would be great to know if there is any way I can help this PR along, be it testing or coding.

FYI: it seems like DeoVR (at least in their latest update) support the multi-selection way (with http://something.local/deovr) now also with non-https URLs. Maybe we can get them to drop this requirement for the deep links as well.

mmavx avatar Feb 16 '22 21:02 mmavx

If you get this branch merged to be compatible with version 0.15, I can help test it a bit. (Or I can build an earlier stash DB, but Github doesn't have the artifacts anymore from the previous builds).

devloch avatar May 22 '22 19:05 devloch

@WithoutPants Would like to replace the bounty (https://github.com/stashapp/stash/pull/2708#issuecomment-1269083743) on DeoVR-Support ($ 100). I can open a separate issue if needed. #2384 is close, but not very specific.

pickleahead avatar Oct 11 '22 12:10 pickleahead

@WithoutPants Would like to replace the bounty (#2708 (comment)) on DeoVR-Support ($ 100). I can open a separate issue if needed. #2384 is close, but not very specific.

A new issue might be ideal, just so that we have a concrete set of requirements.

WithoutPants avatar Oct 12 '22 21:10 WithoutPants

What would be required to make this work for windows VR devices (oculus, Valve index, etc)?

skier233 avatar Nov 04 '22 17:11 skier233

I'm closing this as stale, but it's a good reference (as far as the structs and JSON tags go) for somebody that wants to finish this up. I never had VR hardware, so I probably wasn't the person to see this through.

kermieisinthehouse avatar Nov 21 '22 23:11 kermieisinthehouse