Battlefield V reflection tech *spawn

Discussion in 'Rendering Technology and APIs' started by DavidGraham, Dec 22, 2018.

  1. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    Yeah, but we may be all wrong. I've heard a rumor NV has an AI that can play one hour of Assassins Creed 8, then an hour of AC9, and then it spits out polished AC10 on a shiny disc. hahaha :)
     
    egoless, Malo and milk like this.
  2. DavidGraham

    Veteran

    Joined:
    Dec 22, 2009
    Messages:
    2,703
    Likes Received:
    2,431
    It is, SSR reflections in the game disappear when off screen. Ray traced one don't. It's a matter of testing the objects in the reflection off and on screen and see if they disappear or not.
     
    egoless, vipa899, BRiT and 2 others like this.
  3. milk

    Veteran Regular

    Joined:
    Jun 6, 2012
    Messages:
    2,858
    Likes Received:
    2,384
    Wait, are Ubi games not created that way already? They sure feel that way.
     
    egoless likes this.
  4. milk

    Veteran Regular

    Joined:
    Jun 6, 2012
    Messages:
    2,858
    Likes Received:
    2,384
    Exactly.

    If they disappear or change fidelity, as that change can also be easily noticed in the DF comparisons as well.
     
  5. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    Yes, but i guess what Shifty Geezer means is: If SSR does find a valid hit point and no real ray needs to be traced, do they count this SSR ray to the 'one ray for 15% of pixels per screen budget' yes or no? And at this point the patch makes BFV less usable as a performance measurement.
    Also, if SSR finds a hit but at long distance, they may decide: The probability we have missed something is high, so still trace an additional real ray, but eventually mix both results by distance to hide hard transitions. It all becomes a bit blurry not knowing such details.
    (Not that any of this would matter for visible results)
     
    milk likes this.
  6. Scott_Arm

    Legend

    Joined:
    Jun 16, 2004
    Messages:
    13,162
    Likes Received:
    3,548
    I can't find the link but I believe in digital foundrys patch analysis they said ssr would not count against the dxr ray budget.
     
    egoless, pharma and DavidGraham like this.
  7. DavidGraham

    Veteran

    Joined:
    Dec 22, 2009
    Messages:
    2,703
    Likes Received:
    2,431
    I believe SSR and RT are not yet complementary, there are no evidence of that in the game. Screen space reflections are permanently screen space, and ray traced ones are permanently ray traced. If they are complementary small foliage wouldn't disappear when off screen. That system is yet to be implemented.

    If anyone has any theory to be tested, then I am open for suggestions, I have the game running on a 2080.
     
    pharma and vipa899 like this.
  8. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    I think they already did it, and the purpose was to increase performance with SSR. Likely they have also removed some foliage from ray tracing to avoid costly any hit shaders, so you see them only with SSR (including the off screen fade out.) But that's just what i would do, i can't find the interview again where they revealed some planned details before the patch.

    Another option would be to trace real rays in any case, look up if the hit point is on screen, and reuse the shading from there instead calculating it again. But then we would not see leaf particles in reflections and no typical SSR artifacts at all.

    I guess it is difficult to find out just by looking at the running game. You know the typical SSR artifacts, but you could draw additional conclusions from reflected specular materials. E.g. there is a plastic ball with a highlight, and in SSR reflection the highlight would be at the same spot, while with accurate RT shading the highlight would at a different and correct position. However this will be noticeable very rarely.
     
    milk likes this.
  9. DavidGraham

    Veteran

    Joined:
    Dec 22, 2009
    Messages:
    2,703
    Likes Received:
    2,431
    I don't think they did honestly, and like I said there are no visual evidence from the game supporting this theory.
    They did that before the patch, small grass and leaves were not reflected at all. After the patch they added reflected grass and leaves through SSR.
     
    vipa899 likes this.
  10. Shifty Geezer

    Shifty Geezer uber-Troll!
    Moderator Legend

    Joined:
    Dec 7, 2004
    Messages:
    40,414
    Likes Received:
    10,784
    Location:
    Under my bridge
    Could you grab some window and polished floor reflections in ultra and low RTX quality, with some movement and then remaining stationary for the temporal reconstruction to catch up? I've seen some screenshots with pretty noisy reflections on a vehicle (tram?) and it was like there's no denoising, while some other screenshots showed clear denoising fuzziness.

    Also it be nice if you could recreate the situation where reflections disappear. In my examples, the guy running across the puddle and the sky reflection under the truck. If there's a position where the reflection jumps under the truck (dark then sky then dark again), does it change if you remain stationary, and does it follow the same patterns of light and dark if you move around your position and view it repeatedly from the same local scattered positions? So, walk slowly towards a truck and see if the sky appears and disappears in reflections in puddles under it, then walk backwards and see if they match up the same, and then forwards again. Rays are bundled in more important areas, so if the sampling in some places is very sparse, I would expect to see sampling issues.
     
  11. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    So what do you think is the reason to add SSR, is it only to add vegetation and particles? Makes little sense to add the full SSR cost just for that, when there is a performance problem to solve. (Likely we get each other wrong here somehow.)

    I've looked up the interview again: (https://www.eurogamer.net/articles/digitalfoundry-2018-battlefield-5-rtx-ray-tracing-analysis)


    "Another optimisation we have in the pipe and that almost made launch was a hybrid ray trace/ray march system. This hybrid ray marcher creates a mip map on the entire depth buffer using a MIN filter. This means that every level takes the closest depth in 2x2 regions and keeps going all the way to the lowest mip map. Because this uses a so-called min filter, you know you can skip an entire region on the screen while traversing.

    With this, ray binning then accelerates the hybrid ray traverser tremendously because rays are fetched from the same pixels down the same mip map thereby having super efficient cache utilisation. If your ray gets stuck behind objects as you find in classic screen-space reflections, this system then promotes the ray to become a ray trace/world space ray and continue from the failure point. We also get quality wins here as decals and grass strands will now be in reflections."


    They say it almost made it into the launch version, so likely it is included in the patch already and finished.
    They do not mention the use of SSR results directly, but indirectly by saying grass and decals are now reflected. ('ray marcher' and 'min depth mip map' makes it clear they really talk about typical SSR here, although its results also help to batch real rays better)
    They also say in case of failure (stuck behind object, but surely off screen too, probably large distance as well) they start a real ray. From that i assume they only start real rays if SSR fails (which is very likely).

    If all this is implemented already, it will not cause any visual evidence other then the artifacts we have discussed already.
    But the screenshots you have posted seems to confirm this too: Looking at the SSR reflected magazine from the 1st person view gun close to the floor, this indicates the wrong SSR reflections has been accepted because the distance to the floor is small so probability of error is low. Then a fade out of SSR reflection as distance increases and the 'correct' 3rd person world pose of the model is shown from real ray tracing. So the area with the SSR reflection does not use or require RT. (Notice the fade out of the magazine here is not caused by missing screen space data - the full gun is visible, so it is more likely caused by too high probability of error.)

    If you could make similar shots with reflections on the gun itself, you would have better proof because those reflections taken from screenspace would be wrong, (like the plastic ball example). But this kind of error would be hard to notice.
     
    Shifty Geezer, Scott_Arm and BRiT like this.
  12. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    Nah - stupid, i forgot the 1st person gun is always fake. So you would need another object like a vase with highlights on reflective floor.
     
    vipa899, pharma and DavidGraham like this.
  13. Voxilla

    Regular

    Joined:
    Jun 23, 2007
    Messages:
    708
    Likes Received:
    279
    How do you guys make those nice sceen shots, of the interesting Rotterdam map ?
    I only can examine that map in multi-player.
    Carefull inspection of renderings are rather annoying, as before you know it someone put some bullets in you.
     
    Scott_Arm likes this.
  14. DavidGraham

    Veteran

    Joined:
    Dec 22, 2009
    Messages:
    2,703
    Likes Received:
    2,431
    Once more I don't they think they implemented that system at all, otherwise SSR for small foliage/decals wouldn't have any current artifacts, yet it still does. It still disappears when off screen or blocked by an object.
    That part is a game design choice, the 1st person model can't be ray traced because it's not a real complete model, it's only hands and legs, so it HAS to be SSR. The 3rd person model is ray traced because it's a complete model.
    Get into an empty multiplayer match.
     
    #74 DavidGraham, Dec 27, 2018
    Last edited: Dec 27, 2018
    vipa899 and pharma like this.
  15. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    But both of those points indicate they did in in they way i assume. What do you think is the point where we disagree? I'm confused because you seem to mean they did not implement an additional SSR system, but at same time you say it has SSR.
    AFAIK ther was no SSR before the patch with DXR.
     
  16. DavidGraham

    Veteran

    Joined:
    Dec 22, 2009
    Messages:
    2,703
    Likes Received:
    2,431
    There are two parts here:
    They use SSR only to render certain objects, while the rest of scene is ray traced.
    They still don't use SSR to complement ray traced reflections, in the way that you describe, meaning SSR is not the default reflection method and RT is the fail safe. The scene is reflected using RT from the get go.
     
    vipa899 likes this.
  17. vipa899

    Regular Newcomer

    Joined:
    Mar 31, 2017
    Messages:
    922
    Likes Received:
    354
    Location:
    Sweden
    This is true, not only for bfv but the whole bf series if i remember correctly.
     
  18. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    This is very unlikely. E.g. if you want SSR only for foliage or soft particles, you can do this only by using an additional stencil or ID buffer to distinguish between foliage and other scene elements, but you have the exact same cost otherwise. SSR just for foliage is expensive as full SSR - you still need to march the zbuffer pyramid over the full scene.
    So they would make the game run slower although people complain about bad RT performance.

    There is no doubt they added SSR to the DXR code path. And from that they already get the ray hit position AND the shading just by reading from screen space. They would be crazy to throw this data away and cast a BVH ray to get the same results (almost). This would not make any sense.

    I may sound degrading DXR as a fallback, but that's not what i intend. (i assume that's where you feel resistant but that's unfounded)
    Notice the error probability based by SSR hit distance. The majority of reflections will be still raytraced - it's just an optimization to save maybe 20-30% of rays (just guessing), plus the remaining rays become shorter by clipping against z pyramid. And it must be worth it, otherwise they would not have used SSR at all which has a cost of one millisecond maybe.

    Here's another source (https://forums.geforce.com/default/...20-series/battlefield-v-dxr-faq-updated-12-4/):

    "While ray tracing can produce much more realistic imagery than rasterization, it is also computationally intensive. We have found that the best approach is hybrid rendering, a combination of ray tracing and rasterization. With this approach, rasterization is used where it is most effective, and ray tracing is used where it provides the most visual benefit vs rasterization, such as rendering reflections, refractions, and shadows.

    The Frostbite engine uses a variety of rendering techniques to create various visual effects. A few techniques including mesh scattering and GPU particles aren’t yet accelerated by the Battlefield V implementation of DXR, but in many situations the visual output of those techniques is present in the framebuffer. So, when rendering Ray Traced reflections, Battlefield V is also sampling the framebuffer (similar to how SSR works), and where necessary blends those samples with the ray traced reflections to ensure that reasonably accurate reflections can be seen most of the time, across all visual effects.

    This helps free up rays, which DICE’s variable-rate ray tracing system uses to enhance quality elsewhere in the scene. Variable-rate ray tracing makes best use of available ray budgets, so this technique doesn’t impact performance in the tests we’ve run. This technique is not a factor in the performance improvements that came with the Chapter 1: Overture update.

    With this technique, you may notice minor artifacts where effects are not present in reflections because they are occluded or outside the frame, but we believe that seeing more correct reflections for on-screen effects makes up for the occasional edge-case."


    sampling the framebuffer (similar to how SSR works)
    really means 'exactly how SSR works, but in case of certain or probable failure, we use awesome RTX for correct results'. The quote agrees with the plans the dev mentioned in the pre patch interview.

     
  19. jlippo

    Veteran Regular

    Joined:
    Oct 7, 2004
    Messages:
    1,299
    Likes Received:
    389
    Location:
    Finland
    Prety sure it's currently as follows. (No hit goes to next level. )
    SSR > RT > cubemap.

    In video it was clear that when SSR misses RT is used and things like decals vanish as they are not properly in reflected world, if RT misses cubemap is used. (Sky etc.)

    This is very close to what most games use with SSR and box cubemaps and 'far' environment map.

    Should give nice savings in shading and ray-budget.
     
  20. JoeJ

    Regular Newcomer

    Joined:
    Apr 1, 2018
    Messages:
    394
    Likes Received:
    475
    Agree about SSR > RT, but cubemaps are used if the material is rough and would require too much rays. (RT has no fails, so cubemaps are not a fallback here in contrast to traditional SSR)
    This is a very disappointing but interesting limitation. Wrong cube map reflections at shallow angles are the worst shading artifact since PBS (missing occlusion causes a rim lighting effect everywhere). So i was very disappointed RTX reflections can't fix that.

    I think the problem is mainly this: Because diffuse materials become reflective only at very shallow angles, we see the artifact mostly at the silhouette of objects. But this also means there are very few neighboring pixels that could be used for denoising, so using 1 ray per pixel + denoising does not work well, and many rays are no option.

    However, for BFV they likely made this decision mainly for performance reasons and they did not even try to address this. Exodus on the other hand seems to use diffuse materials for everything, but they violate PBR and shallow angles do not become reflective at all i guess.
    The latter seems the way to go for now, and it's interesting how the use of 'god sent accurate RT' forces us to violate physics laws we have obeyed before that :)
     
    Scott_Arm likes this.
Loading...

Share This Page

  • About Us

    Beyond3D has been around for over a decade and prides itself on being the best place on the web for in-depth, technically-driven discussion and analysis of 3D graphics hardware. If you love pixels and transistors, you've come to the right place!

    Beyond3D is proudly published by GPU Tools Ltd.
Loading...