DX9 2D game w/ camera

I'm working on a 2D platformer. I've set up the camera like I've seen in some examples, but it doesn't seem to make any difference, i.e. I increment and decrement the eye vector and look-at vector, change the up vector, etc.. the scene doesn't change. I'm drawing sprites and primitives; here's what I have:

1
2
3
4
5
6
//In the init function
eyeVector = D3DXVECTOR3(0.0f, 0.0f, -8.0f);

lookAtVector = D3DXVECTOR3(0.0f, 0.0f, 0.0f);

upVector = D3DXVECTOR3(0.0f, 1.0f, 0.0f);


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
//In the render function
if(SUCCEEDED(m_pD3DDevice->Clear(0, 0, D3DCLEAR_TARGET, D3DXCOLOR(0.9f, 0.9f, 0.9f, 1.0f), 1.0f, 0)))
	{
		if(SUCCEEDED(m_pD3DDevice->BeginScene()))
		{
			

			D3DXMatrixLookAtLH(&viewMat,
				&eyeVector,
				&lookAtVector,
				&upVector);

			m_pD3DDevice->SetTransform(D3DTS_VIEW, &viewMat);


			D3DXMatrixPerspectiveFovLH(&projMat,
				D3DXToRadian(90),
				m_Aspect,
				0.0f,
				0.1f);

			m_pD3DDevice->SetTransform(D3DTS_PROJECTION, &projMat);


			if(m_RClick)
			{
				if(m_LaserObject.targetInSight)
				{
					m_pD3DDevice->SetStreamSource(0, m_pLaserVertexObject, 0, sizeof(D3DVERTEX));
					m_pD3DDevice->SetFVF(D3DFVF_XYZRHW|D3DFVF_DIFFUSE);
					m_pD3DDevice->DrawPrimitive(D3DPT_TRIANGLEFAN, 0, 2);
				}
			}

			

			if(SUCCEEDED(m_pD3DSprite->Begin(D3DXSPRITE_ALPHABLEND | D3DXSPRITE_SORT_DEPTH_FRONTTOBACK)))
			{

				D3DXMatrixIdentity(&transMat);
				D3DXMatrixIdentity(&scaleMat);
				D3DXMatrixIdentity(&rotMat);
				D3DXMatrixIdentity(&worldMat);

                                D3DXMatrixIdentity(&worldMat);
	

				D3DXMatrixScaling(&scaleMat, 1.0f, 1.0f, 1.0f);
				D3DXMatrixTranslation(&transMat, m_oPlayer.pos.x, m_oPlayer.pos.y, 0.0f);
				D3DXMatrixMultiply(&worldMat, &scaleMat, &transMat);

				m_pD3DSprite->SetTransform(&worldMat);

                                m_pD3DSprite->Draw(m_pPlayerTex[0], &m_oPlayer.rect, &D3DXVECTOR3(m_imageInfo.Width * 0.5f, m_imageInfo.Height * 0.5f, 0.0f) ,
							0, D3DCOLOR_ARGB(255, 255, 255, 255));


...etc.

Am I missing something?
No one can tell me why the camera isn't working? I'm thinking it's a simple fix in one or two lines of code, I just don't know where to look; I've studied at least 5 similar projects and I have everything pertaining to the camera set up right. I'll post up more info about my project if it's required.
I can't help, but it might be nice if you tell us what API, library, etc. you are using.
Topic archived. No new replies allowed.