Game engine with realtime path tracing?

General project and community related discussions and offtopic threads.
alexwbc
Posts: 6
Joined: Sat May 19, 2018 5:09 pm

Game engine with realtime path tracing?

Post by alexwbc » Tue May 29, 2018 9:42 pm

Not for a First Person Shooter, but a game engine render which specifically target a set of games where the camera moves very little, and dynamic objects movement can be easily predicted (in a way certain area of the screen are prioritized, and so spare precious rays calculations).


One possible game genre I can thing of are point and click adventure (third person, camera fixed panning in predictable directions, light condition/room kept under control to avoid the realtime engine being clutter with unnecessary work).

User avatar
Dade
Developer
Developer
Posts: 3135
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: Game engine with realtime path tracing?

Post by Dade » Tue May 29, 2018 11:00 pm

Support LuxCoreRender project with salts and bounties

alexwbc
Posts: 6
Joined: Sat May 19, 2018 5:09 pm

Re: Game engine with realtime path tracing?

Post by alexwbc » Wed May 30, 2018 10:55 am

I remember I posted that same exact video in a gamedev community.

There was always been some interest in real-time path tracing; but technical limitations: when realtime path tracing is shown, they always try to emphasize it with free movement camera.

https://www.youtube.com/watch?v=BpT6MkCeP7Y

While a free-move camera with photorealistic color may be impressive, unlucky that's immediately show where path tracing fall short: noise effect tend to be more visible when the whole screen is updated.

It appears to me that another mistake they do in showcasing real-time path tracing... is use extremely low-poly models:
https://www.youtube.com/watch?v=x19sIltR0qU

