ADVANCED PHOTO MODE
Documentation
INDEX
INTRODUCTION
The Advanced Photo Mode was inspired by the latest games in the industry, which have an in-game photo mode.
Design and functionality were inspired by The Last of Us: Part II, a first-party game from Sony Interactive Entertainment, developed by Naughty Dog for the Playstation 4, and also God of War (2018) and Shadow of the Colossus (2018).
PHOTOS TAKEN WITH ADVANCED PHOTO MODE
IMPLEMENTATION: USING APM IN YOUR PROJECT
You can consult this video to watch the Advanced Photo Mode installation tutorial, or follow the steps bellow:
STEPS
1.
Open your project;
2.
In Edit → Project Settings → Input, add the action mapping “PhotoMode” (P and Gamepad Special Button Right) and "Gallery" (G and Gamepad Special Button Left);
3.
Make sure that you have all these input events (axis mapping included -- to Free Camera):
4.
Go to your character’s blueprint and add the “PhotoModeComponent” component;
5.
Drag and drop the PhotoModeComponent in the blueprint. With this “get”, call the “Initialization” function. Plug it on the Event Begin Play. Connect the indicated components;
6.
Drag and drop the PhotoModeComponent in the blueprint. With this “get”, call the “Photo Mode” function. Call the “PhotoMode” and "Gallery" events (created in the action mappings). Connect to the functions of PhotoModeComponent, respectively, "PhotoMode" and "OpenGallery";
7.
You can now use photo mode! But if you want some more details, see the additional steps below.
EXTRA 1.
If you want to remove the lines surrounding the widget (like in the image), go to Edit → Project Settings → search for “rule” → in “Focus” seccion, change “render focus rule” to “never”.
EXTRA 2.
If you want to use Advanced Photo Mode in a multiplayer game, just replace the "event begin play" with the configuration below (or follow this video):
This configuration ensures that all references for all players are properly made, avoiding access errors. Note that, despite using the event tick, performance will not be affected, since the "Do Once" node, as the name suggests, performs the initialization only once.
TUTORIALS PLAYLISTS
Do you want to mod or check the features of the Advanced Photo Mode? Check out the tutorials playlists below!
REVIEW________________________________________
Hey,
First of all, thank you for your interest in Advanced Photo Mode.
If you purchased Advanced Photo Mode: thank you very much!
If you have any questions, feel free to send a message on the marketplace page or send me an email (available on the authors page).
Please consider writing a review on the marketplace page (link), each review helps me a lot!
QUICK SETTINGS: CUSTOMIZATION OPTIONS
The photo mode has several customization options. Take your time and check out its features! All variables are commented with a "tooltip" (just hover over the variable). All functions have comments detailing their operation.
UPDATES
LOG
05/05/2022: VERSION 4 UPDATE 1
CODE CHANGES
Added an extra option to pause the game in the photo mode component variables menu; now you can select the pause game method:
PAUSE GAME USING "SET GAME PAUSED" function: pauses the game completely. The image can show some little dots in the unreal engine 5 if you're testing in the viewport mode (they disappear in the packaged game). This is caused by a bug in the unreal engine viewport (which hopefully will be fixed soon by the UE team).
PAUSE GAME USING "GLOBAL TIME DILATION": the image looks a bit better in the viewport, but you'll get a very similar quality in the output photo. This mode doesn't pause background audios, but has a better compatibility with assets that doesn't handle paused game (unusual case).
I recommend the first option (the default, pause game using "set game paused").
05/01/2022: VERSION 4.0 RELEASED
VISUAL CHANGES
New visual. You still have access to version 3.0, if you prefer (in this case, you need to use the files from version 4.24 of your library).
EPIC GAMES LIBRARY CHANGES
The distribution method was changed to "Asset Pack", so now you can import the Advanced Photo Mode directly from your library (using the button "add to project") instead of creating a new project and migrating the content.
CODE CHANGES
Now, instead of the "pause game" function, we're setting the global time dilation to 0.0001. That action increases the compatibility with assets that needs the game "running" (not fully paused) to work properly. Also increases the image quality.
Changes on the screenshot+thumbnail code (no usage of delay nodes -- now the photo and the thumbnail comes out quickly) and the camera doesn't moves after the screenshot.
Added "character rotation" toggle (when true, the character will rotate at the camera direction)
Logo code reworked: corretly fits the screen size. Recommendation: logos with 256x256. You no more need to cut one pixel column/row in each side.
Now, instead of editing the player's camera, we're editing the post process volume (don't worry if your level do not have one or more, the code handle these situations).
"Aperture" slider was changed to a "Selector" slider type, bringing the most common camera apertures.
Now you can change the slider values by scrolling the mouse wheel (when hovering the mouse cursor over the slider or selector).
Added option to focus on the slider when hovering the mouse over the slider (that option is marked as false by default on the photo mode component).
Free camera code reworked: now the "spectator character" type, and it is using the default controls type (so Q and E keys allows you to move up and down).
Removed the option "rotate around character when reaching the maximum distance" of the Free Camera. Now you can choose if you want a maximum distance or not (in the photo mode component) and you can choose the maximum distance. The free camera will stop when reaching the maximum distance, but the camera will move if the input was in a direction that reduces this distance.
Added interpolation in the Camera Rotation, FOV, Camera Distance and camera movement (WASD). So the movement/value changes will be smooth.
Added option to autosize the photo mode UI box (you can find it in the photo mode component). If true, the size will be automatically adjust to the sliders height; if false, the menu will have the same size for all tabs.
04/09/2021: VERSION 3.3 RELEASED
CODE CHANGES
Free Camera Improved (the free camera will adjust its position when it collides with other objects when spawned).
Added slider to rotate the Logo.
Added background blur in the Advanced Photo Mode Menu.
Added a new font style: Louis George Cafe (100% free to use, commercial or not, you can check here: https://www.dafont.com/louis-george-caf.font)
02/09/2021: VERSION 3.2 RELEASED
CODE CHANGES
Removed fixed screen percentage 200% and added a variable with 150% as default value.
Added variable to set the viewport ZOrder easily. Default value = 1.
30/08/2021: VERSION 3.1 RELEASED
CODE CHANGES
1. Added fixed screen percentage 200% when opening photo mode
05/22/2021: VERSION 3.0 RELEASED!
CODE CHANGES
1. The project was redone in several aspects with a focus on optimization (both in the use of computational resources and VRAM usage).
2. Simplified the creation of sliders, toggles, selectors and tabs. This drastically reduced the amount of programming involved in creating them, once the slider was created, all the programming assigned to it is automatically generated, leaving only its initialization and programming of the desired effects.
2.1. When adding a new slider, several customization options are displayed in the details menu such as: font size, color when selected/unselected, slider size, margins size, units, prefixes, maximum and minimum value (the value default is set at initialization according to the developer's), step size, among other options.
2.2. The same is true for toggles, "selector" sliders and tabs.
2.3. To change all the sliders, just modify the widget corresponding to the slider (by modifying this widget, all the others will also be changed, saving time in the modifications, that is, you can change the source or the model of the slider quickly).
2.4. It is possible to choose which tab a button (tab) will open only by inserting the index of the tab in question in the details panel of the button.
3. When taking a photo, we have 2 different outputs: the photo in the desired resolution and a thumbnail in low resolution (in ideal resolution for thumbnail) that will be inserted in the gallery when opening it. Later in this log we will go into more details about how the gallery works.
4. The photos now come out with the following pattern: "YYYY-MM-DD H Min s" and "YYYY-MM-DD H Min s_thumbnail". To make this possible, Advanced Photo Mode now has the creation of a "save game" file that is automatically updated when a photo is taken or when it is deleted from the folder.
5. The reset system has been redesigned. Now no programming is required to reset the slider to its default value, which guarantees its smooth operation.
6. All versions now contain identical code since Epic Games fixed the bug with delays while the game was paused, that is, all tutorials will be identical for any of the versions (4.24, 4.25 and 4.26)
OPTIONS AVAILABLE IN PHOTO MODE
1. Added option for autofocus: automatically displays a grid and a point in the center of the screen that indicates the distance between the camera and the object being viewed.
2. Added the option to change the sensor size (sensor width).
3. Added the option to take photos in different resolutions: by default the default resolutions are available, 720p, 1080p, 1440p, 2160p and default with UI (which considers any HUD other than the logo or borders in the photo - it is important to note that all other options automatically hide any HUD, except logos and borders). The developer can easily add new options (8k, 16k etc, with due care because in these specific cases the photos are large in size and therefore freeze the game for a certain time so that the photo is completed), as well as remove some of the available options.
4. Added a slider selector that allows the addition of post process materials: we have in this version some demonstrative examples such as Outline post process, pixelated effect, heat and brush effect. You can add other effects on your own, such as Cel Shading etc.
5. Added the blue correction option.
6. The Chromatic Aberration and Chromatic Aberration offset sliders have been moved to the Screen Effects tab and are now bundled with Film Grain, Motion Blur and Vignette.
7. It is now possible to change the size of the logo as well as position it anywhere on the screen.
8. The option to change the intensity of the filters has been added.
9. A toggle has been added that allows you to show/hide the grid. The grid is automatically activated during autofocus but can be turned off using this toggle.
10. The SHOW/HIDE mouse option appears only when keyboard/mouse inputs are used.
11. Improvements in the gamepad and the mouse inputs in the menu.
12. Added commands to allow the player's camera to go left/right and not just up/down.
13. Added the option to display the mouse automatically after opening the photo mode and the gallery.
14. Once the mouse cursor is displayed, it is possible to move the camera away from the player using the mouse wheel.
15. Units such as Kelvin, centimeters and etc. have been added to the appropriate sliders.
16. When taking a photo, a thumbnail is now displayed along with the message "PHOTO TAKEN!".
ABOUT THE ALBUM/GALLERY
1. The gallery has been completely redesigned and now works in a different and more dynamic way, consuming a small amount of VRAM and also optimizing it by loading only the displayed pages and freeing up memory instantly when the pages stop showing (the same occurred in previous versions but with a slightly longer delay and not instantly). This new gallery was totally inspired by The Legend of Zelda: Breath of the Wild (Album) gallery.
2. Animations have been added to the gallery for clarity on which photo is selected.
3. Once the mouse cursor is displayed, it is possible to switch pages using the mouse wheel.
4. It is possible to change pages on the gamepad using the thumbstick R.
5. A short tutorial is available on how to add the option to delete photos from the gallery right from the gallery. For this it is necessary to use a plugin capable of managing files, in the tutorial I recommend a plugin from the marketplace that is free and very useful. All the functions to delete the photos are ready, so just add the plugin and call a function.
EXTRAS.
1. A global function has been created to assist in hiding huds when the photo mode is opened (attention: any and every HUD is already automatically hidden from the photo if the selected "resolution" option is different from "Default With UI").
2. We will have a new tutorial to integrate Advanced Photo Mode with ALSV4 (simpler and shorter, I hope, than the current one). The installation tutorials other than ALSV4 are the same, there were no changes in this regard.
12/01/2020: VERSION 2.1 RELEASED!
Optimizations;
13/10/2020: VERSION 2.0 RELEASED!
Gallery Photo Viewer added;
Custom folder path for screenshots;
Added animation for when photos are taken;
Added a function library for screenshots;
Now works with multiplayer.
Fixed the depth of field slider sensitivity;
Fixed free camera sensitivity.