Commit Graph

27 Commits

Author SHA1 Message Date
zach bethel
7bda0efe14 Deprecated raw UAV access in VT API.
#preflight 628c07b7d8258814a9d8d882

[CL 20370291 by zach bethel in ue5-main branch]
2022-05-25 15:50:23 -04:00
Jeremy Moore
bdc9b1f426 #jira UE-151312
Remove SRGB flag when creating RVT PF_G16 texture.
Fixes issue with texture copy to physical texture for world height RVT.
Issue was triggered by change in RHICopyTexture behavior on some platforms.
#rnx
#preflight 627be8500a5817c9d9518b8a

[CL 20143333 by Jeremy Moore in ue5-main branch]
2022-05-11 12:57:11 -04:00
zach bethel
a00b40ad3b Deprecated GetRenderTargetItem() from IPooledRenderTarget.
#preflight 624ddb30090236773a1a83e0
#rb luke.thatcher

#ROBOMERGE-AUTHOR: zach.bethel
#ROBOMERGE-SOURCE: CL 19655641 via CL 19655653 via CL 19655661
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v938-19570697)

[CL 19657582 by zach bethel in ue5-main branch]
2022-04-06 18:24:24 -04:00
aurel cordonnier
1cfed63bd4 Fix for shipping server
#jira none
[FYI] jeremy.moore
#rnx

#ROBOMERGE-AUTHOR: aurel.cordonnier
#ROBOMERGE-SOURCE: CL 18377121 in //UE5/Release-5.0/... via CL 18377123
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18377124 by aurel cordonnier in ue5-release-engine-test branch]
2021-12-04 12:55:41 -05:00
jeremy moore
30d9ab97ef Add Virtual Texture CSV stats.
Will help determine future VT pool size changes.
#rb andrew.firth
#preflight 616f0c8e6e12ff0001305f52
#lockdown Michal.Valient

#ROBOMERGE-AUTHOR: jeremy.moore
#ROBOMERGE-SOURCE: CL 17865095 via CL 18004160 via CL 18370046 via CL 18370143
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18370163 by jeremy moore in ue5-release-engine-test branch]
2021-12-03 13:27:21 -05:00
jeremy moore
748c4023e1 Allow multiple physical pools to be created for the same virtual texture format.
Producers will be randomly distributed between physical pools.
The maximum physical pool tile size is set by r.VT.SplitPhysicalPoolSize.
Setting a size of 64 will force all pools to be divided so that their page tables fit in 16 bits.
This makes it possible to use large physical pools without doubling the cost of page table memory.
#rb none
[FYI] ben.ingram
#preflight 611a616a8ff5540001cf6575

#ROBOMERGE-SOURCE: CL 17175504 via CL 17175510
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v855-17104924)

[CL 17175517 by jeremy moore in ue5-release-engine-test branch]
2021-08-16 09:38:03 -04:00
jeremy moore
133f595257 Added min/max scaled virtual texture pool size.
This gives us better control on pool scaling.
Also adjusted the thresholds for vt residency mip map bias.
#preflight 6112ac8acf0cdd0001c2f4ef

#ROBOMERGE-SOURCE: CL 17120014 via CL 17120019
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v855-17104924)

[CL 17120032 by jeremy moore in ue5-release-engine-test branch]
2021-08-10 13:51:40 -04:00
jeremy moore
b6035db644 Small VT reporting improvements.
Don't double report header size to avoid confusion about total cost.
Use MB for disk usage.
Report residency oversubscription even when r.VT.Residency.MaxMipMapBias is 0.
#rb none
#preflight 610bdd9d76f51a0001d18c13

#ROBOMERGE-SOURCE: CL 17067448 via CL 17067674
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v853-17066230)

