Hello DevGurus!
I'm one step ahead.
I figured out, when I disable the geometry shader in the transform feedback stage, the gpu memory consumption of 150 MB disapears. As said, the geometry shader just produces a tri for an input primitive(point). I just added a picture that shows the peak if glDrawArray is passed in the transform feedback stage and the gs is active. That is about 150 MB.
I changed the configuration a little bit. Now input two triangles(6 points if gs is used). If gs is disabled, the two tris are streamed out to the transform feedback VBO. The result is displayed correctly, two tris. If i add the gs and change the input primitive to GL_POINTS again, the geometry shader correctly produces 6 triangles. I can check this by visual and by glGetQueryObject and GL_PRIMITIVES_GENERATED. The query returns 6, as expected. But, as said, the GPU memory grows by 150 MB if the gs is active in the transform feedback stage.
The gs is like this:
[code]
#version 150
// can be specified here or is retrieved from programparameteri
layout(points) in;
layout (triangle_strip) out;
layout (max_vertices=3) out;
in VertexData{
vec3 color ;
} vertices_in[1] ;
out vec3 oa_position ;
out vec3 oa_color ;
void main()
{
oa_position = vec3(gl_in[0].gl_Position) ;
oa_color = vertices_in[0].color ;
EmitVertex() ;
oa_position = vec3(gl_in[0].gl_Position + vec4(1.0,0.0,0.0,1.0));
oa_color = vertices_in[0].color ;
EmitVertex() ;
oa_position = vec3(gl_in[0].gl_Position + vec4(-1.0,1.0,0.0,1.0));
oa_color = vertices_in[0].color ;
EmitVertex() ;
//EndPrimitive() ;
}
[/code]
This is all I do in the gs, and it also works fine.except the GPU memory overhead, implied by the usage of this geometry shader. I also want to add that the 150 MB footprint only appears in the GPU memory graph in process explorer. Not in system memory.
It would be really great if someone could point me in the right direction, because this is very critical part of my app! My whole application depends on this transform feedback loop.
Thanks,
Alex