Jump to content

  • Log In with Google      Sign In   
  • Create Account

image1D as function parameter in glsl


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
No replies to this topic

#1 Wh0p   Members   -  Reputation: 340

Like
0Likes
Like

Posted 14 June 2014 - 05:38 AM

Hi like the topic suggests I am trying to find a way to pass an image1D (2D or whatever) in a parameterlist of a glsl function like:

vec4 myImageLoad (in image1D tex, int pos) {...}

This is simply for convenience when i need to do some more calcularion on the texel value.

 

However i did not get my driver (AMD HD6950) to compile this, the error would be "missing or invalid layout qualifier"

when I use a layout qualifier like this:

vec4 myImageLoad (layout (rgba32f) in image1D paramtex, int light) {...}

The compiler suggests: "parse error on 'layout'".

 

Since the glwiki told me this would be possible, but didnt give a syntax example (http://www.opengl.org/wiki/Image_Load_Store#Image_variables), one of you guys might give me a hint.

Thanks.


Edited by Wh0p, 14 June 2014 - 06:03 AM.


Sponsor:



Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS