Sign in to follow this  
Frente

Why [pRect doesn't fit inside the surface]??

Recommended Posts

I wrote these code in my program:
g_pd3dDevice->Clear(0,NULL,D3DCLEAR_TARGET|D3DCLEAR_ZBUFFER,D3DCOLOR_XRGB(0,0,0),1.0f,0);
	if(SUCCEEDED(g_pd3dDevice->BeginScene())){
		
	  g_pd3dDevice->UpdateSurface(Surface,NULL,BackBuffer,NULL);

	  g_pd3dDevice->EndScene();
	
	}
	g_pd3dDevice->Present(NULL,NULL,NULL,NULL);
	Surface->Release();
And before it,I use D3DXLoadSurfaceFromFile(Surface,NULL,NULL,Path,NULL,D3DX_FILTER_NONE,0,NULL) to load a jpg file to Surface,and i'm sure it's OK. But why i got these ERROR??What's these mean?thx~ Direct3D9: (ERROR) :pRect doesn't fit inside the surface Direct3D9: (ERROR) :Invalid dest rect specified. UpdateSurface failed [Edited by - Frente on September 6, 2005 1:51:28 AM]

Share this post


Link to post
Share on other sites
Oh i forgot it...
But if I want to load a image from a file and i set the size of BackBuffer bigger then the size of the image,the image didn't presents as it's normal size~
How to solve it ?
thx

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this