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"

How to get real camera position in VR mode?

Hi there,

I'm doing some line traces in VR which should start at the position of the camera (shifted 10 cm downwards, so I can still still the line). This is my current setup:

alt text

As you can see, this works as expected in non-VR:

alt text

In VR however, the starting position of the trace is wandering across the screen when I move the HMD in space:

alt text

(Using standalone game mode in 4.8 due to broken VR preview)

There is a new node called "enable player camera manager follow HMD". But both values (orientation/position) are already set to TRUE (which seems to be there default).

But it seems that the camera manager does indeed not give you the current camera position ?

So I was hoping, that I could just add the result of 'getOrientationAndPosition', but that doesn't help as you can see.

So here's my question: How to get the real, absolute transform (position + orientation) of the camera in VR?

Thank you.

Product Version: UE 4.8
Tags:
more ▼

asked Jun 16 '15 at 01:08 PM in Blueprint Scripting

avatar image

spyro
1.7k 104 116 228

avatar image spyro Jun 18 '15 at 06:47 PM

Come on, is it really so hard...? ;)

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

Ok, thanks to Chillybody at the Unreal Forum there is a solution now to get the real (!) transform of the in-game camera (cameraManager doesn't work reliable with VR):

alt text

(Slightly modified)

more ▼

answered Jun 25 '15 at 10:21 AM

avatar image

spyro
1.7k 104 116 228

(comments are locked)
10|2000 characters needed characters left

Hey there spyro,

Thank you for your work! This is exactly what I need and have been looking for a while.

Just one question: exactly where is that Blueprint? I mean, which actor has it?

Thank you so much again!

more ▼

answered Jun 13 '16 at 08:02 AM

avatar image

j0s3m4
5 4 3 4

avatar image spyro Jun 15 '16 at 06:15 PM

Hi there,

there are not internal dependencies so you can just pack this into a function library and use it globally in your project in every Blueprint.

(comments are locked)
10|2000 characters needed characters left
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