Is it possible to capture a snapshot of just a portion of the existing screen?
This is just a test to see if I understand _Newimage and _Putimage well enough. And since the following code doesn't work, I obviously don't .
Anyway I looked it up but I haven't found any specific details on capturing a portion of the screen like this.
I should mention that this was pasted into the program where the screen already had been created. So this is meant to be getting a snapshot of the game screen and then placing that onto a black screen, just as a test.
This is just a test to see if I understand _Newimage and _Putimage well enough. And since the following code doesn't work, I obviously don't .
Code: (Select All)
Dim snap&
snap& = _NewImage(100, 100, 32) 'create a small blank image 100x100
_PutImage (400, 400)-(500, 500), 0, snap& 'grab a section of the screen (source) and copy it to the small image (destination)
Sleep
Cls
_PutImage (100, 100), snap&, 0 'take the new image and place it onto the screen (should now be a black screen with this new image appearing)
Sleep
Cls
Sleep
_PutImage (200, 200), snap&, 0 'now the same small image should appear in a different place
Sleep
Anyway I looked it up but I haven't found any specific details on capturing a portion of the screen like this.
I should mention that this was pasted into the program where the screen already had been created. So this is meant to be getting a snapshot of the game screen and then placing that onto a black screen, just as a test.