PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

COpying a part of the screen

I'm trying to copy a part of the screen in order to be able to reinitialize graphics.
I'm using using the following piece of code:

following lines for copying the part of the screen I want to use:
case_vide = new E2DSurface; display->CreateSurface(case_vide,TAILLE_CASE,TAILLE_CASE); case_vide->BltFast(pos.x,pos.y,&display-;>buffer,r);

And this one to reinit the graphics
display->buffer.BltFast(pos.x,pos.y,case_vide,r);


I'm using the same method for copying the whole screen and it works but it doesn't work at all for just a part of the screen. If someone sees what's going wrong, thank you:)
Hi Alucardo,

Do you get an error code after calling BltFast (the one that doesn't work)?
I have found the solution (sorry for posting so lately), the size of the rectangle was not correct. Thank you