Skip to content

Conversation

FrancescoC-unity
Copy link
Contributor

When filtering is enabled I couldn't see any perceivable difference in having the biquadratic resampling when sampling the vbuffer during the OpaqueAtmosphereScattering pass. On the other hand the difference is much stronger if filtering is off, so the predication of the biquadratic resampling is based on whether the filtering is on or not.

This saves around 0.4ms on PS4 on the template scene.

@github-actions
Copy link

github-actions bot commented Sep 2, 2020

It appears that you made a non-draft PR!
Please convert your PR to draft (button on the right side of the page)
and cancel any jobs that started on Yamato.
See the PR template for more information.
Thank you!


if (_EnableVolumetricFog != 0)
{
bool doBiquadraticReconstruction = _VolumetricFilteringEnabled < 0.5f; // Only if filtering is disabled.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is weird, just compare it with 0. More efficient as well.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could also pass an int.

Copy link
Contributor Author

@FrancescoC-unity FrancescoC-unity Sep 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is actually a leftover of an experimentation I was doing, will change!

@sebastienlagarde sebastienlagarde merged commit 7b2c5b6 into HDRP/staging Sep 24, 2020
@sebastienlagarde sebastienlagarde deleted the HDRP/skip-biquadratic-volumetric-sampling-when-filtered branch September 24, 2020 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants