Skip to content

o-fl0w/stash-vr

Repository files navigation

Stash-VR

Watch your Stash library in VR for that full immersion effect.

Stash-VR bridges your Stash instance and VR video player allowing you to browse, play and manage your scenes using the video players native VR UI.

It's lightweight, optionally configurable and has support for two-way sync.

Install Stash-VR, point it to your Stash instance and point your VR video player to Stash-VR.

(Traditional flat/2d videos as well as VR videos are supported.)

Supported video players

  • HereSphere (two-way sync)
  • DeoVR

Features

  • Browse, play and manage videos from your Stash library using the native VR UI of supported video players.
  • Use your saved scene filters from Stash as sections in video player.
  • Heatmaps for interactive scenes generated by Stash.
  • Transcoding endpoints to your videos served by Stash
  • HereSphere
    • Two-way sync of tags, rating, markers
    • Increment o-count/play count/play duration
    • Generate categorized tags, studios, performers
    • Delete scenes
    • Funscript
    • Subtitles
  • DeoVR
    • Markers(?)

Installation

Container images available at docker hub.

For details or docker compose see docker_compose.yml.

After installation open your endpoint (e.g. http://localhost:9666) in a regular browser to verify your setup.

Docker

docker run --name=stash-vr -e STASH_GRAPHQL_URL=http://stash-host:9999/graphql -e STASH_API_KEY=XXX -p 9666:9666 ofl0w/stash-vr:latest

Stash-VR listens on port 9666 by default. To change local port, use docker port binding, e.g. -p 9000:9666, or set env. LISTEN_ADDRESS=:9000 to listen on port 9000 instead.

Binaries

Download and extract a binary for your platform. Run stash-vr -h to display help.

Example: Connect to Stash running on stash-host:9999 with api key XXX and set Stash-VR to listen on port 9000:

stash-vr --STASH_GRAPHQL_URL=http://stash-host:9999/graphql --STASH_API_KEY=XXX --LISTEN_ADDRESS=:9000

Configuration

  • STASH_GRAPHQL_URL
    • Required
    • Url to your Stash graphql - something like http://<stash.host>:<9999>/graphql.
  • STASH_API_KEY
    • Api key to your Stash if it's using authentication, otherwise not required.
More (click to expand)
  • CONFIG_PATH
    • A path Stash-VR can access and save configuration to. If not specified changes will apply in memory but not persist between restarts.
  • FAVORITE_TAG
    • Default: FAVORITE
    • Name of tag in Stash to hold scenes marked as favorites (will be created if not present).
  • EXCLUDE_SORT_NAME
    • Default: hidden
    • Tags with this sort name will not be applied to videos or used for categorization.
  • HEATMAP_HEIGHT_PX
    • Default: 0 (use height of heatmap)
    • Manually set height of all heatmaps. If not set, height of the heatmap retrieved from Stash will be used, currently 15 by default.
  • FORCE_HTTPS
    • Default: false
    • Force Stash-VR to use HTTPS. Useful as a last resort attempt if you're having issues with Stash-VR behind a reverse proxy.

Usage

Browse to http://<host>:9666 using a supported video player. You'll be presented with your library within their respective native UI.

HereSphere

Two-way sync

To enable two-way sync with Stash the relevant toggles (Overwrite tags etc.) in the cogwheel at the bottom right of preview view in HereSphere needs to be on.

To enable update of play duration and count you need to be "logged in" (using any value for username and password) in HereSphere. "Log out" to disable updates.

Manage metadata

Scene metadata is handled using Video Tags in HereSphere. Both for presentation and making changes.

  • Scene tags
    • #:<Name>
    • To tag a scene, create a tag in HereSphere following above format.
      • #:Music will apply the tag Music, creating it if necessary.
    • To untag a scene, delete the tag in HereSphere.
    • Name may not start with #
      • #:#Music
  • Parent tags
    • #<Parent>:<Name> - read-only.
    • Hidden in tag editor, visible in categorized tags under category #<Parent>
  • Ancestor tags
    • #:#<Name> - read-only
    • Hidden in tag editor, visible in categorized tags under # as #<Name>
  • Summary tag
    • Summary:<SUMMARY> - read-only
    • Generated summary string of the scene, parent and ancestor tags shown above seekbar.
  • Studio
    • Studio:<Name> - read-only.
  • Performers
    • @:<Name> - read-only.
  • Groups
    • %:<Name> - read-only.
  • Play count
    • Played:<Count>
    • Automatically incremented when "logged in"
      • Uses Minimum Play Percent from Stash if set.
    • To decrement (delete last timestamp), delete the Played tag
  • O-Count
    • O-Count:<Count>
    • To increment, add a tag /o
    • To decrement (delete last timestamp), delete the O-Count tag
  • Organized
    • Organized:<bool>
    • To set organized, add a tag /org
    • To unset organized, delete the Organized tag
  • Rating
    • Rating:<value>
    • Ratings set in HereSphere will be converted to its equivalent in Stash (4.5 stars => 90).
    • To unset rating, delete the Rating tag
  • Markers
    • Everything else is treated as a marker
    • <Primary Tag Name> (empty title)
      • Music will create marker with tag Music spanning HereSphere tag length
    • <Primary Tag Name>:<Title>
      • Music:Solo will create marker with tag Music and title Solo spanning HereSphere tag length
    • Set the start and end time using HereSphere controls.
    • Changes in HereSphere will sync to Stash

Changes reflect in HereSphere when videos are re-opened.

Favorites

When the favorite-feature of HereSphere is first used Stash-VR will create a tag in Stash named according to FAVORITE_TAG (set in docker env., defaults to FAVORITE) and apply that tag to your scene.

Known issues/Missing features

Unsupported filter types

  • Premade Filters (i.e., Recently Released Scenes etc.) from Stash front page are not supported.
    • Tip: If you really want such filters to show they can easily be recreated and saved using regular filters in Stash.

Scene count limits (More than 10.000 links generated)

DeoVR/HereSphere both seem to have limits and struggle/crash when too many videos are provided than they can handle.

  • For HereSphere the limit seems to be around 10k unique scenes.
    • Fixed in HereSphere v0.7.3?
  • Tip: If you have a VERY LARGE library and your player is struggling to load them all, try creating scene filters in Stash and/or disable filters in Stash-VR index page such that the total amount of videos are lowered to a "reasonable" amount.

Missing thumbnail images in DeoVR

DeoVR won't show images served through HTTP - seems they only allow HTTPS. See xbapps/xbvr#1705

Missing thumbnail images in HereSphere

HereSphere doesn't support WEBP images, which is sometimes fetched when scraping from Stash. A workaround is to manually regenerate a cover using Stash for those scenes.

Troubleshooting

  • If your Stash requires an api key, make sure you provide it to Stash-VR
  • Make sure Stash-VR has network access to Stash
  • Make sure your VR-headset has network access to both Stash and Stash-VR
    • Try explicitly setting LISTEN_ADDRESS to the external (accessible by headset) ip:port of Stash-VR
  • If you can't seek or get errors about unsupported encoding/format, set the Encoding drop-down (above the seekbar) in HereSphere to direct. There's also an equivalent setting in DeoVR.

About

Watch your stash library in VR.

Resources

Stars

Watchers

Forks