ATI+OGL+Geometry Shaders
category: general [glöplog]
Quote:
it's not 4k, where effects are almost everything you can do.
But the probability that xTr1m is, in fact, doing a 4k is very high, since all his prods so far were 4k intros :) A fallback is out of the question then -- except if he makes e.g. a geometry-shaderized 4k version and a GS-less 5k version.
hey KeyJ :)
No this time I'm working on my first big demo. Sure GS would be a nice thing, but I think I can (will have to) manage without. I'll just consider it a limitation of the target platform.
No this time I'm working on my first big demo. Sure GS would be a nice thing, but I think I can (will have to) manage without. I'll just consider it a limitation of the target platform.
It's hard to find OpenGL 3.1 compliant geometry shaders. For some reason glCompileShader or something like that is crashing the drivers with my shader, and I can't find good enough examples.
Which driver? Got no such problems here. They're working pretty much as expected/specced here (on current ati and nvidia drivers). But damn geforce 8/9 are slow at it..
Psycho - just don't output more than, is it 24bytes per vertex? Just enough to expand a particle per point :p
I'm not sure of the version, but I've updated them in December.
I have in the VS:
and in the GS:
I have in the VS:
Code:
attribute vec3 vertex;
out float a;
out vec3 b;
...
gl_Position = ...;
a = ...;
b = ...;
and in the GS:
Code:
in float a[4];
in vec3 b[4];
out vec3 p;
(...)
... = gl_PositionIn[i];
... = a[i];
... = b[i];
is geometry shaders really necessary ??? because everything that can be done with this can also be done from code with opengl no?. is it just a performance stuff ? and i cant really think about stuff that would benefit of this expect palm trees or pubic hair rendering
No, software rendering is fine.
For another answer you can read navis's post on his workflow.
It's compiling now, after a little code optimization... still doesn't explain why it crashed.
It's compiling now, after a little code optimization... still doesn't explain why it crashed.
xernobyl: [4] inputs for the geoshader?
Btw, if on nvidia remember to read the NV_geometry_shader4 spec, to see what you should NOT use.
Btw, if on nvidia remember to read the NV_geometry_shader4 spec, to see what you should NOT use.
How are you supposed to declare the inputs, for 4 vertexes (line adjacency)?
From what I read in the specification I'm supposed to declare the geometry shader inputs as
But the first way gives "array must be redeclared with a size before being indexed with a variable", and the second way gives some error related to the index being wrong (3 instead of 4), but isn't VerticesIn suposed to be set only at link time?
Code:
in vec4 a[];
or
in vec4 a[gl_VerticesIn];
But the first way gives "array must be redeclared with a size before being indexed with a variable", and the second way gives some error related to the index being wrong (3 instead of 4), but isn't VerticesIn suposed to be set only at link time?
I've inlined the code manually and suddenly everything works.