Search the Community
Showing results for tags 'reflections'.
-
If we use MirrorTexture based reflections on any planer surface while using WebVRFreeCamera (And viewing in the VR HMD), reflected image is different for both the eyes. So it looks consistent and random. It can't be perceived to be a reflection. It looks like random artefacts. Because reflection is not matching. I am not able to imagine if the mirror texture should be obtained differently for both the eyes using two camera rig (Currently Babylon seems to be doing that ) or obtained reflection texture should be same for both the eyes. If it does need to be obtained two two camera rig (separate reflectionTexture for both eyes, then maybe the two camera rig has some position issue and position for internal mirrorTexture capture cameras need to be corrected. But mirrorTexture is wrong while checking in VR HMD is what I can tell. @RaananW , Mentioning you because of WebVRFReeCamera.
- 6 replies
-
- vr
- rendertarget
-
(and 1 more)
Tagged with:
-
Howdy Babylonians! When I used the unity3d to babylon exporter it currently takes my cubemap and exports it out to a series of JPGs for the different faces of the cubemap. I would like to have use PNG files instead. I can fix this on the exporter side fairly easily by switching the command to from File.WriteAllBytes(faceTexturePath, tempTexture.EncodeToJPG()); to File.WriteAllBytes(faceTexturePath, tempTexture.EncodeToPNG()); and then also changing the output naming convetion from case CubemapFace.NegativeZ: faceTexturePath += "_nz.jpg"; to case CubemapFace.NegativeZ: faceTexturePath += "_nz.png"; When I change these it makes the PNG and names them correctly, but the exported BJS scene doesn't read in the reflection textures correctly. Here is what it looks like when I export the JPG version: - What it looks like when I switch everything over to PNGs - When I load the scene into the babylon sandbox it says " [15:15:49]: Error while trying to load texture: file:ReflectionProbe-0_pz.jpg " So it's still looking for the jpgs insted of the PNGs. Here are the settings for the shader: { "name" : "babylonjs_sample_material_reflection", "id" : "fb8dec12-8352-4e22-8ec5-83008b1780c1", "backFaceCulling" : true, "wireframe" : false, "ambient" : [1, 1, 1], "diffuse" : [0, 0, 0, 1], "specular" : [1, 1, 1, 1], "emissive" : [0, 0, 0, 1], "specularPower" : 53.588665, "alpha" : 1, "diffuseTexture" : null, "diffuseFresnelParameters" : null, "ambientTexture" : null, "opacityTexture" : null, "opacityFresnelParameters" : null, "reflectionTexture" : { "name" : "ReflectionProbe-0", "level" : 1, "hasAlpha" : false, "getAlphaFromRGB" : false, "coordinatesMode" : 3, "isCube" : true, "uOffset" : 0, "vOffset" : 0, "uScale" : 1, "vScale" : 1, "uAng" : 0, "vAng" : 0, "wAng" : 0, "wrapU" : 1, "wrapV" : 1, "coordinatesIndex" : 0, "isRenderTarget" : false, "renderTargetSize" : 0, "mirrorPlane" : null, "renderList" : null, "animations" : null }, "reflectionFresnelParameters" : null, "emissiveTexture" : null, "emissiveFresnelParameters" : null, "specularTexture" : null, "bumpTexture" : null } Is there a way I can adjust the unity exporter code to have it look for the PNGs that were created instead? Or if not is there a way to alter the shader settings after the fact to have it look for the PNGs?