I am talking about speculation, my competence in path tracing is not that great (hopefully I'll be corrected here, so I can improve my knowledge on this issue).

Isn't one of the advances of path tracing (over raster) the possibility to have much detailed (very high poly) models than raster?

Of course, this would take more VRAM, but another advance woldn't be the less need of all the 2k/4k textures a PBR raster render would need (also, less or no need for LODs); would that be another relevant advance?

Vertex colours: if we're using high poly models, vertex colours could reach a certain grade of detail... would they work as substitute of the classic raster's PBR albedo texture map (no need of UV at all! :o) ?

A game like Double Dragon (side scrolling brawler) could be optimal for a real time rendering engine? Becouse:

- It's action based
- camera move very slowly: the perspective change very little,in a very predictable way (object in foreground can be blurred, so you can move big object with relatively small number of rays; I think they used a similar trick in video about of StarWars made by Unreal/Nvidia. notice how camera does actually move very little (jerky moments to make it "alive" seems to be more a combination of pan and zoom in post-processing )
- "sprites" (actual 3d highpoly models) move also quite practicably on a flat surface, also they tend to be distant.. so the "square" in which these models are are little and more rays can be shoot in there safely
- if camera move always/only in one direction, it's could be easier to render the offscreen part (on the left)... so there's supposed to do less work when the actual camera pan on the right.

alexwbc
Posts: 6
Joined: Sat May 19, 2018 5:09 pm

Re: Game engine with realtime path tracing?

Post by alexwbc » Wed Jan 30, 2019 10:41 am

Fully fledged game engine with real time path tracing is out:
http://brechpunkt.de/q2vkpt/

(it's a reimplementation of Quake 2 with a full path tracing one)
It uses a single bounce on an expensive RTX card to maintain 60 FPS ( (2560x1440, RTX2080Ti); the trick is to use Nvidia algorithm to "blur" the image for a consistent look:
Image

Funny thing is the game looks ugly becouse it's very old-school low poly, while the true potential of the path tracing is the relatively (compared to raster) inexpensiveness of the polycount. Modern photo-realistic AAA games require lot of textures/map to simulate geometry on low/mid-poly models (also lot of ram "wasted" for LOD and other trick);
Path Tracing true potential is how it enable to use real highpoly meshes and less/no need for occlusion/lod and other tricks. This six year old video shows a dynamic scene with about "300 million dynamic triangles"... on a powerful, yet old, Titan card.

Return to the project itself, this is how it looks:
https://www.youtube.com/watch?v=vrq1T93uLag

and this is the analysis made by Digital Foundry:

https://www.youtube.com/watch?v=BRCAfdBMe2Y

User avatar
lacilaci
Donor
Donor
Posts: 1616
Joined: Fri May 04, 2018 5:16 am

Re: Game engine with realtime path tracing?

Post by lacilaci » Wed Jan 30, 2019 12:00 pm

I don't know if full pathtracing is the best way to go...
You can see unreal and unity realtime archviz on a level that is 99% comparable with offline rendering.
It's a pain to set up though, due to need to have all uv's unwrap and bake lighting, set up reflection probes etc etc...

I think rasterized graphics(for general fast rendering) + raytracing(shadows, reflections, refractions...) + some not yet existing method of realtime GI calculation could be in future a merging point for offline and realtime rendering...

Today, it would seem proper and detailed GI calculation of any kind is too slow for realtime or not detailed enough.

User avatar
FarbigeWelt
Donor
Donor
Posts: 856
Joined: Sun Jul 01, 2018 12:07 pm
Location: Switzerland
Contact:

Re: Game engine with realtime path tracing?

Post by FarbigeWelt » Wed Jan 30, 2019 12:29 pm

Dade wrote:
Tue May 29, 2018 11:00 pm
I wrote this (7 years ago !): https://www.youtube.com/watch?v=Dh9uWYaiP3s&t=5s
Very nice game, should have won an Indie prize for idea and realization!

(The game remembers me on of my first models made in Real 3D on Amiga 4000, taking hours for a 800x600 still. On your youtube channel there is a video for Mandelbrot on gpu, this could be a good remember procedural texture for luxcorerender, if iteration number grew Julia set into colored 3. dimension)
Light and Word designing Creator - www.farbigewelt.ch - aka quantenkristall || #luxcorerender
160.8 | 42.8 (10.7) Gfp | Windows 10 Pro, intel i7 4770K@3.5, 32 GB
2 AMD Radeon RX 5700 XT, 8 GB || Gfp = SFFT Gflops

User avatar
FarbigeWelt
Donor
Donor
Posts: 856
Joined: Sun Jul 01, 2018 12:07 pm
Location: Switzerland
Contact:

Re: Game engine with realtime path tracing?

Post by FarbigeWelt » Wed Jan 30, 2019 12:39 pm

lacilaci wrote:
Wed Jan 30, 2019 12:00 pm

Today, it would seem proper and detailed GI calculation of any kind is too slow for realtime or not detailed enough.
Sounds a bit to pessimistic in my ears.
7nm to 10nm structure based power optimized IC chiplets can be assembled and stack in way to produce CPU and GPU with estimated pace of doubling number of cores in less than a year if market demands this speed what depends on crave for hyper realistic, immersive games. A billion user market.
Light and Word designing Creator - www.farbigewelt.ch - aka quantenkristall || #luxcorerender
160.8 | 42.8 (10.7) Gfp | Windows 10 Pro, intel i7 4770K@3.5, 32 GB
2 AMD Radeon RX 5700 XT, 8 GB || Gfp = SFFT Gflops

alexwbc
Posts: 6
Joined: Sat May 19, 2018 5:09 pm

Re: Game engine with realtime path tracing?

Post by alexwbc » Wed Jan 30, 2019 3:31 pm

The future is all in the hands of those who pioneer a technology.
A voxel based game seemed a weird idea at time until someone didn't find that "magical formula" that suck everyone into: a survival game in a fully destructible world.

Once you know the potential, its about the human cunning to find the right formula that make the old technology (raster render) impossible to follow.


https://youtu.be/pXZ33YoKu9w?t=82

Try stuff something like this in a modern gpu with raster render without resorting LODs (ie. everything is dynamic and destructible)

User avatar
FarbigeWelt
Donor
Donor
Posts: 856
Joined: Sun Jul 01, 2018 12:07 pm
Location: Switzerland
Contact:

Re: Game engine with realtime path tracing?

Post by FarbigeWelt » Wed Jan 30, 2019 4:21 pm

Eric Haines | October 3, 2018
Fast and Fun: My First Real-Time Ray Tracing Demo
By Eric Haines | October 3, 2018 Tags: Design and Visualization, DXR, Game Development, ray tracing, RTX, RTX 2080 Ti, TITAN V, Turing
Editor’s note: What happens when a veteran graphics programmer with substantial experience in old-school ray tracing (in other words, offline rendering), gets hold of hardware capable of real-time ray tracing?
to be continued here
https://devblogs.nvidia.com/my-first-ray-tracing-demo/
Light and Word designing Creator - www.farbigewelt.ch - aka quantenkristall || #luxcorerender
160.8 | 42.8 (10.7) Gfp | Windows 10 Pro, intel i7 4770K@3.5, 32 GB
2 AMD Radeon RX 5700 XT, 8 GB || Gfp = SFFT Gflops

User avatar
lacilaci
Donor
Donor
Posts: 1616
Joined: Fri May 04, 2018 5:16 am

Re: Game engine with realtime path tracing?

Post by lacilaci » Wed Jan 30, 2019 5:30 pm

alexwbc wrote:
Wed Jan 30, 2019 3:31 pm
The future is all in the hands of those who pioneer a technology.
A voxel based game seemed a weird idea at time until someone didn't find that "magical formula" that suck everyone into: a survival game in a fully destructible world.

Once you know the potential, its about the human cunning to find the right formula that make the old technology (raster render) impossible to follow.


https://youtu.be/pXZ33YoKu9w?t=82

Try stuff something like this in a modern gpu with raster render without resorting LODs (ie. everything is dynamic and destructible)
Brigade is in the works forever, otoy likes to hype things up...

Post Reply