virtual-reality

Using Raycast instead of Gaze Pointer

こ雲淡風輕ζ 提交于 2020-01-05 04:56:11
问题 I'm new to VR development,I'm using oculus integration so I made a ray line with the line renderer , but now I need to make this line interactive with everything like a gaze pointer (objects,UI, Scrolls..),, I'm testing my project on Oculus Go I have tried a lot of tutorials but no one focuses on this point. Here's my attempt at the code: RaycastHit hit; if(Physics.Raycast(transform.position,transform.forward ,out hit,0.8f)) { if(hit.collider != null) { if (OVRInput.Get(OVRInput.Button

Raycast an object to enbable a mouse click event with Three.js

…衆ロ難τιáo~ 提交于 2020-01-03 02:29:12
问题 I'm adding objects to a scene for each entry in a database. I had a cube appearing in the scene for entry, but when I tried to add raycasting to click on objects it doesnt work, the objects dont appear and the console reads "Expression unavailable".. I got parts of the code from the three.js website for Raycasting so not sure what I'm doing wrong. Here is the JS code: var renderer, scene, container, camera; var geometry, material; var controls, group; var raycaster = new THREE.Raycaster();

How to show side by side two previews of camera in iOS objective-C for vr app?

半腔热情 提交于 2020-01-03 02:03:05
问题 I am trying to implement side by side two camera views for vr application. I found some useful info on at this site: How to show 2 camera preview side by side?[For cardboard apps] but I want how to create it with iOS? I am trying to create same behaviour with AVFoundation. This is my current code CameraViewController #import <AVFoundation/AVFoundation.h> #import "CameraViewController.h" @interface CameraViewController () @property (strong, nonatomic) AVCaptureSession *captureSession;

Control HTML Objects with A-Frame Entity

戏子无情 提交于 2019-12-25 19:02:07
问题 Is it possible to control regular html objects outside of a-scene using A-Frame entities? For example, I would like to toggle a modal object when selecting a plane, sphere, etc. within an embedded scene. I know about the UI Modal that can be displayed within the scene, but the ability to operate between the scene and "exterior" elements would be very powerful. I'm sure this is possible, but I do not have the VR developer skills yet to figure this one out! Thanks in advance for your help! 回答1:

Connect OVRGearVrController to Scene

允我心安 提交于 2019-12-25 09:28:58
问题 It's should be simple but I can't find any proper tutorial/sample for this. I imported the OVR package to my Unity scene, and put the OVRGearVrController in the middle of it. I can see the controller in my scene, but that's it. How or where should I connect it to react to the real controller that it's in my hand? 回答1: Import the latest OculusUtilities package to your project Replace the default Camera with OVRCameraRig Add GearVrController under the RightHandAnchor 来源: https://stackoverflow

How to show 4 videos at once using Google Cardboard?

大憨熊 提交于 2019-12-25 09:14:59
问题 I am trying to show four videos at once using Google Cardboard. These videos are normal 2D videos that were shot on a normal 16:9 camera. What I want and need is to have one video in front of you then you turn your head 90 degrees and you see another video, turn again and see another until you hit the front video again. Please see my Pablo Picasso Microsoft Paint skills to visualize what I am talking about... So basically what I need is like four VR movie theater screens that a person can

Android XML InflateException - Google Cardboard

和自甴很熟 提交于 2019-12-25 07:58:44
问题 Getting an InflateException for the following XML. The suspect line is with VrVideoView. I have looked through the XML, and cannot find any big differences between this an the demo app. Has anyone successfully used VrVideoView XML <?xml version="1.0" encoding="utf-8"?> <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="@android:color/white"> <LinearLayout android:layout_width="match

Application froze when system popup show Unity3D Samsung Gear VR Bluetooth Android

与世无争的帅哥 提交于 2019-12-25 07:28:04
问题 I am developing an Android application using Unity3D for the Samsung Gear VR, with the Samsung Galaxy S7. In my app, I use the bluetooth to create a local network between two devices. When the system popup asking permissions to enable bluetooth discoverability is supposed to appear in my app, the whole app freeze, the popup is not shown and I have to reboot the phone to use it again. Is there a solution to maybe ask for that permission before my app is launch? For example, another request,

How do I get VrVideoView to start in Cardboard mode? [closed]

人走茶凉 提交于 2019-12-25 01:45:41
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 10 months ago . http://trimensions.org/node/83 I am coding by importing the code from the link above. But this code starts on a small screen. As soon as I start, I want to start with the Cardboard mode (a mode with both left-eye and right-eye monitors). However, no matter how I read the code, the code to switch to Cardboard

In A-Frame: How do I get the VR camera

荒凉一梦 提交于 2019-12-24 10:49:13
问题 In this example: https://glitch.com/~query-aframe-cameras I have registered a component which launches a projectile in the direction the user is looking (with a little boost for elevation) Spacebar or Screen Tap to launch - be sure to be looking above the horizon! It fails in mobile vr (stereo camera) mode: Projectiles continue to fire, but from the default orientation of the mono, not the stereo camera I'm using: var cam = document.querySelector('a-scene').camera.el.object3D; var camVec =