I set my viewport as following
D3D10_VIEWPORT vp;
vp.TopLeftX = 0;
vp.TopLeftY = 0;
vp.Width = 320;
vp.Height = 320;
vp.MinDepth = 0.0f;
vp.MaxDepth = 1.0f;
mDevice -> RSSetViewports(1, &vp);
But the problem is whether I use viewport or not, I can render onto the window. And chaning vp.Width or vp.Height doesn't get any effect. What is the problem?