Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17825

DX9 - Projection stretched

$
0
0
I was making some tests on sample (c++/dx9) of dx sdk, and all works good. When I passed the code to my app, the meshes are getting stretched, i dont know why, both use the same code, same camera, same mesh class etc.. Image of problem: (left its my app, and right its the same code on dx sample) I creating my camera this way: pcCamera->CreateProjectionMatrix( D3DX_PI / 4.4f, (float)RESOLUTION_WIDTH / (float)RESOLUTION_HEIGHT, 20.0f, 4000.0f ); fCameraFov = fFov; fCameraAspect = fAspect; fCameraNearPlane = fNearPlane; fCameraFarPlane = fFarPlane; D3DXMatrixPerspectiveFovLH( &sProjection, fCameraFov, fCameraAspect, fCameraNearPlane, fCameraFarPlane ); lpD3DDevice->SetTransform( D3DTS_PROJECTION, &sProjection ); Thanks.

Viewing all articles
Browse latest Browse all 17825

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>