Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error creating shader at com.google.ar.core.codelab.common.rendering.ShaderUtil.loadGLShader(ShaderUtil.java:53) #1

Open
agGitHub opened this issue May 27, 2021 · 2 comments

Comments

@agGitHub
Copy link

Hi,

When trying to run samples 2 and 3, I get the following error:

2021-05-27 16:38:48.698 17037-18105/com.google.ar.core.codelab.rawdepth E/AndroidRuntime: FATAL EXCEPTION: GLThread 12755
    Process: com.google.ar.core.codelab.rawdepth, PID: 17037
    java.lang.RuntimeException: Error creating shader.
        at com.google.ar.core.codelab.common.rendering.ShaderUtil.loadGLShader(ShaderUtil.java:53)
        at com.google.ar.core.codelab.common.rendering.DepthRenderer.createOnGlThread(DepthRenderer.java:67)
        at com.google.ar.core.codelab.rawdepth.RawDepthCodelabActivity.onSurfaceCreated(RawDepthCodelabActivity.java:208)
        at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1559)
        at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1286)

Any idea how to solve it ?

Thanks.

@agGitHub agGitHub reopened this May 27, 2021
@nadiawangberg
Copy link

Did you manage to solve this?

@mcallistertyler
Copy link

Hi,

I was able to solve this by changing the following lines in depth_point_cloud.vert from:

   float kMinHeightMeters = -2.0f;
   float kMaxHeightMeters = 2.0f;

to:

   float kMinHeightMeters = -2.0;
   float kMaxHeightMeters = 2.0;

dchen23 pushed a commit to dchen23/codelab-raw-depth-api that referenced this issue May 12, 2022
- set up the raw depth API
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants