Unreal Engine

Unreal - take a photo and save it locally.


Unreal tomar foto y guardar de forma local


Primero crea un widget.

First, create a widget.

Agrega el canvas y luego una imagén del 100 por ciento del tamaño.

Add a canvas, and then an image that is 100% of the size.

Indicamos la imagén para poder animarla.

Specify the image so that it can be animated.

Indicamos que queremos animar el color y opacidad.

Specify that you want to animate the color and opacity.


Animamos el canal alfa y le indicamos la opacidad en el primer frame y en el tercer frame.

Animate the alpha channel and specify the opacity in the first frame and the third frame.

Seleccionamos el third person

Select the third person.

Básicamente con este código estamos diciendo lo siguiente: al presionar la tecla f12 vamos a crear un widget(el que creamos previamente y al que llamamos flash), luego lo añades a la escena mediante add to viewport, espera 0.1 segundos y ejecuta un comando que haga una captura de pantalla y lo guarda en el pc.

Basically, with this code we are saying the following: when pressing the F12 key, we will create a widget (the one we created previously and called flash), then add it to the scene using add to viewport, wait 0.1 seconds, and execute a command that takes a screenshot and saves it to the computer.

Al jugar si presionamos f12 tomamos la foto.

When playing, if we press F12 we take the photo.