How to set automatically a screenshot as a background?

Hello everybody, here’s my problem.

I would like to know how to automatically take a screenshot in the BGE, and then calling a new scene with this screenshot as background.

I’ve tried with python:

import Rasterizer

But when I’m playing, executing this sript make a popup window appear, asking for overwrite confirmation.

Is it possible to save the file without having this popup appear?
Then next, how to automatically load an image as a background when setting a scene?

Thanks for your answers.

Because you have an always sensor attached to the python script, youve got the script set to take a picture every millesecond or something like that.

do this:

keyboardsensor = cont.getSensor("keyboard sensor")
if keyboardsensor.isPositive:

You should put a jpg extension on the end of the picture file name because i’ve otherwise experienced troubles opening the picture file.:confused:

… and for the background (skybox you mean?) thats not really possible or practical…
just open up the image into the blend file and go from there. opening up an image through python? nahhhhhhh…

Can’t you just suspend your current scene and start new scene as overlay?