Log in or register to post comments

Cloud Recognition plus Unity UI Canvas causes OpenGL 0x0502 and texture corruption

March 26, 2015 - 2:44pm #1

Vuforia SDK Version: 4.0 -

Description with steps to reproduce:

The easisest way to reproduce the issue is to:

1) Create a Cloud Recognition project

2) Attach a Canvas with world render mode to the ARcamera such that it is visible by the Vuforia camera, and is in its viewport.

3) Add some UI elements (text, images, etc) to that Canvas.

4) Add a second Canvas that is set to screen space. Add some UI components to that Canvas, and set them all to a separate layer from the first canvas.

5) Set up a second orthographic Camera that is rendering only that second UI layer.

Once a target is recognized, you should see OpenGLES 0x0502 errors, and some of the textures and text will get corrupted. The error message looks like:

OpenGLES error 0x0502 in /Users/poshaughnessey/dev/GenieQuest/GenieQuestXCodeFUUUUUUcK/Classes/Unity/GlesHelper.mm:342
 
 
If you remove the Canvas from the AR Camera, it should reduce the likelihood of the corruption happening, which we are currently using as a workaround. However, the issue is still intermittently happening even with the workaround.
 

-

Development OS (Mac OS X, Windows, Linux): Mac OS X -

Mobile OS and Version: iOS 8 -

Mobile Device Manufacturer and Model name: Apple iPhone 6 -

Do the Vuforia Sample Applications show the same behavior?: Not out of the box, since they don't include Unity UI elements as described above.

Cloud Recognition plus Unity UI Canvas causes OpenGL 0x0502 and

April 21, 2015 - 8:18am #5

This issue should be fixed in Vuforia 4.0.105 (without using any corrective script).

 

Cloud Recognition plus Unity UI Canvas causes OpenGL 0x0502 and

March 31, 2015 - 12:03am #4

Also, could you try the following workaround:

- create a script called FixUI.cs, with this code:

using UnityEngine;
using System.Collections;
using Vuforia;
public class FixUI : MonoBehaviour { 

  void OnPostRender() { 
    if (!QCARRuntimeUtilities.IsPlayMode()) { 
        Debug.Log ("flush GL state");
        GL.IssuePluginEvent(-1); 
    }
  } 
}

- attach that script to the Camera object under ARCamera

- see if it gets better

 

 

Cloud Recognition plus Unity UI Canvas causes OpenGL 0x0502 and

March 27, 2015 - 1:57pm #3

What Unity version are you using?

Cloud Recognition plus Unity UI Canvas causes OpenGL 0x0502 and

March 26, 2015 - 2:47pm #2

Attaching a screenshot

AttachmentSize
Image icon 2015-03-26 11.59.51.png1.57 MB
Log in or register to post comments