[Question] Handheld camera

Question

Hi folks! I'm trying to make an in-game handheld camera that the player can use. So far the player holds down the right button to zoom but how do I take an in-game picture from a camera?

I looked at the SceneCaptureComponent2D but had little luck with creating a still image with it.

Edit: The camera is going to be used for a Pokemon snap like game.

Posted Jun 25, 2016, 1:52 PM UTC · edited

16
NaojirouDev•

Didn't play Pokemon snap so, do these pictures be persistent through levels? Like, will you have a collection of pictures that can be checked after you shut the game etc.

2
SuppeeOPIndie•

In pokemon snap they do but that's not the intention here, only for the duration of a match

1
NaojirouDev•

There probably isnt a blueprint solution for that (At least not for my method).

You can make a file explorer and use highresshot capability. Simply, make a camera (not a model but a component). When you want to take a shot, possess the camera, take a highresshot. Use the file explorer to find out which screenshot is yours (Keep the file names in an array, fetch the files again to find out the difference (Also there might be a function which returns the name of the screenshot, not sure). You can dynamic load the image into a texture and view it whenever/wherever you want that accepts a texture (Thus material).

If you want to take the adventure, there are the codes lying around in the internet but I have the implementation for all of these and I can send the source code if you want. I don't know if there is another way but with this, you can also save them as actual files if you see any need for that.

Edit: You can also make it not persistent through levels with SceneCaptureComponent2D, however they wont be actual images but harry potter style moving images unless if there is a way to stop the render of scc2d and making it static.

1
SuppeeOPIndie•

I actually already setup console command to Shot (just for testing) but is there a way to clean the folder after pictures have been taken?

1
NaojirouDev•

You probably need to have a file explorer for that purpose. Screenshot works in a fire and forget manner.

1