In most fullscreen effects (probably all of them) either the pixel shader or the fill rate is the bottleneck, so I'm wondering if I can do whatever I want to in the vertex/geometry shader as long as it doens't take longer the compute than the pixel shader right?
For example generate the fullscreen quads in the geometry shader so there's no need to bind vertex/index buffers, set input layouts, etc without hurting the performance...
Taking advantage of bottlenecks, kind of
As far as shader goes your primary hardware resources are shared among all shader stages (at least on DX10+ hardware), so you're not really going to have any hardware that's idling when performing a full screen effect. However executing a single instance of a geometry shader probably isn't going to make the slightest bit of difference, so if that's convenient for you then go for it. Alternatively you can also use a vertex shader that sets the appropriate vertex position based on SV_VertexID, and that would also let you avoid binding a VB + IB + InputLayout without having to use a geometry shader.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement