#One-Dimensional Render Target?

5 messages · Page 1 of 1 (latest)

potent wave
#

Is it possible to render to an array (i.e. 1D render target)? I'm trying to use the GPU for some computation and don't need anything more than points on a line (i.e. elements in an array).
I guess this brings up the question whether a fragment shader can understand a 1D 'texture', too.

quaint oriole
#

Yes, try RedFormat.

#

You still write a vec4 to gl_FragColor etc., but only the red channel will be used.

potent wave
#

Thanks, but I meant more like the length and width dimensions ( length == 1 || width == 1 ) rather than the channels in each texel.

#

I think I actually just answered my own question. lol