x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

VR Camera Location is wrong

I'm working on a room scale VR game with the HTC Vive and there's a new bug which popped up in 4.13 which didn't exist in 4.12.

I have a camera which is attached to a scene component called "Tripod". The tripod scene component is attached to another scene component called "BaseComponent", which is always at the foot/floor of the character. When a player wears an HMD, the relative offset of the tripod component changes to change the camera position. The tracking origin is set to the floor. So, if I'm standing up with the HMD and I measure my relative height from the floor, I get about 172cm and the ground plane in the game matches the floor in my office. I can stand up and crouch, and the HMD has perfect correspondence to my actual height.

However, if I select the camera component and set "Lock to HMD" to false AND have "Use Pawn Control Rotation" set to false, and then I go and stand in the center of my play space and crouch and stand, the height offset is completely off. If my HMD moves below my hip height, the camera view goes through the floor. If I stand all the way up, I'm way outside the bounds of the character capsule component. To adjust the camera height, I am using the "DevicePosition" node and wiring the Z value into the relative location of the tripod in the tick function.

What's really weird is that I can draw a debug sphere at the reported world space tripod scene component location, but that doesn't match up with my actual camera location. However, if I enable either "Lock to HMD" or "User Pawn Control Rotation", the visual output and camera locations match perfectly.

This is my blueprint setup: alt text

This is what I see in VR. The camera should be in the red sphere and the white sphere's Z axis value should always be exactly at eye level. alt text

This is what I see when I enable "Lock to HMD" and disconnect the wires from updating the tripod component values. The camera is now correctly inside of the red sphere. alt text

I can't use pawn control rotation because I don't want my character rotation to be bound to the HMD yaw. A player could be looking over their left or right shoulder.

I don't want to lock the camera to the HMD because I need to manually set the camera location to be on top of the characters head if the player attempts to walk through a colliding obstacle in VR. Their physical body may clip the colliding geometery, but their camera and character do not.

I had this working in 4.12 :(

Product Version: UE 4.13
Tags:
camerasetup.png (468.1 kB)
externalcam.png (987.8 kB)
lockhmd.png (1.0 MB)
more ▼

asked Sep 23 '16 at 01:52 AM in Bug Reports

avatar image

Slayemin
829 50 29 73

avatar image Rudy Q ♦♦ STAFF Sep 23 '16 at 01:32 PM

Hello Slayemin,

I have a few questions for you that will help narrow down what issue it is that you are experiencing.

Quick questions:

  1. Can you reproduce this issue in a clean project?

  2. If so, could you provide a detailed list of steps to reproduce this issue on our end?

  3. Could you provide screen shots of any blueprints/settings that may be involved in the reproduction of this issue?

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hello Slayemin,

We have not heard back from you in a few days, so we are marking this post as Resolved for tracking purposes. If you are still experiencing the issue you reported, please respond to this message with additional information and we will follow up.

Thanks,

more ▼

answered Sep 27 '16 at 03:44 PM

avatar image

Rudy Q ♦♦ STAFF
47.4k 545 132 525

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question