2 Replies Latest reply on Mar 25, 2009 12:03 PM by yangyi0239

    Does reduction support float4

    yangyi0239

      I write follow code, but  cannot get correct result.

      reduce void sum(float4 a<>, reduce float4 b)
      {
          b += a;
      }

        • Does reduction support float4
          Ceq

          You have a float4 reduction working code example in the following directory:

          BROOKDIR\samples\legacy\tests\reduction

          I think your reduce variable should be a stream too:

          ...,reduce float4 b<> ) ...

            • Does reduction support float4
              yangyi0239

               

              Originally posted by: Ceq You have a float4 reduction working code example in the following directory:

               

              BROOKDIR\samples\legacy\tests\reduction

               

              I think your reduce variable should be a stream too:

               

              ...,reduce float4 b<> ) ...

               

               

              Thanks! I find one bug in my codes. So now the float4 reduction version works perfect.