[CL 17067684 by jeremy moore in ue5-release-engine-test branch]
2021-08-05 10:06:29 -04:00
yangke li
5fb9374d13 Add a Mobile friendly RVT MaterialType BaseColor_Normal_Roughness with basecolor in RT0, NormalXY and roughness in RT1, NormalZ is considered always a positive number( which is the situation for local space normal)
Add A  flag bUseLowQualityCompression to BaseColor_Normal_Roughness, which fakes compression by 16bit format(RGB565)

#rb Dmitriy.Dyomin

#ROBOMERGE-SOURCE: CL 16977982 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v838-16927207)

[CL 16977984 by yangke li in ue5-release-engine-test branch]
2021-07-27 22:07:02 -04:00
jeremy moore
7124ab4a00 #jira UE-117953
#jira UE-109349
Add mip map bias for virtual texture sampling.
Respects the existing r.MiipMapLodBias CVar.
Also add residency tracking for each virtual texture physical pool.
If the pool has been created from a config with the bEnableResidencyMipMapBias flag set then a mip map lod bias is applied to bring the pool back within budget.
The residency mip map lod bias is applied globally (combined with the global mip map lod bias).
In future it could be good to apply the mip map lod bias per physical pool, but this will require tracking all physical pool combinations for each page table.
Physical pool residency tracking can be shown on screen with r.vt.residency.show CVar.
#rb ben.ingram

#ROBOMERGE-SOURCE: CL 16724483 via CL 16724487
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v835-16672529)

[CL 16724488 by jeremy moore in ue5-release-engine-test branch]
2021-06-20 18:47:26 -04:00
christopher waters
2c3c5c5198 Adding GRHISupportsUAVFormatAliasing support to D3D12RHI.
When creating a BCn texture with UAV support, create a secondary ID3D12Resource that aliases the same memory and can be used as its UAV. This alias resource has to be considered during transitions to/from the UAV state where we insert an aliasing barrier and possibly another state transition for the 'real' resource.
Created FD3D12ResourceDesc which extends D3D12_RESOURCE_DESC. This type should allow us to pass around future UE-only creation info without modifying all the allocation function signatures. This is only implemented enough to cover Textures right now, can be extended in the future.

#jira UE-114150
#rb kenzo.terelst
#preflight 60b944100249c300015e7cd6


#ROBOMERGE-OWNER: christopher.waters
#ROBOMERGE-AUTHOR: christopher.waters
#ROBOMERGE-SOURCE: CL 16555034
#ROBOMERGE-BOT: (v828-16531559)
#ROBOMERGE-CONFLICT from-shelf

[CL 16555067 by christopher waters in ue5-main branch]
2021-06-03 19:08:56 -04:00
Luke Thatcher
d9728437c1 Add UAVFormat field to FPooledRenderTargetDesc to allow selection of an aliasing format when retrieving surfaces from the pool
- Used by the VT system to alias DXT surfaces with integer formats.

#rb Zach.Bethel
#fyi Christopher.Waters
#jira UE-114726
#preflight 60a3aca422cce000018d88ad

[CL 16369514 by Luke Thatcher in ue5-main branch]
2021-05-18 12:34:02 -04:00
Ben Ingram
71d9de4675 Display on-screen message when VT pool is oversubscribed
#rb none
#jira none

[CL 16201143 by Ben Ingram in ue5-main branch]
2021-05-04 19:20:32 -04:00
Ben Ingram
6b158562d7 Update names of render targets used for VT to actually include the word 'Virtual'
#rb none
#jira none

[CL 14837842 by Ben Ingram in ue5-main branch]
2020-12-02 15:35:05 -04:00
Marcus Wassmer
3b81cf8201 Merging using //UE5/Main_to_//UE5/Release-Engine-Staging @14384769
autoresolved files
#rb none

[CL 14384911 by Marcus Wassmer in ue5-main branch]
2020-09-24 00:43:27 -04:00
Marc Audy
11f5b21210 Merging //UE5/Release-Engine-Staging @ 13752110 to Main (//UE5/Main)
#rnx

