diff --git a/README.md b/README.md new file mode 100644 index 0000000..175e830 --- /dev/null +++ b/README.md @@ -0,0 +1,31 @@ +# PSVR Player +This is a cross-platform 3D 360/180 video player for the Playstation VR headset. It uses libvlc to stream videos to OpenGL in order to display them on the headset. For rotational tracking, it reads the data from the HID device using hidapi. A GUI is provided using Qt 5. It has been tested on Windows and Linux so far. + +This project has been made possible after emoRaivis found out how to get the tracking data from PSVR and developed the app MacMorpheus, which is essentially the same as this project, but as an exclusive Mac application. It is available here: https://github.com/emoRaivis/MacMorpheus. A big thanks to him! + +### Warning +This program uses only a roughly estimated symmetrical field of view and does not apply any lens correction distortion. This means, the projection in the headset is not perfectly correct, which can lead to motion sickness. + +## Screenshot +![Screenshot](screenshot.png) + +## Download +Windows binaries are provided here: https://github.com/metallicent/psvr/releases + +For Linux, you will have to compile the program yourself for now. + +## Setup +emoRaivis has made a nice wiring diagram with instructions on how to set up PSVR for the PC: https://github.com/emoRaivis/MacMorpheus + +## Supported Formats +Since libvlc is used, a huge variety of file formats and codecs is supported. + +An arbitary projection angle can be used in combination with one of these modes: +* Monoscopic +* 3D Over/Under +* 3D Side by Side + +## TODO / Known Issues +* Find out / measure accurate values for the asymmetrical FOV of the HMD and apply correct barrel distortion. +* libvlc outputs the frame data as BGR instead of RGB on different systems. A checkbox has been added as a temporary workaround to switch between both modes. +* Audio seems to stop working when stopping the video on Windows 10. \ No newline at end of file diff --git a/screenshot.png b/screenshot.png new file mode 100644 index 0000000..e77592e Binary files /dev/null and b/screenshot.png differ diff --git a/shader/sphere.frag b/shader/sphere.frag index ca9a172..0cc81f8 100644 --- a/shader/sphere.frag +++ b/shader/sphere.frag @@ -1,3 +1,5 @@ +#version 330 + /* * Created by Florian Märkl * @@ -16,8 +18,6 @@ * */ -#version 330 - #define M_PI 3.1415926535897932384626433832795 uniform sampler2D tex_uni; diff --git a/shader/sphere.vert b/shader/sphere.vert index d713744..527d222 100644 --- a/shader/sphere.vert +++ b/shader/sphere.vert @@ -1,3 +1,5 @@ +#version 330 + /* * Created by Florian Märkl * @@ -16,8 +18,6 @@ * */ -#version 330 - uniform mat4 modelview_projection_uni; in vec3 vertex_attr;