Haoris
(Haoris)
June 27, 2020, 1:49pm
222
MostHost_LA:
You might loose your mind currently. Each tile needs its own material. Each material needs to specify the rtvt. Each tile needs to render to the correct rtv.
It works, but on anything large enough to require world composition it is a massive amount of work and needless files.
if/when they patch the instances to accept interchangeable rtvs, then the process would be a little easier. Create an instance for each tile and set it up on the tile itself.
Ok, that’s what I thought, each tile would need its own RVT. Yes, that would be a lot of work for 1000+ tiles (I’m just reminding that Novigrad map of The Witcher 3 is made of 2116 tiles :rolleyes: )
We should be able to use only one RVT on the main landscape actor but then we go back to this point and there’s no more news about this :
The resolution of a given virtual texture ultimately is limited by the page table size. VT is typically divided into tiles of 128x128 pixels. Each VT gets a page table allocated, where each pixel in the page table corresponds to 1 tile in the physical texture. So an 8k x 8k VT would require a 64x64 page table texture. This isn’t generally an issue for more “normal” sized VTs, but it becomes a problem when you want to create huge VTs to cover terrain. The page table size is limited by GPU texture limits, and it’s also an uncompressed texture, so once it gets too large it actually starts to consume a large amount of memory.
So for terrains, I think the current state of the art is to dynamically adjust the page table as the player moves through the world, so only pages “close enough” to the camera origin are kept in memory. There are various ways to do this, one of them being the Adaptive Virtual Texture method Jeremy mentioned in the live stream. I believe there are slides online somewhere that describe how this works in the context of one of the recent Far Cry games. The plan is for us to implement something like this for future version of UE4, but I don’t have any specifics to offer yet. For now RVT will be limited to the current size limits, so it won’t work for huge terrains.