[CL 13753156 by Marc Audy in ue5-main branch]
2020-06-23 18:40:00 -04:00
dmitriy dyomin
6d284b45a3 Fixed: Runtime Virtual Texture crash on mobile
#jira UE-90300
#rb none

#ROBOMERGE-SOURCE: CL 12057079 in //UE4/Release-4.25/... via CL 12057088
#ROBOMERGE-BOT: RELEASE (Release-4.25Plus -> Main) (v657-12064184)

[CL 12076323 by dmitriy dyomin in Main branch]
2020-03-09 13:21:37 -04:00
Rolando Caloca
5b82f15def Copying //UE4/Dev-RenderPlat-Staging@11388153 to //UE4/Main
#rb none
#rnx

[CL 11388545 by Rolando Caloca in Main branch]
2020-02-12 13:27:19 -05:00
dmitriy dyomin
32bb8acd0b Support virtual textures on mobile platforms. Requires Vulkan, OpenGL ES3.1 + SRV, iPhone8 and up.
Disabled by default, set r.Mobile.VirtualTextures=1 to enable
known issues: RVT compression is not implementted, Android OpenGL will have R and G channels swapped for uncompressed streaming VT, no sRGB support
#jira UE-79955
#rb jeremy.moore


#ROBOMERGE-SOURCE: CL 11070636 via CL 11070637
#ROBOMERGE-BOT: (v637-11041722)

[CL 11070638 by dmitriy dyomin in Main branch]
2020-01-20 22:16:23 -05:00
ryan durand
0f0464a30e Updating copyright for Engine Runtime.
#rnx
#rb none


#ROBOMERGE-OWNER: ryan.durand
#ROBOMERGE-AUTHOR: ryan.durand
#ROBOMERGE-SOURCE: CL 10869210 via CL 10869511 via CL 10869900
#ROBOMERGE-BOT: (v613-10869866)

[CL 10870549 by ryan durand in Main branch]
2019-12-26 14:45:42 -05:00
jeremy moore
ffefadf9d5 Fix some missing texture creation flags.
Enable UAV creation for VT physical texture where supported.


#ROBOMERGE-SOURCE: CL 9804698 via CL 9804747 via CL 9804799
#ROBOMERGE-BOT: (v546-9757112)

[CL 9804825 by jeremy moore in Main branch]
2019-10-24 13:23:31 -04:00
jeremy moore
636afa56b4 Add console variable scale factor for virtual texture physical pools
This allows per platform device overrides



#ROBOMERGE-SOURCE: CL 9428247 via CL 9428248 via CL 9444144 via CL 9449040 via CL 9449233
#ROBOMERGE-BOT: (v495-9448618)

[CL 9451398 by jeremy moore in Main branch]
2019-10-07 13:11:51 -04:00
jeremy moore
1310cc4462 Fix for Windows 7 crash
#jira


#ROBOMERGE-SOURCE: CL 9389857 via CL 9389859 via CL 9389861 via CL 9389862 via CL 9389863
#ROBOMERGE-BOT: (v456-9359915)

[CL 9392182 by jeremy moore in Main branch]
2019-10-03 11:09:54 -04:00
jeremy moore
55bb85a00d Support passing UAV of physical texture to RuntimeVirtualtexture::RenderPages
This will allow compressing direct to physical texture on platforms that support it
Some small RHI changes will have to be approved before turning on though


#ROBOMERGE-SOURCE: CL 9291051 via CL 9291054 via CL 9291057 via CL 9291060
#ROBOMERGE-BOT: (v452-9288972)

[CL 9291062 by jeremy moore in Main branch]
2019-09-29 17:29:22 -04:00
jeremy moore
bb9eb8e48a Make VT pools respect budget size
Use floor instead of ceil so that budget is our upper memory limit


#ROBOMERGE-SOURCE: CL 8970428 via CL 8970429 via CL 8970430
#ROBOMERGE-BOT: (v436-8951088)

[CL 8970431 by jeremy moore in Main branch]
2019-09-22 22:48:39 -04:00