Tiddan
Topic Author
Posts: 8
Joined: 05 Mar 2019, 14:12

Problem with aliasing when using HDRP

09 Mar 2021, 19:05

Image

Having some problems with pixelated edges. I'm using Unity 2020.1.12f1 and Noesis 3.0.10.

Left shows my paths viewed in blend.
Middle is in my actual project using HDRP.
Right is in another project (same unity version) without HDRP.

It doesn't matter if I run it in editor or standalone, the problem is the same.

When setting AA to None in the No-HDRP project I get pretty much the same effect btw.

Anders
 
User avatar
jsantos
Site Admin
Posts: 4825
Joined: 20 Jan 2012, 17:18
Contact:

Re: Problem with aliasing when using HDRP

12 Mar 2021, 02:29

Your configuration of HDRP is not using multisampling surfaces so you need to enable PPAA in your view.
 
wbruno
Posts: 4
Joined: 05 Apr 2022, 10:09

Re: Problem with aliasing when using HDRP

05 Apr 2022, 15:46

We have the same problem in our project with anti-aliasing using HDRP, even after enabling PPAA in the Noesis View.

See below :
hdrp_aliasing.png
hdrp_aliasing.png (6.03 KiB) Viewed 1907 times
Note: these icons are built in XAML using tags <Path> and <Geometry>.

What else could cause this problem ?
 
User avatar
jsantos
Site Admin
Posts: 4825
Joined: 20 Jan 2012, 17:18
Contact:

Re: Problem with aliasing when using HDRP

05 Apr 2022, 18:55

Are you sure PPAA is enabled in your Noesis View?
 
wbruno
Posts: 4
Joined: 05 Apr 2022, 10:09

Re: Problem with aliasing when using HDRP

06 Apr 2022, 09:51

I thought it was enabled since "Enable PPAA" is checked in NoesisView properties.
noesisview.jpg
noesisview.jpg (26.4 KiB) Viewed 1890 times
I just traced the code and I notice that _isPPAAEnabled is always false but RenderFlags is set to PPAA.
I can see in the code OnAfterDeserialize :
        // (3.0) PPAA flag is now in view render flags 
        if (_isPPAAEnabled)
        {
            _renderFlags |= RenderFlags.PPAA;
            _isPPAAEnabled = false;
        }
So it seems to be like expected.

When I uncheck the property "Enable PPAA" it has some slight effects on the UI but not on these icons.
 
User avatar
jsantos
Site Admin
Posts: 4825
Joined: 20 Jan 2012, 17:18
Contact:

Re: Problem with aliasing when using HDRP

06 Apr 2022, 09:54

Could you please attach your XAML?
 
wbruno
Posts: 4
Joined: 05 Apr 2022, 10:09

Re: Problem with aliasing when using HDRP

06 Apr 2022, 10:07

