Forums - Problem with struct assignment in GLSL shader on Nexus 6

4 posts / 0 new
Last post
Problem with struct assignment in GLSL shader on Nexus 6
Evan
Join Date: 5 Mar 13
Posts: 34
Posted: Mon, 2015-02-02 13:54

We're having an issue with the following vertex shader, specifically on the Nexus 6. 

https://gist.github.com/eodabash/13623179d2e84d5c183e.

In particular at line 44, where DistantLights[0] is assigned to the 'light_9' local variable. The assignment doesn't seem to be doing the correct thing and 'light_9' ends up with bad values in it. If I change the code to manually copy the fields one by one then everything works as expected. 

We're OK with our work-around of copying the fields one by one for now, but I just wanted to bring this your attention in case it wasn't already a known issue.

  • Up0
  • Down0
Ayo Moderator
Profile picture
Join Date: 23 Jan 15
Posts: 31
Posted: Thu, 2015-02-05 11:59

Hello Evan.

We did receive a similar report on the Nexus 5:

https://developer.qualcomm.com/forum/qdn-forums/maximize-hardware/mobile...

So at first glance this appears to be a known issue. The compiler team will investigate with the specific shader you submitted, and we'll update this thread when we know for sure if this is related to the other issue.

Thanks for the report.

 

  • Up0
  • Down0
Ayo Moderator
Profile picture
Join Date: 23 Jan 15
Posts: 31
Posted: Fri, 2015-02-06 13:26

Hello Evan.

I wrote a small sample app using your shader. I modified it a bit so it would output the value from light_9.specular as a reddish tint on my test quad, so I could visualise what value was coming through:

color = vec4(light_9.specular, 1.0);

On the commercial Nexus 6, my quad appeared black, just as expected from your reported issue. However, running the same apk on an internal test Nexus 6 containing a pre-production driver, the problem was fixed and the quad appeared red.

This driver should be available publically sometime in March (but do not quote me on that), so for now you should continue using your workaround and the problem would be fixed once your Nexus 6 is updated to the fixed driver.

 

 

  • Up0
  • Down0
Evan
Join Date: 5 Mar 13
Posts: 34
Posted: Mon, 2015-02-09 08:59

OK great, thanks for following up on this.

 

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.