Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Precipitation enhancements for P3Dv5?

Featured Replies

I was just wondering if there's any add-ons out there that enhance precipitation (rain, snow, etc.) for P3Dv5?  I've not been able to find any.

I do have PrecipitFX for FSX but it's installed through Orbx Central and I don't know how I could install it manually to P3Dv5 to see if it will work or not.

Thanks

Edited by Zylx

Specs: MSI X470 Gaming Pro Carbon board, Ryzen 5800X CPU, 3600Mhz Corsair RAM, Sapphire Nitro+ RX 6900 XT GPU

Favorite Sims: FSX:SE, P3Dv5.4, X-Plane 11 & 12

On 1/25/2025 at 3:46 PM, Zylx said:

I was just wondering if there's any add-ons out there that enhance precipitation (rain, snow, etc.) for P3Dv5?  I've not been able to find any.

I have a couple of direct shader mods applied.

The edits are in the PrecipParticle.fx shader.

Code:

   // Control how long streaks face and how big they are.
    // TBM 26/03/2023 change the calculated value for a smaller looking rain/snow effect.
    float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale / (2.4 - (cb_uPrecipType * 1.65));
    float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale / (1.0 - (cb_uPrecipType * 0.25));

Complete Function (in spoiler):

Spoiler

void CreateStreakQuadVertices(float3 position, float3 velocity, float3 eyePosition, out float3 outQuadPosition[4], out float3 outQuadNormal, in PrecipMaterialInstanceData precipMaterial)
{
    // Control how long streaks face and how big they are.
    // TBM 26/03/2023 change the calculated value for a smaller looking rain/snow effect.
    float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale / (2.4 - (cb_uPrecipType * 1.65));
    float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale / (1.0 - (cb_uPrecipType * 0.25));

    // Original lines.
    //float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale;
    //float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale;

    velocity = normalize(velocity);
    float3 eyeVector = eyePosition - position;
    float3 eyeOnvelocityPlane = eyePosition - ((dot(eyeVector, velocity)) * velocity);
    float3 projectedeyeVector = eyeOnvelocityPlane - position;
    float3 sideVector = normalize(cross(projectedeyeVector, velocity));

    outQuadPosition[0] = position - (sideVector * 0.5 * width);
    outQuadPosition[1] = outQuadPosition[0] + (sideVector * width);
    outQuadPosition[2] = outQuadPosition[0] - (velocity * height);
    outQuadPosition[3] = outQuadPosition[2] + (sideVector * width);

    outQuadNormal = normalize(projectedeyeVector);
}

 

Easy to apply or reverse given the shaders are just text files.

Cheers

Ryzen 5800X clocked to 4.7 Ghz (SMT off), 32 GB ram, Samsung 1 x 1 TB NVMe 970, 2 x 1 TB SSD 850 Pro raided, Asus Tuf 3080Ti

P3D 4.5.14, Orbx Global, Vector and more, lotsa planes too.

Catch my vids on Oz Sim Pilot, catch my screen pics @ Screenshots and Prepar3D

  • 2 weeks later...
  • Author
On 1/28/2025 at 3:24 PM, Rogen said:

I have a couple of direct shader mods applied.

The edits are in the PrecipParticle.fx shader.

Code:

   // Control how long streaks face and how big they are.
    // TBM 26/03/2023 change the calculated value for a smaller looking rain/snow effect.
    float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale / (2.4 - (cb_uPrecipType * 1.65));
    float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale / (1.0 - (cb_uPrecipType * 0.25));

Complete Function (in spoiler):

  Reveal hidden contents

void CreateStreakQuadVertices(float3 position, float3 velocity, float3 eyePosition, out float3 outQuadPosition[4], out float3 outQuadNormal, in PrecipMaterialInstanceData precipMaterial)
{
    // Control how long streaks face and how big they are.
    // TBM 26/03/2023 change the calculated value for a smaller looking rain/snow effect.
    float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale / (2.4 - (cb_uPrecipType * 1.65));
    float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale / (1.0 - (cb_uPrecipType * 0.25));

    // Original lines.
    //float height = precipMaterial.fQuadSize * precipMaterial.fQuadSizeHeightScale;
    //float width = precipMaterial.fQuadSize * precipMaterial.fQuadSizeWidthScale;

    velocity = normalize(velocity);
    float3 eyeVector = eyePosition - position;
    float3 eyeOnvelocityPlane = eyePosition - ((dot(eyeVector, velocity)) * velocity);
    float3 projectedeyeVector = eyeOnvelocityPlane - position;
    float3 sideVector = normalize(cross(projectedeyeVector, velocity));

    outQuadPosition[0] = position - (sideVector * 0.5 * width);
    outQuadPosition[1] = outQuadPosition[0] + (sideVector * width);
    outQuadPosition[2] = outQuadPosition[0] - (velocity * height);
    outQuadPosition[3] = outQuadPosition[2] + (sideVector * width);

    outQuadNormal = normalize(projectedeyeVector);
}

 

Easy to apply or reverse given the shaders are just text files.

Cheers

Wow, thank you Rogen, for sharing this.  I really appreciate it.  Sorry, for taking long to respond.  I will certainly give this a try and see how it looks.

Specs: MSI X470 Gaming Pro Carbon board, Ryzen 5800X CPU, 3600Mhz Corsair RAM, Sapphire Nitro+ RX 6900 XT GPU

Favorite Sims: FSX:SE, P3Dv5.4, X-Plane 11 & 12

On 2/8/2025 at 6:25 PM, Zylx said:

Wow, thank you Rogen, for sharing this.  I really appreciate it.  Sorry, for taking long to respond.  I will certainly give this a try and see how it looks.

Np.

Cheers

Ryzen 5800X clocked to 4.7 Ghz (SMT off), 32 GB ram, Samsung 1 x 1 TB NVMe 970, 2 x 1 TB SSD 850 Pro raided, Asus Tuf 3080Ti

P3D 4.5.14, Orbx Global, Vector and more, lotsa planes too.

Catch my vids on Oz Sim Pilot, catch my screen pics @ Screenshots and Prepar3D

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.