NVIDIA Ansel Photo Mode and NVIDIA Highlights Video Capture Tool

NVIDIA Ansel Photo Mode and NVIDIA Highlights Video Capture Tool

NVIDIA Ansel Photo Mode and NVIDIA Highlights Video Capture Tool Bryan Dudash, Senior Manager Developer Technology March 23rd , 2018 Booth #223 - South Hall www.nvidia.com/GDC 2 Ansel takes in-game photography further FREE CAMERA FILTERS EXR SUPER 360 RESOLUTION 3 MASS EFFECT: ANDROMEDA 4 TM TM STAR WARS BATTLEFRONT II 5 HELLBLADE: SENUA’S SACRIFICE 6 EASY GAME INTEGRATION THE WITCHER 3 HAD 150 LINES OF CODE 7 THE WITCHER 3: WILD HUNT 2M ANSEL PHOTOGRAPHS 8 Community Ansel Photographs Super Resolution/ 360 / VR support Upload directly from GeForce Experience AVAILABLE TODAY! SHOTWITHGEFORCE.COM9 ANSEL SDK Gameworks Github UE 4.14+ Unity Plugin Available for all games and major engines Download from developer.nvidia.com/Ansel 10 Ansel Architecture Graphics API driver Game shim GeForce Game Profile Ansel core Ansel SDK Ships with driver Ships with game 11 Join the GameWorks developer program ▪ https://developer.nvidia.com/Ansel ▪ The above link will instruct you to do the following: o If you don't have an account on developer.nvidia.com or are not a registered member of the NVIDIA GameWorks developer program then register here: https://developer.nvidia.com/developer-program/signup o If you are logged in, accept the EULA and enter your GitHub username at the bottom of the form: https://developer.nvidia.com/content/apply-access-nvidia-physx-source- code o You should receive an invitation within an hour 12 https://github.com/NVIDIAGameWorks/AnselSDK 13 Agenda ▪ Ansel Photo Mode o Run through the integration of Ansel into a game o Stop along the way to discuss some common issues and how to address them o Will not cover every corner case but that is what the docs are for 14 The four concepts involved in integration 1. Configuration 2. Session 3. Camera 4. Hints (optional) 15 Setting the Configuration 16 Configuration contents 17 Default orientation in game coordinates up right forward 18 Capture latencies time Present k-1 Present k Present k+1 Present k+n Render frame k Render frame k+1 Render frame k+2 Update frame i captureLatency = 0 captureLatency = 1 captureSettleLatency = 0 captureSettleLatency = n captureLatency is the number of D3D present calls between update and present for a frame captureSettleLatency is the number of D3D present calls between first present and final accumulation for a frame (temporal AA, etc) 19 Discontinuous camera movement Two adjacent frames from a 360 capture (yaw angle for camera is changed in these shots): ▪ Frame accumulation effects need time to settle (via captureSettleLatency) ▪ Or disabled during multipart shots 20 Session ▪ Session is the period when a player is in Ansel mode ▪ Session is typically started & stopped by the player 21 Event timeline for a Session time Present n triggers User deactivates Ansel stopSessionCallback Render frame k Render frame k+1 …………. Render frame n Render frame n+1 Ansel session Present k-1 Present k triggers startSessionCallback & game approves User presses ALT+F2 to activate Ansel 22 NEED NEW SCREENSHOT 23 Camera 24 Camera update during Ansel Session 25 Offset and view angle for Super resolution 27 Rotation and view angle for 360 photos 28 Post-effects and multipart shots ▪ Most post-effects work fine but: o Non-uniform frame effects, like vignette, need to be disabled during multipart capture o Temporal frame effects like motion blur and LOD fading should also be disabled o Ansel has Vignette functions, so should disable in game vignetting unless really necessary. 32 High bang to developer buck ratio ▪ Ansel SDK is easy to integrate ▪ Ansel engine plug-ins are even easier ▪ Most games require only minor modifications to support Ansel – multiplayer games with no replay functionality can be a challenge though ▪ Your players will thank you ▪ The beauty and wonder of your game will be captured and shared in stunning photos 34 Links https://developer.nvidia.com/Ansel https://github.com/NVIDIAGameWorks/AnselSDK “NVIDIA Ansel” in the Unity Asset Store https://assetstore.unity.com/packages/tools/camera/nvidia-ansel-74758 Unreal Engine 4 contains Ansel integration in the main branch. Yay! 37 NVIDIA HIGHLIGHTS FULLY AUTOMATIC CAPTURE Captures Video Automatically Based On Game Events Leverages GeForce Experience overlay and ShadowPlay technology Easy Upload To YouTube, Facebook, Imgur, or Weibo 39 What is Highlights? ▪ HIGHLIGHTS SDK allows games to automatically save screenshots and/or videos of important events VIDEO SCREENSHOTS PREVIEW SHARE USER CONTROL 4K 60 FPS H.264 4K PNG Images In-game overlay Facebook Video settings 40 No impact to gameplay No impact to gameplay Review, trim, upload YouTube Highlights settings Google+ Notifications settings Imgur Disk space settings HIGHLIGHTS IN FORTNITE BATTLE ROYALE 41 What are the benefits? ▪ Features for Gamers ▪ Value for Developers o Fully automatic o Low overhead • Hands free captures • Leverages existing ShadowPlay • No need to guess when something technology interesting might happen o Simple interface o Increased immersion • No need to implement from scratch o Increased replay value using • No need to incorporate a highlights as achievements complicated or heavy API 43 EXAMPLE INTEGRATION ` Begin Highlight End of Game Match Notification Summary 44 Example Game Flow using Highlights Game triggers Game calls Game Player kills 5th Game N second Match ends Highlights session starts opponent continues Game highlight summary Highlights API GFE saves User reviews video of last highlights in GeForce N seconds GFE overlay Experience User uploads Pentakill clip to YouTube 45 What Makes a Good Highlight? ▪ A good highlight is an event that users will want to save o Something they will take pride in, find funny, or want to share via social media ▪ Some examples o Killing a boss o Multi-kills o Revenge kills o Discovering a hidden area o Rare accomplishments/treasure/combos o Odd or interesting deaths 46 Highlights Architecture NVIDIA Display Driver ShadowPlay Capture DX/Frame Game Process APIs Buffers Exports & Callbacks Highlights Core GFESDK.DLL IPC Ships with Ships with game GeForce Experience 47 HIGHLIGHTS SDK AVAILABLE TODAY Available for all games and major engines Download from developer.nvidia.com/highlights 48 4 steps to access Highlights in Ue4 https://github.com/NVIDIAGameWorks/GfeSDK-UE4Plugin In your copy of UE4 source: 1. In git bash/cmd navigate to Engine\Plugins\Runtime\Nvidia 2. git submodule add -b 4.18 https://github.com/NVIDIAGameWorks/ GfeSDK-UE4Plugin.git GfeSDK 3. Rebuild engine 4. Enable via plugins menu in Editor 49 Also in Unity https://assetstore.unity.com/packages/tools/video/nvidia-highlights-100938 1. Search for “NVIDIA Highlights” on the asset store 2. Download & Import into current project 3. Access Highlights C# functions through NVIDIA.Highlights namespace 50 About the Engine Plugins ▪ Unreal Engine 4 o C++ and Blueprint support o Currently Unreal Engine 4.18 o https://github.com/NVIDIAGameWorks/GfeSDK-UE4Plugin ▪ Unity o Provides C# interfaces o Unity 5.6(Basic or Pro) or Unity 2017 • Unity 2017 required for sample projects o https://www.assetstore.unity3d.com/en/#!/preview/100938/302229 51 Custom Integration Overview ▪ Include “gfesdk/isdk.h” o Basic GFE SDK initialization ▪ Include “gfesdk/highlights/ihighlights.h” o Highlights specific functions ▪ Add GFESDK.dll into game package o At runtime load DLL in game process • Link via lib, or manually load, etc • Recommend perform Digital Signature Check to prevent malicious/rogue code ▪ Call various SDK interfaces we’ll explain in this talk. 52 Example Highlights API Flow Game Start Match Start Match End Game End Event ... Event Time ConfigureAsync() OpenSummaryAsync() OpenGroupAsync() SetVideoHighlightAsync() SetVideoHighlightAsync() 53 NVGSDK_Scope scopes[] = { NVGSDK_SCOPE_HIGHLIGHTS, NVGSDK_SCOPE_HIGHLIGHTS_VIDEO, NVGSDK_Create() NVGSDK_SCOPE_HIGHLIGHTS_SCREENSHOT }; NVGSDK_ScopePermission scopePermissions[3]; ▪ Initializes the SDK interface with the requested NVGSDK_RetCode returnCode = NVGSDK_SUCCESS; highlight scopes NVGSDK_HANDLE * handle = INVALID_HANDLE; ▪ Parameters: NVGSDK_CreateInputParams createParams = {0}; createParams.appName = "MyGame"; createParams.scopeTable = &scopes[0]; o Handle to the interface createParams.scopeTableSize = 3; createParams.pollForCallbacks = false; o Create input parameter structure NVSDK_CreateResponse response; o Response structure response.scopePermissionTable = &scopePermissions[0]; response.scopePermissionsTableSize = 3; ▪ Success returns (more than one!): returnCode = NVGSDK_Create(handle, createParams, response); o NVGSDK_SUCCESS if(NVGSDK_SUCCEEDED(returnCode) { o NVGSDK_IPC_SUCCESS_OLD_SDK // Success path } else o NVGSDK_IPC_SUCCESS_OLD_GFE { // Failure handling } 54 int const NUM_HIGHLIGHTS = 2; NVGSDK_Highlight highlights[NUM_HIGHLIGHTS] = {0}; NVGSDK_LocalizedPair highlight1Translation[2] = { { "en-US", "Highlight One" }, { "es-MX", "Resalte Uno" } }; NVGSDK_ConfigureAsync() highlights[0].id = "highlight1"; highlights[0].userInterest = true; ▪ Provides a list of all possible Highlights to GFE highlights[0].highlightTags = NVGSDK_HIGHLIGHT_TYPE_ACHIEVEMENT; highlights[0].significance = NVGSDK_HIGHLIGHT_SIGNIFICANCE_VERY_GOOD; o This is the point GFE knows about the highlights[0].nameTable = &highlight1Translation[0]; highlights highlights[0].nameTableSize = 2; NVGSDK_LocalizedPair highlight2Translation[2] = { ▪ Parameters: { "en-US", "Highlight Two" }, { "es-MX", "Resalte Dos" } }; highlights[1].id = "highlight2"; o Handle to the interface highlights[1].userInterest = true; highlights[1].highlightTags

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    65 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us