Jump to content

VR goggle camera issues


photo

Recommended Posts

Hi Lukas,

Please, check the AppVive sources. There are two separate camera and each one have an ability to set any post-processing effect you want. By default they are taken from a in-game player, but you can always redefine this list and add any material you want independently:

left_camera->setViewportMask(player_camera->getViewportMask());
left_camera->setReflectionMask(player_camera->getReflectionMask());
left_camera->setReverbMask(player_camera->getReverbMask());
left_camera->setSourceMask(player_camera->getSourceMask());
left_camera->setPostMaterials(player_camera->getPostMaterials()); // <<<

right_camera->setReflectionMask(player_camera->getReflectionMask());
right_camera->setReverbMask(player_camera->getReverbMask());
right_camera->setSourceMask(player_camera->getSourceMask());
right_camera->setPostMaterials(player_camera->getPostMaterials()); // <<<

You will need to rebuild a plugin in order to achieve that.

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment
  • 3 weeks later...

HI, silent

Thanks

But currently, the problem I meet is that it seems that only left_camera works, and it will also affect right_camera.

if you apply a postmaterial to left_camera, both camera will also show the post material.

The SDK version for me is 2.6.0.1

 

Link to comment

Hi Lukas,

seems like it's correct behavior for now. We have plans for such feature (add post materials per camera) but I can't give you any ETA on this.

However, you can modify shader: 

core\shaders\screen_space\fragment\stereo.frag

May I ask you how should the final result look like? Is it something like night vision effect for the left eye and normal picture for the right?

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

Thanks, morbid

yeah,  you are right, we want two eyes to have different vision effects.

But currently, maybe we just want one eye totally black, the other eye works well to simulate night vision goggle battery failure

  • Like 1
Link to comment
  • 2 weeks later...

Now I am changing the stereo.frag 

but I found that even I delete the stereo.frag in core\shaders\screen_space\fragment\

there was no error in the log

and the engine seems to can still read it

and if I add some new materials in  \core\materials\default\post 

the engine cannot find them, and there are errors in the log

 

Link to comment

Hi Lukas,

That's weird. Please, make sure that you have core.ung or unpacked core directory. If you have both (packed and unpacked core) you may observe different kinds of side effects. Normally, when engine finds collisions between packed and unpacked files it uses the unpacked versions.

6 hours ago, de-Roo.Lukas said:

the engine cannot find them, and there are errors in the log

Could you please show us a log file with exact errors?

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

Hi, silent

Thanks, it works, the reason why it didn't work is because  I directly changed the shaders in SDK browser folder rather than in  unpacked core directory

Link to comment
  • 3 months later...
On 4/24/2018 at 2:38 PM, silent said:

Hi Lukas,

Please, check the AppVive sources. There are two separate camera and each one have an ability to set any post-processing effect you want. By default they are taken from a in-game player, but you can always redefine this list and add any material you want independently:


left_camera->setViewportMask(player_camera->getViewportMask());
left_camera->setReflectionMask(player_camera->getReflectionMask());
left_camera->setReverbMask(player_camera->getReverbMask());
left_camera->setSourceMask(player_camera->getSourceMask());
left_camera->setPostMaterials(player_camera->getPostMaterials()); // <<<

right_camera->setReflectionMask(player_camera->getReflectionMask());
right_camera->setReverbMask(player_camera->getReverbMask());
right_camera->setSourceMask(player_camera->getSourceMask());
right_camera->setPostMaterials(player_camera->getPostMaterials()); // <<<

You will need to rebuild a plugin in order to achieve that.

Thanks!

Hi,silent

I used the codes

        left_camera->setViewportMask(player_camera->getViewportMask());
        left_camera->setReflectionMask(player_camera->getReflectionMask());
        left_camera->setReverbMask(player_camera->getReverbMask());
        left_camera->setSourceMask(player_camera->getSourceMask());
        left_camera->setPostMaterials("post_sensor_green");

        right_camera->setViewportMask(player_camera->getViewportMask());
        right_camera->setReflectionMask(player_camera->getReflectionMask());
        right_camera->setReverbMask(player_camera->getReverbMask());
        right_camera->setSourceMask(player_camera->getSourceMask());
        right_camera->setPostMaterials("post_sensor_heat");

and rebuild the dll and applied it in the VR demo project, version 2.7

The result is that  right_camrea's  postMaterials is the same with left_camera as both camera is post_sensor_green

619507275_Screenshot(498).thumb.png.9c2e10cd05e43c69e8811b140d298f8a.png

 

How to make right camera's post material is not the same with left_camera's ?

 

Thanks.

 

you can recreate the scenario using the same code.

 

 

 

Link to comment
×
×
  • Create New...