How many pixels does each quad cover? If every quad is covering the entire screen, then that's only 0.018ms per full-screen-quad, which is actually extremely fast. Graphics cards from a few years back will take ~0.5ms to draw a textured quad over an entire "HD" res buffer,
I had that thought last night. The screen is 800x600, the quad is 260x260. I resized the quad to 66x66 and it still gave lousy performance, something like 20 FPS if I recall. In my D3D9 app I've got 8192 128x128 textured and alpha blended quads on the screen at ~200 FPS.
I just tried the D3D11 app here at the office, and this thing has a Radeon 4550 which is quite slow (running in 10.1 downlevel mode, not that it matters, I get these issues on my home computer which uses a Direct3D 11 card). With my D3D9 app I got ~22 FPS, with this D3D11 (running in 10.1) I get ~0.15 FPS. Something's not kosher here.
I also updated the code to only fill the vertex buffer one time only, so every time the frame is drawn it just calls DrawIndexed(). Something's just not right here.
Oh, also, this is my vertex/pixel shader for the quads (in case there's something in here that'd be a problem):
Texture2D theTexture : register(t0);
SamplerState sample : register(s0);
struct VS_IN
{
float4 pos : POSITION;
float4 col : COLOR;
float2 uv : TEXTURECOORD;
};
struct PS_IN
{
float4 pos : SV_POSITION;
float4 col : COLOR;
float2 uv : TEXTURECOORD;
};
PS_IN VS( VS_IN input )
{
return input;
}
float4 PS( PS_IN input ) : SV_Target
{
return theTexture.Sample(sample, input.uv);
}
Yeah, I'm flummoxed.