{"action":"created","issue":{"url":"https://api.github.com/repos/mrdoob/three.js/issues/7426","labels_url":"https://api.github.com/repos/mrdoob/three.js/issues/7426/labels{/name}","comments_url":"https://api.github.com/repos/mrdoob/three.js/issues/7426/comments","events_url":"https://api.github.com/repos/mrdoob/three.js/issues/7426/events","html_url":"https://github.com/mrdoob/three.js/pull/7426","id":113080949,"number":7426,"title":"Fixing shadow map crash on Linux. [do not merge]","user":{"login":"bhouston","id":588541,"avatar_url":"https://avatars.githubusercontent.com/u/588541?v=3","gravatar_id":"","url":"https://api.github.com/users/bhouston","html_url":"https://github.com/bhouston","followers_url":"https://api.github.com/users/bhouston/followers","following_url":"https://api.github.com/users/bhouston/following{/other_user}","gists_url":"https://api.github.com/users/bhouston/gists{/gist_id}","starred_url":"https://api.github.com/users/bhouston/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bhouston/subscriptions","organizations_url":"https://api.github.com/users/bhouston/orgs","repos_url":"https://api.github.com/users/bhouston/repos","events_url":"https://api.github.com/users/bhouston/events{/privacy}","received_events_url":"https://api.github.com/users/bhouston/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-10-23T19:02:43Z","updated_at":"2015-10-29T09:45:59Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mrdoob/three.js/pulls/7426","html_url":"https://github.com/mrdoob/three.js/pull/7426","diff_url":"https://github.com/mrdoob/three.js/pull/7426.diff","patch_url":"https://github.com/mrdoob/three.js/pull/7426.patch"},"body":"There is this error:\r\n```\r\n0:201(39): error: sampler arrays indexed with non-constant expressions is forbidden in GLSL 1.30 and later\r\n```\r\n\r\nIt occurs on Linux machines.  Intel driver at least.\r\nIt occurs if shadow maps are enabled.\r\n\r\nIt should be solvable because the access patterns are similar between lights and shadow maps."},"comment":{"url":"https://api.github.com/repos/mrdoob/three.js/issues/comments/152130189","html_url":"https://github.com/mrdoob/three.js/pull/7426#issuecomment-152130189","issue_url":"https://api.github.com/repos/mrdoob/three.js/issues/7426","id":152130189,"user":{"login":"bhouston","id":588541,"avatar_url":"https://avatars.githubusercontent.com/u/588541?v=3","gravatar_id":"","url":"https://api.github.com/users/bhouston","html_url":"https://github.com/bhouston","followers_url":"https://api.github.com/users/bhouston/followers","following_url":"https://api.github.com/users/bhouston/following{/other_user}","gists_url":"https://api.github.com/users/bhouston/gists{/gist_id}","starred_url":"https://api.github.com/users/bhouston/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bhouston/subscriptions","organizations_url":"https://api.github.com/users/bhouston/orgs","repos_url":"https://api.github.com/users/bhouston/repos","events_url":"https://api.github.com/users/bhouston/events{/privacy}","received_events_url":"https://api.github.com/users/bhouston/received_events","type":"User","site_admin":false},"created_at":"2015-10-29T09:45:59Z","updated_at":"2015-10-29T09:45:59Z","body":"It should be possible to fix this bug as I've looked through the shadow map code in the basic/simple case and it seems to be nearly identical in structure to lighting.  The only difference is some of the shadowMap uniforms are conditionally read based on whether or not a shadowMap test passes.  I wonder if we decide to always read those uniforms before the test, it will not cause this error?  Less efficient yes, but if it works on more platforms, I'm all for it.\r\n\r\nI've made that change in this PR but I haven't yet tested it on Intel drivers on Linux.  But if anyone wants to the fix is live here:\r\n\r\nhttp://ci.threejs.org/api/pullrequests/7426/examples/webgl_animation_skinning_morph.html\r\n"}}