Here are some parts of the code that display the green icon into a progress bar :
    <ProgressBar Grid.Column="1" Width="160" Foreground="{StaticResource LightGreenBrush}" Style="{StaticResource ProgressBarTalentZonetyle}" Value="{Binding TalentZone}" Minimum="0" Maximum="5" VerticalAlignment="Center"/>

    (...)
    <Style x:Key="ProgressBarTalentZonetyle" TargetType="ProgressBar">
        <Setter Property="Foreground" Value="{StaticResource YellowBrush}"/>
        <Setter Property="Background" Value="{StaticResource DarkBrush}"/>
        <Setter Property="VerticalAlignment" Value="Center"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ProgressBar">
                    <Viewbox>
                        <Grid>
                            <Border x:Name="PART_Track" Background="{TemplateBinding Background}" Clip="{StaticResource StarsTalentZone}"/>
                            <Border x:Name="PART_Indicator" HorizontalAlignment="Left" Background="{TemplateBinding Foreground}" Clip="{StaticResource StarsTalentZone}"/>
                            <Path Data="{StaticResource StarsTalentZone}" Stretch="Fill" StrokeLineJoin="Round"/>
                        </Grid>
                    </Viewbox>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    (...)
    <Geometry x:Key="StarsTalentZone">
        M1000.000,145.000 L1000.000,174.000
        ZM921.636,174.014 C922.109,173.122 922.573,172.245 923.022,171.399 C933.633,167.590 943.423,161.072 951.247,151.897 C975.133,123.887 971.688,81.902 943.554,58.121 C938.879,54.169 933.815,50.970 928.513,48.509 L928.373,47.345 L936.903,38.395 C941.047,40.703 945.029,43.437 948.785,46.612 C980.078,73.063 983.909,119.762 957.342,150.917 C947.589,162.354 935.092,170.091 921.636,174.014
        ZM922.351,70.046 L899.861,57.515 L876.960,70.245 L882.239,44.887 L862.743,27.327 L888.856,24.300 L899.347,0.604 L910.569,24.204 L936.187,27.004 L917.368,44.732 L922.351,70.046
        ZM872.236,47.777 C866.337,50.322 860.710,53.764 855.555,58.121 C827.421,81.902 823.977,123.887 847.863,151.897 C855.686,161.072 865.476,167.590 876.087,171.399 C876.536,172.245 877.000,173.122 877.474,174.014 C864.018,170.091 851.520,162.354 841.767,150.917 C815.200,119.762 819.031,73.063 850.324,46.612 C854.297,43.254 858.523,40.385 862.925,37.997 L872.236,47.777
        ZM722.538,174.014 C723.011,173.122 723.476,172.245 723.925,171.399 C734.535,167.590 744.326,161.072 752.150,151.897 C776.035,123.887 772.591,81.902 744.456,58.121 C739.781,54.169 734.718,50.970 729.415,48.509 L729.275,47.345 L737.806,38.395 C741.949,40.703 745.932,43.437 749.687,46.612 C780.981,73.063 784.811,119.762 758.244,150.917 C748.492,162.354 735.994,170.091 722.538,174.014 ZM723.253,70.046 L700.763,57.515 L677.862,70.245 L683.141,44.887 L663.645,27.327 L689.759,24.300 L700.249,0.604 L711.471,24.204 L737.089,27.004 L718.270,44.732 L723.253,70.046
        ZM673.138,47.777 C667.239,50.322 661.613,53.764 656.457,58.121 C628.323,81.902 624.879,123.887 648.765,151.897 C656.588,161.072 666.379,167.590 676.989,171.399 C677.438,172.245 677.902,173.122 678.376,174.014 C664.920,170.091 652.422,162.354 642.670,150.917 C616.103,119.762 619.933,73.063 651.226,46.612 C655.199,43.254 659.425,40.385 663.828,37.997 L673.138,47.777
        ZM520.440,174.014 C520.914,173.122 521.378,172.245 521.827,171.399 C532.438,167.590 542.228,161.072 550.052,151.897 C573.938,123.887 570.493,81.902 542.359,58.121 C537.683,54.169 532.620,50.970 527.317,48.509 L527.177,47.345 L535.708,38.395 C539.851,40.703 543.834,43.437 547.590,46.612 C578.883,73.063 582.714,119.762 556.147,150.917 C546.394,162.354 533.896,170.091 520.440,174.014
        ZM521.155,70.046 L498.665,57.515 L475.764,70.245 L481.043,44.887 L461.547,27.327 L487.661,24.300 L498.151,0.604 L509.373,24.204 L534.991,27.004 L516.172,44.732 L521.155,70.046
        ZM471.040,47.777 C465.142,50.322 459.515,53.764 454.360,58.121 C426.226,81.902 422.782,123.887 446.667,151.897 C454.491,161.072 464.281,167.590 474.892,171.399 C475.341,172.245 475.805,173.122 476.278,174.014 C462.822,170.091 450.325,162.354 440.572,150.917 C414.005,119.762 417.836,73.063 449.129,46.612 C453.102,43.254 457.327,40.385 461.730,37.997 L471.040,47.777
        ZM322.553,174.014 C323.026,173.122 323.490,172.245 323.940,171.399 C334.550,167.590 344.341,161.072 352.165,151.897 C376.050,123.887 372.606,81.902 344.471,58.121 C339.796,54.169 334.732,50.970 329.430,48.509 L329.290,47.345 L337.820,38.395 C341.964,40.703 345.946,43.437 349.702,46.612 C380.996,73.063 384.826,119.762 358.259,150.917 C348.506,162.354 336.009,170.091 322.553,174.014
        ZM323.268,70.046 L300.778,57.515 L277.877,70.245 L283.156,44.887 L263.660,27.327 L289.774,24.300 L300.264,0.604 L311.486,24.204 L337.104,27.004 L318.285,44.732 L323.268,70.046
        ZM273.153,47.777 C267.254,50.322 261.627,53.764 256.472,58.121 C228.338,81.902 224.894,123.887 248.780,151.897 C256.603,161.072 266.394,167.590 277.004,171.399 C277.453,172.245 277.917,173.122 278.391,174.014 C264.935,170.091 252.437,162.354 242.685,150.917 C216.118,119.762 219.948,73.063 251.241,46.612 C255.214,43.254 259.440,40.385 263.842,37.997 L273.153,47.777
        ZM122.525,174.014 C122.999,173.122 123.463,172.245 123.912,171.399 C134.523,167.590 144.313,161.072 152.137,151.897 C176.023,123.887 172.578,81.902 144.444,58.121 C139.768,54.169 134.705,50.970 129.402,48.509 L129.262,47.345 L137.793,38.395 C141.936,40.703 145.919,43.437 149.675,46.612 C180.968,73.063 184.799,119.762 158.232,150.917 C148.479,162.354 135.981,170.091 122.525,174.014
        ZM123.240,70.046 L100.750,57.515 L77.849,70.245 L83.128,44.887 L63.632,27.327 L89.746,24.300 L100.236,0.604 L111.458,24.204 L137.076,27.004 L118.257,44.732 L123.240,70.046
        ZM73.125,47.777 C67.227,50.322 61.600,53.764 56.445,58.121 C28.311,81.902 24.867,123.887 48.752,151.897 C56.576,161.072 66.366,167.590 76.977,171.399 C77.426,172.245 77.890,173.122 78.363,174.014 C64.907,170.091 52.410,162.354 42.657,150.917 C16.090,119.762 19.921,73.063 51.214,46.612 C55.187,43.254 59.412,40.385 63.815,37.997 L73.125,47.777
        ZM-0.000,174.000 L-0.000,145.000
        ZM43.898,92.983 C48.389,76.820 59.292,64.140 73.111,56.907 L67.435,85.302 L101.282,68.203 L133.611,83.453 L130.615,58.576 C152.574,71.741 163.991,98.288 156.822,124.088 C148.195,155.134 115.922,173.339 84.739,164.750 C53.556,156.160 35.270,124.029 43.898,92.983
        ZM243.925,92.983 C248.417,76.820 259.319,64.140 273.139,56.907 L267.463,85.302 L301.310,68.203 L333.639,83.453 L330.643,58.576 C352.601,71.741 364.019,98.288 356.849,124.088 C348.222,155.134 315.950,173.339 284.766,164.750 C253.583,156.160 235.298,124.029 243.925,92.983
        ZM441.812,92.983 C446.304,76.820 457.207,64.140 471.026,56.907 L465.350,85.302 L499.197,68.203 L531.526,83.453 L528.530,58.576 C550.489,71.741 561.906,98.288 554.737,124.088 C546.110,155.134 513.837,173.339 482.654,164.750 C451.471,156.160 433.185,124.029 441.812,92.983
        ZM643.910,92.983 C648.402,76.820 659.305,64.140 673.124,56.907 L667.448,85.302 L701.295,68.203 L733.624,83.453 L730.628,58.576 C752.586,71.741 764.004,98.288 756.834,124.088 C748.207,155.134 715.935,173.339 684.751,164.750 C653.568,156.160 635.283,124.029 643.910,92.983
        ZM843.008,92.983 C847.500,76.820 858.402,64.140 872.222,56.907 L866.546,85.302 L900.393,68.203 L932.722,83.453 L929.726,58.576 C951.684,71.741 963.102,98.288 955.932,124.088 C947.305,155.134 915.032,173.339 883.849,164.750 C852.666,156.160 834.381,124.029 843.008,92.983 Z
    </Geometry>
	
 
wbruno
Posts: 4
Joined: 05 Apr 2022, 10:09

Re: Problem with aliasing when using HDRP

06 Apr 2022, 10:13

By the way, this problem seems to happen often with progressbars

Who is online

Users browsing this forum: No registered users and 16 guests