This commit is contained in:
StarBeats 2024-12-25 17:39:55 +08:00
parent d9471c4708
commit 816a5c184d
5 changed files with 42 additions and 43 deletions

View File

@ -28,7 +28,7 @@ MonoBehaviour:
m_SupportsHDR: 1
m_HDRColorBufferPrecision: 0
m_MSAA: 1
m_RenderScale: 1
m_RenderScale: 0.75
m_UpscalingFilter: 0
m_FsrOverrideSharpness: 1
m_FsrSharpness: 1

View File

@ -103,7 +103,7 @@ MonoBehaviour:
m_Name: DLSS
m_EditorClassIdentifier:
m_Active: 1
quality: 2
quality: 1
useOptimalSetting: 1
sharpness: 0.126
preExposure: 0.214

View File

@ -71,6 +71,7 @@ namespace X.Rendering.Feature
{
return;
}
supportDLSS = InitFeature();
profiler = new ProfilingSampler("NV.DLSS");
gfxDevice = UnityEngine.NVIDIA.GraphicsDevice.device;
@ -106,11 +107,11 @@ namespace X.Rendering.Feature
public void DoSR(CommandBuffer cmd, RTHandle source, RTHandle destination, RTHandle motionVector, ref RenderingData renderingData)
{
using var scp = new ProfilingScope(cmd, profiler);
var camerdData = renderingData.cameraData;
ref var cameraData = ref renderingData.cameraData;
uint inputWidth = (uint)source.referenceSize.x;
uint inputHeight = (uint)source.referenceSize.y;
uint outputWidth = (uint)camerdData.pixelWidth;
uint outputHeight = (uint)camerdData.pixelHeight;
uint outputWidth = (uint)cameraData.pixelWidth;
uint outputHeight = (uint)cameraData.pixelHeight;
gfxDevice.GetOptimalSettings(outputWidth, outputHeight, quality, out optimalSettings);
bool reset = false;
@ -163,8 +164,8 @@ namespace X.Rendering.Feature
dlssContext.executeData.subrectOffsetY = 0;
dlssContext.executeData.subrectWidth = inputWidth;
dlssContext.executeData.subrectHeight = inputHeight;
dlssContext.executeData.jitterOffsetX = -jitter.x;
dlssContext.executeData.jitterOffsetY = -jitter.y;
dlssContext.executeData.jitterOffsetX = jitter.x;
dlssContext.executeData.jitterOffsetY = jitter.y;
dlssContext.executeData.preExposure = preExposure;
dlssContext.executeData.invertYAxis = 1u;
dlssContext.executeData.invertXAxis = 0u;

View File

@ -15,10 +15,10 @@ EditorUserSettings:
value: 5b00515154055e035459547042705a44154f1e2c2e2e7f677e7d4567e1b9376d
flags: 0
RecentlyUsedSceneGuid-3:
value: 5a57555407545f0b5e0f5f764277594914161e2b787977692b714e64e4b2363b
value: 57050d5004060d590f56087046700f4445164c7e7a7824312e7c4e6bb0e1376d
flags: 0
RecentlyUsedSceneGuid-4:
value: 57050d5004060d590f56087046700f4445164c7e7a7824312e7c4e6bb0e1376d
value: 5a57555407545f0b5e0f5f764277594914161e2b787977692b714e64e4b2363b
flags: 0
vcSharedLogLevel:
value: 0d5e400f0650

View File

@ -1,5 +1,5 @@
%YAML 1.1
%TAG !u! tag:yousandi.cn,2023:
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &1
MonoBehaviour:
m_ObjectHideFlags: 52
@ -19,7 +19,7 @@ MonoBehaviour:
width: 2560
height: 1349
m_ShowMode: 4
m_Title: Console
m_Title: Game
m_RootView: {fileID: 10}
m_MinSize: {x: 875, y: 321}
m_MaxSize: {x: 10000, y: 10000}
@ -43,8 +43,8 @@ MonoBehaviour:
y: 0
width: 1472
height: 770
m_MinSize: {x: 202, y: 221}
m_MaxSize: {x: 4002, y: 4021}
m_MinSize: {x: 200, y: 200}
m_MaxSize: {x: 4000, y: 4000}
m_ActualView: {fileID: 18}
m_Panes:
- {fileID: 14}
@ -96,8 +96,8 @@ MonoBehaviour:
y: 0
width: 784
height: 529
m_MinSize: {x: 100, y: 100}
m_MaxSize: {x: 4000, y: 4000}
m_MinSize: {x: 102, y: 121}
m_MaxSize: {x: 4002, y: 4021}
m_ActualView: {fileID: 19}
m_Panes:
- {fileID: 19}
@ -127,7 +127,7 @@ MonoBehaviour:
m_MinSize: {x: 200, y: 50}
m_MaxSize: {x: 16192, y: 8096}
vertical: 0
controlID: 131
controlID: 65
draggingID: 0
--- !u!114 &6
MonoBehaviour:
@ -153,7 +153,7 @@ MonoBehaviour:
m_MinSize: {x: 300, y: 100}
m_MaxSize: {x: 24288, y: 16192}
vertical: 0
controlID: 167
controlID: 165
draggingID: 0
--- !u!114 &7
MonoBehaviour:
@ -174,8 +174,8 @@ MonoBehaviour:
y: 0
width: 697
height: 1299
m_MinSize: {x: 276, y: 71}
m_MaxSize: {x: 4001, y: 4021}
m_MinSize: {x: 275, y: 50}
m_MaxSize: {x: 4000, y: 4000}
m_ActualView: {fileID: 16}
m_Panes:
- {fileID: 16}
@ -686,9 +686,9 @@ MonoBehaviour:
m_PlayAudio: 0
m_AudioPlay: 0
m_Position:
m_Target: {x: -46.7692, y: -53.881615, z: -65.801216}
m_Target: {x: -30.54924, y: -24.907612, z: -105.301956}
speed: 2
m_Value: {x: -46.7692, y: -53.881615, z: -65.801216}
m_Value: {x: -30.54924, y: -24.907612, z: -105.301956}
m_RenderMode: 0
m_CameraMode:
drawMode: 0
@ -734,13 +734,13 @@ MonoBehaviour:
m_GridAxis: 1
m_gridOpacity: 0.5
m_Rotation:
m_Target: {x: -0.32792997, y: 0.3162188, z: -0.11751483, w: -0.88241905}
m_Target: {x: -0.01710797, y: 0.98246396, z: -0.11578433, w: -0.14516942}
speed: 2
m_Value: {x: -0.32792908, y: 0.31621793, z: -0.117514506, w: -0.8824166}
m_Value: {x: -0.0171079, y: 0.98245996, z: -0.11578386, w: -0.14516884}
m_Size:
m_Target: 58.881893
m_Target: 59.73875
speed: 2
m_Value: 58.881893
m_Value: 59.73875
m_Ortho:
m_Target: 0
speed: 2
@ -758,8 +758,6 @@ MonoBehaviour:
m_FarClip: 10000
m_DynamicClip: 1
m_OcclusionCulling: 0
m_EnableGDRP: 1
m_BackfaceCulling: 0
m_LastSceneViewRotation: {x: 0, y: 0, z: 0, w: 0}
m_LastSceneViewOrtho: 0
m_ReplacementShader: {fileID: 0}
@ -812,7 +810,7 @@ MonoBehaviour:
m_SkipHidden: 0
m_SearchArea: 1
m_Folders:
- Assets/Settings/Mobile
- Packages/com.unity.render-pipelines.universal/Runtime
m_Globs: []
m_OriginalText:
m_ImportLogFlags: 0
@ -820,16 +818,16 @@ MonoBehaviour:
m_ViewMode: 1
m_StartGridSize: 16
m_LastFolders:
- Assets/Settings/Mobile
- Packages/com.unity.render-pipelines.universal/Runtime
m_LastFoldersGridSize: 16
m_LastProjectPath: G:\TJURP
m_LastProjectPath: E:\unity_native_render
m_LockTracker:
m_IsLocked: 0
m_FolderTreeState:
scrollPos: {x: 0, y: 37}
m_SelectedIDs: c8ba0000
m_LastClickedID: 47816
m_ExpandedIDs: 0000000040ba000044ba000048ba000000ca9a3bffffff7f
scrollPos: {x: 0, y: 40}
m_SelectedIDs: 62b80000
m_LastClickedID: 47202
m_ExpandedIDs: 00000000fab400001cb8000000ca9a3bffffff7f
m_RenameOverlay:
m_UserAcceptedRename: 0
m_Name:
@ -857,7 +855,7 @@ MonoBehaviour:
scrollPos: {x: 0, y: 0}
m_SelectedIDs:
m_LastClickedID: 0
m_ExpandedIDs:
m_ExpandedIDs: 00000000fab40000
m_RenameOverlay:
m_UserAcceptedRename: 0
m_Name:
@ -888,18 +886,18 @@ MonoBehaviour:
m_ExpandedInstanceIDs: c6230000000000005aca0000
m_RenameOverlay:
m_UserAcceptedRename: 0
m_Name:
m_OriginalName:
m_Name: Runtime
m_OriginalName: Runtime
m_EditFieldRect:
serializedVersion: 2
x: 0
y: 0
width: 0
height: 0
m_UserData: 0
m_UserData: 47202
m_IsWaitingForDelay: 0
m_IsRenaming: 0
m_OriginalEventType: 11
m_OriginalEventType: 0
m_IsRenamingFilename: 1
m_ClientGUIView: {fileID: 9}
m_CreateAssetUtility:
@ -909,7 +907,7 @@ MonoBehaviour:
m_Icon: {fileID: 0}
m_ResourceFile:
m_NewAssetIndexInList: -1
m_ScrollPosition: {x: 0, y: 0}
m_ScrollPosition: {x: 0, y: 451}
m_GridSize: 16
m_SkipHiddenPackages: 0
m_DirectoriesAreaWidth: 207
@ -954,7 +952,7 @@ MonoBehaviour:
m_ControlHash: -371814159
m_PrefName: Preview_InspectorPreview
m_LastInspectedObjectInstanceID: -1
m_LastVerticalScrollValue: 0
m_LastVerticalScrollValue: 860
m_GlobalObjectId:
m_InspectorMode: 0
m_LockTracker:
@ -997,9 +995,9 @@ MonoBehaviour:
m_SceneHierarchy:
m_TreeViewState:
scrollPos: {x: 0, y: 0}
m_SelectedIDs: 4a030000
m_SelectedIDs: 88b80000
m_LastClickedID: 0
m_ExpandedIDs: 46faffff
m_ExpandedIDs: 5efaffff
m_RenameOverlay:
m_UserAcceptedRename: 0
m_Name: