question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Invalid shader creating when running in exokit browser

See original GitHub issue

Running http://www.babylonjs-playground.com/frame.htm#EIX8SD#3 in exokit (https://exokitbrowser.com) fails to function properly due to invalidly constructed shader (LOGARITHMICDEPTH is not defined)

Exokit logging:

Babylon.js engine (v3.3.0-alpha.13) launched BJS - [23:19:35]: Unable to compile effect: BJS - [23:19:35]: Uniforms: LensCenter, Scale, ScaleIn, HmdWarpParam, scale, textureSampler BJS - [23:19:35]: Attributes: position BJS - [23:19:35]: Error: unknown #version type: 300 es BJS - [23:19:35]: Unable to compile effect: BJS - [23:19:35]: Uniforms: world, view, viewProjection, vEyePosition, vLightsType, vAmbientColor, vDiffuseColor, vSpecularColor, vEmissiveColor, vFogInfos, vFogColor, pointSize, vDiffuseInfos, vAmbientInfos, vOpacityInfos, vReflectionInfos, vEmissiveInfos, vSpecularInfos, vBumpInfos, vLightmapInfos, vRefractionInfos, mBones, vClipPlane, diffuseMatrix, ambientMatrix, opacityMatrix, reflectionMatrix, emissiveMatrix, specularMatrix, bumpMatrix, normalMatrix, lightmapMatrix, refractionMatrix, diffuseLeftColor, diffuseRightColor, opacityParts, reflectionLeftColor, reflectionRightColor, emissiveLeftColor, emissiveRightColor, refractionLeftColor, refractionRightColor, vReflectionPosition, vReflectionSize, logarithmicDepthConstant, vTangentSpaceParams, alphaCutOff, vLightData0, vLightDiffuse0, vLightSpecular0, vLightDirection0, vLightGround0, lightMatrix0, shadowsInfo0, depthValues0, diffuseSampler, ambientSampler, opacitySampler, reflectionCubeSampler, reflection2DSampler, emissiveSampler, specularSampler, bumpSampler, lightmapSampler, refractionCubeSampler, refraction2DSampler, shadowSampler0, depthSampler0 BJS - [23:19:35]: Attributes: position, normal BJS - [23:19:35]: Error: unknown #version type: 300 es BJS - [23:19:35]: Trying next fallback. BJS - [23:19:35]: Unable to compile effect: BJS - [23:19:35]: Uniforms: world, view, viewProjection, vEyePosition, vLightsType, vAmbientColor, vDiffuseColor, vSpecularColor, vEmissiveColor, vFogInfos, vFogColor, pointSize, vDiffuseInfos, vAmbientInfos, vOpacityInfos, vReflectionInfos, vEmissiveInfos, vSpecularInfos, vBumpInfos, vLightmapInfos, vRefractionInfos, mBones, vClipPlane, diffuseMatrix, ambientMatrix, opacityMatrix, reflectionMatrix, emissiveMatrix, specularMatrix, bumpMatrix, normalMatrix, lightmapMatrix, refractionMatrix, diffuseLeftColor, diffuseRightColor, opacityParts, reflectionLeftColor, reflectionRightColor, emissiveLeftColor, emissiveRightColor, refractionLeftColor, refractionRightColor, vReflectionPosition, vReflectionSize, logarithmicDepthConstant, vTangentSpaceParams, alphaCutOff, vLightData0, vLightDiffuse0, vLightSpecular0, vLightDirection0, vLightGround0, lightMatrix0, shadowsInfo0, depthValues0, diffuseSampler, ambientSampler, opacitySampler, reflectionCubeSampler, reflection2DSampler, emissiveSampler, specularSampler, bumpSampler, lightmapSampler, refractionCubeSampler, refraction2DSampler, shadowSampler0, depthSampler0 BJS - [23:19:35]: Attributes: position, normal BJS - [23:19:35]: Error: unknown #version type: 300 es

Invalid produced shader: https://exokit.slack.com/files/U90GZV4GN/FBUMQB3EH/broken_shader.txt

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
TrevorDevcommented, Jul 31, 2018

@modulesio Thanks so much, will do.

I might be able to dig a bit more into webmixedreality/exokit#283 to see where/when in babylon the viewport is somehow setting the wrong values when I get some free time.

0reactions
avaercommented, Jul 31, 2018

I got http://www.babylonjs-playground.com/frame.htm#EIX8SD#7 working by fixing bugs https://github.com/webmixedreality/exokit/pull/282 + https://github.com/webmixedreality/exokit/pull/281.

capture 12

I filed https://github.com/webmixedreality/exokit/issues/283 to track the too small viewport calls coming from Babylon.js. I’ll have to understand the Babylon architecture more, but the setViewport() calls are using the old canvas size to set gl.viewport, resulting in a too small render.

Regarding Reality Tabs, it is Ctrl-1 to enter VR but we still need to document many of these features on https://docs.webmr.io/.

@TrevorDev Finally, if I missed something re: Exokit, could you file an issue at the Exokit repo?

Read more comments on GitHub >

github_iconTop Results From Across the Web

glShaderSource should give more info when a shader is ...
Issue 101239: glShaderSource should give more info when a shader is rejected due to invalid characters. ... Searching a long shader using a...
Read more >
[Solved] Invalid Shader Version Issue - GameDev.net
Hello everyone. I am currently working on making a game engine and I have been following the tutorials on http://www.directxtutorial.com/ ...
Read more >
WebGPU - W3C
When a shader is provided to createShaderModule() , the WebGPU implementation has to validate it before doing any translation (to platform-specific shaders) or ......
Read more >
Tutorial: Vulkan GLSL Ray Tracing Emulator - GSN Composer
Only if you want to run the exported C++ Vulkan stand-alone application, a GPU with ray ... The ray generation shader creates rays...
Read more >
Changing Optifine settings with Minecraft closed - YouTube
Trying to set up a shaderpack, but the game crashes whenever you click a new option? Set something wrong that prevents you from...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found