Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17625

Can't compile a shader (0:1(1): error: syntax error, unexpected NEW_IDENTIFIER)

$
0
0

I am trying to port android application to linux, i am stuck at shader compilation during runtime

0:1(1): error: syntax error, unexpected NEW_IDENTIFIER

precision highp float;
attribute vec3 Vpos;
varying highp vec2 vert;

void main()
{
vert = Vpos.xy;
gl_Position = vec4(Vpos.xy, 0.0, 1.0);
}

I tried to log this shader to see if i get some weird characters during reading

function goes like ALOG("$"+VertexShaderData);

Loading vertex shader /mnt/ext_sdcard/com.example.wirednavalbattle/files/shaders/fullscreen2d_vp.shader
$precision highp float;
attribute vec3 Vpos;
varying highp vec2 vert;

void main()
{
vert = Vpos.xy;
gl_Position = vec4(Vpos.xy …

Viewing all articles
Browse latest Browse all 17625

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>