Author Topic: Issue with Beautify 2 DOF - blurring looks worse due to missing alpha in RT  (Read 68 times)

usrnm111

  • Newbie
  • *
  • Posts: 3
    • View Profile
I was using the alpha version of Beautify 2 (for URP - not sure of the version number I'm afraid) in URP version 7.3.1, Unity 2019.3.7f1. The DOF looked like this. I then upgraded to URP version 7.5.1, Unity 2019.4.14f1, using the Beautify 2 version from the asset store (I didn't upgrade to 10.8 as there were no URP changes) and the DOF looks like this. Did a bit of investigating as to what the differences could be between the two versions and noticed this when comparing the frame debugger for both versions (the left is the newer, non-working version and the right is the old, working version). I'm not going to claim to fully understand this, but it looks like the colour format is different in the final Draw Mesh frame for each version (ignore the resolution difference, that's something else). Additionally, the final frame in the working version has the full blur effect visible in the frame, whereas the final frame in the not-working version doesn't. If I examine the alpha frame in each I can see that the alpha channel in the working version has data (presumably because the colour format being RGBA32 supports alpha) whereas in the non-working version doesn't (as it's B10G11R11). I wanted to ask if this is a bug on your side or something on our end (as we're doing a few things with our own RT's) as unfortunately the result at the moment is that the DOF has had a bit of a visual downgrade...

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6521
    • View Profile
Thanks for the details, I'm checking this.

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6521
    • View Profile
This can happen if the platform doesn't support ARGBHalf render texture (half-precision). In this case, the render textures created for DoF computation defaults to non-floating point which in URP 7.5.x doesn't use the alpha channel for performance reasons on mobile. I'll send you an update which ensures the alpha channel is present in all cases for DoF.


usrnm111

  • Newbie
  • *
  • Posts: 3
    • View Profile
Amazing, thank you for the quick response! Just so I understand, having the additional alpha channel will fix the DOF issue?

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6521
    • View Profile
It should, as the CoC amount is stored in the alpha channel.

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6521
    • View Profile
Hm, looks like this is not the issue as the latest version forces the use of floating point rt.. could you please check that the forward renderer asset has "Depth Texture" enabled? Make sure you select the correct URP asset as you can have a few based on Project Settings / Quality levels.

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6521
    • View Profile
Could you please make a new project and send it to me? (Assuming the new project reproduces the same issue).

usrnm111

  • Newbie
  • *
  • Posts: 3
    • View Profile
Depth texture is enabled on all our URP assets :) I've sent you a small test project as a DM.

Thanks!