//DMC5 vignette.
//
// Generated by Microsoft (R) HLSL Shader Compiler 10.1
//
//   using 3Dmigoto v1.3.15 on Fri Mar 08 23:57:43 2019
//
//
// Buffer Definitions:
//
// cbuffer SceneInfo
// {
//
//   row_major float4x4 viewProjMat;    // Offset:    0 Size:    64 [unused]
//   row_major float3x4 transposeViewMat;// Offset:   64 Size:    48 [unused]
//   row_major float3x4 transposeViewInvMat;// Offset:  112 Size:    48 [unused]
//   float4 projElement[2];             // Offset:  160 Size:    32 [unused]
//   float4 projInvElements[2];         // Offset:  192 Size:    32 [unused]
//   row_major float4x4 viewProjInvMat; // Offset:  224 Size:    64 [unused]
//   row_major float4x4 prevViewProjMat;// Offset:  288 Size:    64 [unused]
//   float3 ZToLinear;                  // Offset:  352 Size:    12 [unused]
//   float subdivisionLevel;            // Offset:  364 Size:     4 [unused]
//   float2 screenSize;                 // Offset:  368 Size:     8
//   float2 screenInverseSize;          // Offset:  376 Size:     8
//   float2 cullingHelper;              // Offset:  384 Size:     8 [unused]
//   float cameraNearPlane;             // Offset:  392 Size:     4 [unused]
//   float cameraFarPlane;              // Offset:  396 Size:     4 [unused]
//   float4 viewFrustum[6];             // Offset:  400 Size:    96 [unused]
//   float4 clipplane;                  // Offset:  496 Size:    16 [unused]
//
// }
//
// cbuffer Tonemap
// {
//
//   float exposureAdjustment;          // Offset:    0 Size:     4 [unused]
//   float tonemapRange;                // Offset:    4 Size:     4
//   float sharpness;                   // Offset:    8 Size:     4 [unused]
//   float preTonemapRange;             // Offset:   12 Size:     4 [unused]
//   int useAutoExposure;               // Offset:   16 Size:     4 [unused]
//   float echoBlend;                   // Offset:   20 Size:     4 [unused]
//   float AABlend;                     // Offset:   24 Size:     4 [unused]
//   float AASubPixel;                  // Offset:   28 Size:     4 [unused]
//   float ResponsiveAARate;            // Offset:   32 Size:     4 [unused]
//
// }
//
// cbuffer CameraKerare
// {
//
//   float kerare_scale;                // Offset:    0 Size:     4
//   float kerare_offset;               // Offset:    4 Size:     4
//
// }
//
// cbuffer LensDistortionParam
// {
//
//   float fDistortionCoef;             // Offset:    0 Size:     4
//   float fRefraction;                 // Offset:    4 Size:     4
//   uint aberrationEnable;             // Offset:    8 Size:     4
//   uint reserved;                     // Offset:   12 Size:     4 [unused]
//
// }
//
// cbuffer RadialBlurRenderParam
// {
//
//   float4 cbRadialColor;              // Offset:    0 Size:    16
//   float2 cbRadialScreenPos;          // Offset:   16 Size:     8
//   float2 cbRadialMaskSmoothstep;     // Offset:   24 Size:     8
//   float2 cbRadialMaskRate;           // Offset:   32 Size:     8
//   float cbRadialBlurPower;           // Offset:   40 Size:     4
//   float cbRadialSharpRange;          // Offset:   44 Size:     4
//   uint cbRadialBlurFlags;            // Offset:   48 Size:     4
//   float cbRadialReserve0;            // Offset:   52 Size:     4 [unused]
//   float cbRadialReserve1;            // Offset:   56 Size:     4 [unused]
//   float cbRadialReserve2;            // Offset:   60 Size:     4 [unused]
//
// }
//
// cbuffer FilmGrainParam
// {
//
//   float2 fNoisePower;                // Offset:    0 Size:     8
//   float2 fNoiseUVOffset;             // Offset:    8 Size:     8
//   float fNoiseDensity;               // Offset:   16 Size:     4
//   float fNoiseContrast;              // Offset:   20 Size:     4
//   float fBlendRate;                  // Offset:   24 Size:     4
//   float fReverseNoiseSize;           // Offset:   28 Size:     4
//
// }
//
// cbuffer ColorCorrectTexture
// {
//
//   float fTextureSize;                // Offset:    0 Size:     4 [unused]
//   float fTextureBlendRate;           // Offset:    4 Size:     4
//   float fTextureBlendRate2;          // Offset:    8 Size:     4
//   float fTextureInverseSize;         // Offset:   12 Size:     4
//   row_major float4x4 fColorMatrix;   // Offset:   16 Size:    64
//
// }
//
// cbuffer ColorDeficientTable
// {
//
//   float4 cvdR;                       // Offset:    0 Size:    16
//   float4 cvdG;                       // Offset:   16 Size:    16
//   float4 cvdB;                       // Offset:   32 Size:    16
//
// }
//
// cbuffer ImagePlaneParam
// {
//
//   float4 ColorParam;                 // Offset:    0 Size:    16
//   float Levels_Rate;                 // Offset:   16 Size:     4
//   float Levels_Range;                // Offset:   20 Size:     4
//   uint Blend_Type;                   // Offset:   24 Size:     4 [unused]
//
// }
//
// cbuffer CBControl
// {
//
//   uint cPassEnabled;                 // Offset:    0 Size:     4
//
// }
//
// Resource bind info for ComputeResultSRV
// {
//
//   struct RadialBlurComputeResult
//   {
//
//       float computeAlpha;            // Offset:    0
//
//   } $Element;                        // Offset:    0 Size:     4
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// BilinearClamp                     sampler      NA          NA    0        1
// TrilinearClamp                    sampler      NA          NA    1        1
// SourceImage                       texture  float4          2d    0        1
// ComputeResultSRV                  texture  struct         r/o    1        1
// tTextureMap0                      texture  float4          3d    2        1
// tTextureMap1                      texture  float4          3d    3        1
// tTextureMap2                      texture  float4          3d    4        1
// ImagePlameBase                    texture  float4          2d    5        1
// ImagePlameAlpha                   texture   float          2d    6        1
// SceneInfo                         cbuffer      NA          NA    0        1
// Tonemap                           cbuffer      NA          NA    1        1
// CameraKerare                      cbuffer      NA          NA    2        1
// LensDistortionParam               cbuffer      NA          NA    3        1
// RadialBlurRenderParam             cbuffer      NA          NA    4        1
// FilmGrainParam                    cbuffer      NA          NA    5        1
// ColorCorrectTexture               cbuffer      NA          NA    6        1
// ColorDeficientTable               cbuffer      NA          NA    7        1
// ImagePlaneParam                   cbuffer      NA          NA    8        1
// CBControl                         cbuffer      NA          NA    9        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Position              0   xyzw        0      POS   float   xy
// Kerare                   0   xyzw        1     NONE   float   xyzw
// Exposure                 0   x           2     NONE   float   x
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb0[24], immediateIndexed
dcl_constantbuffer cb1[1], immediateIndexed
dcl_constantbuffer cb2[1], immediateIndexed
dcl_constantbuffer cb3[1], immediateIndexed
dcl_constantbuffer cb4[4], immediateIndexed
dcl_constantbuffer cb5[2], immediateIndexed
dcl_constantbuffer cb6[5], immediateIndexed
dcl_constantbuffer cb7[3], immediateIndexed
dcl_constantbuffer cb8[2], immediateIndexed
dcl_constantbuffer cb9[1], immediateIndexed
dcl_sampler s0, mode_default
dcl_sampler s1, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_structured t1, 4
dcl_resource_texture3d (float,float,float,float) t2
dcl_resource_texture3d (float,float,float,float) t3
dcl_resource_texture3d (float,float,float,float) t4
dcl_resource_texture2d (float,float,float,float) t5
dcl_resource_texture2d (float,float,float,float) t6
dcl_input_ps_siv linear noperspective v0.xy, position
dcl_input_ps linear v1.xyzw
dcl_input_ps linear v2.x
dcl_output o0.xyzw
//dcl_temps 10
dcl_temps 30

dcl_resource_texture1d (float,float,float,float) t120
ld_indexable(texture1d)(float,float,float,float) r20.xyzw, l(10, 0, 0, 0), t120.xyzw
ld_indexable(texture1d)(float,float,float,float) r22.xyzw, l(11, 0, 0, 0), t120.xyzw

//Barrel distortion comparison.
ieq r23.x, r22.y, l(1.000000)

//Vignette comparison.
ieq r21.x, r20.w, l(0.000000)

//Radial blur comparison.
ieq r21.y, r22.w, l(1.000000)

and r0.xyzw, cb9[0].xxxx, l(1, 32, 2, 4)
if_nz r0.x
  mad r1.xy, v0.xyxx, cb0[23].zwzz, l(-0.500000, -0.500000, 0.000000, 0.000000)
  
  //Barrel distortion.
  if_nz r23.x
  mad r1.z, cb3[0].x, l(0.500000), l(1.000000)
  else
  mad r1.z, cb3[0].x, l(0.000000), l(1.000000)
  endif
  
  max r1.z, r1.z, l(1.000000)
  rcp r1.z, r1.z
  dp2 r1.w, r1.xyxx, r1.xyxx
  
  //Barrel distortion.
  if_nz r23.x
  mad r2.x, cb3[0].x, r1.w, l(1.000000)
  else
  mad r2.x, cb3[0].x, l(0.000000), l(1.000000)
  endif
  
  mul r2.xy, r1.xyxx, r2.xxxx
  mad r2.xy, r2.xyxx, r1.zzzz, l(0.500000, 0.500000, 0.000000, 0.000000)
  if_z cb3[0].z
    sample_indexable(texture2d)(float,float,float,float) r3.xyz, r2.xyxx, t0.xyzw, s0
    mul r3.xyz, r3.xyzx, v2.xxxx
    max r2.z, r3.y, r3.x
    max r2.z, r3.z, r2.z
    and r2.w, r2.z, l(0x7f800000)
    ieq r2.w, r2.w, l(0x7f800000)
    if_nz r2.w
      mov r4.xyz, l(1.000000,1.000000,1.000000,0)
    endif
    if_z r2.w
      mad r2.z, r2.z, cb1[0].y, l(1.000000)
      div r4.xyz, r3.xyzx, r2.zzzz
    endif
    mov_sat r4.xyz, r4.xyzx
  else
    add r1.w, r1.w, cb3[0].y
    mad r2.z, cb3[0].x, r1.w, l(1.000000)
    mul r2.zw, r1.xxxy, r2.zzzz
    mad r2.zw, r2.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
    add r1.w, r1.w, cb3[0].y
    mad r1.w, cb3[0].x, r1.w, l(1.000000)
    mul r1.xy, r1.wwww, r1.xyxx
    mad r1.xy, r1.xyxx, r1.zzzz, l(0.500000, 0.500000, 0.000000, 0.000000)
    sample_indexable(texture2d)(float,float,float,float) r3.xyz, r2.xyxx, t0.xyzw, s0
    mul r3.xyz, r3.xyzx, v2.xxxx
    max r1.w, r3.y, r3.x
    max r1.w, r3.z, r1.w
    and r2.x, r1.w, l(0x7f800000)
    ieq r2.x, r2.x, l(0x7f800000)
    if_nz r2.x
      mov r4.x, l(1.000000)
    endif
    if_z r2.x
      mad r1.w, r1.w, cb1[0].y, l(1.000000)
      div r4.x, r3.x, r1.w
    endif
    sample_indexable(texture2d)(float,float,float,float) r2.xyz, r2.zwzz, t0.xyzw, s0
    mul r2.xyz, r2.xyzx, v2.xxxx
    max r1.w, r2.y, r2.x
    max r1.w, r2.z, r1.w
    and r2.x, r1.w, l(0x7f800000)
    ieq r2.x, r2.x, l(0x7f800000)
    if_nz r2.x
      mov r4.y, l(1.000000)
    endif
    if_z r2.x
      mad r1.w, r1.w, cb1[0].y, l(1.000000)
      div r4.y, r2.y, r1.w
    endif
    sample_indexable(texture2d)(float,float,float,float) r1.xyw, r1.xyxx, t0.xywz, s0
    mul r1.xyw, r1.xyxw, v2.xxxx
    max r1.x, r1.y, r1.x
    max r1.x, r1.w, r1.x
    and r1.y, r1.x, l(0x7f800000)
    ieq r1.y, r1.y, l(0x7f800000)
    if_nz r1.y
      mov r4.z, l(1.000000)
    endif
    if_z r1.y
      mad r1.x, r1.x, cb1[0].y, l(1.000000)
      div r4.z, r1.w, r1.x
    endif
    mov_sat r4.xyz, r4.xyzx
  endif
  mov r1.x, cb3[0].x
else
  ftou r2.xy, v0.xyxx
  mov r2.zw, l(0,0,0,0)
  ld_indexable(texture2d)(float,float,float,float) r2.xyz, r2.xyzw, t0.xyzw
  mul r2.xyz, r2.xyzx, v2.xxxx
  max r1.y, r2.y, r2.x
  max r1.y, r2.z, r1.y
  and r1.w, r1.y, l(0x7f800000)
  ieq r1.w, r1.w, l(0x7f800000)
  if_nz r1.w
    mov r4.xyz, l(1.000000,1.000000,1.000000,0)
  endif
  if_z r1.w
    mad r1.y, r1.y, cb1[0].y, l(1.000000)
    div r4.xyz, r2.xyzx, r1.yyyy
  endif
  mov_sat r4.xyz, r4.xyzx
  mov r1.xz, l(0,0,1.000000,0)
endif
if_nz r0.y
  and r0.y, cb4[3].x, l(2)
  movc r1.yw, r0.yyyy, l(0,1.000000,0,0), l(0,0,0,1.000000)
  ld_structured_indexable(structured_buffer, stride=4)(mixed,mixed,mixed,mixed) r0.y, l(0), l(0), t1.xxxx
  mad r0.y, r0.y, r1.y, r1.w
  mul r0.y, r0.y, cb4[0].w
  eq r1.y, r0.y, l(0.000000)
  if_nz r1.y
    mov r2.xyz, r4.xyzx
  endif
  if_z r1.y
    movc r0.x, r0.x, l(1), l(0)
    mul r1.yw, v0.xxxy, cb0[23].zzzw
    mad r3.xy, v0.xyxx, cb0[23].zwzz, l(-0.500000, -0.500000, 0.000000, 0.000000)
    add r3.xy, r3.xyxx, -cb4[1].xyxx
	
	//Radial blur. Included in vignette toggle.
    if_nz r21.y
    mul r3.xy, r3.xy, l(0.0)
    endif
	
    lt r3.zw, r3.xxxy, l(0.000000, 0.000000, 0.000000, 0.000000)
    mad r5.xy, -v0.xyxx, cb0[23].zwzz, l(1.000000, 1.000000, 0.000000, 0.000000)
	
	//Radial blur. Included in vignette toggle.
	//if_nz r21.y
	//mul r5.xy, r5.xy, l(0.0)
	//endif
	
    movc r1.yw, r3.zzzw, r5.xxxy, r1.yyyw
    and r2.w, cb4[3].x, l(1)
    dp2 r3.z, r3.xyxx, r3.xyxx
    rsq r3.w, r3.z
    mul r5.xy, r3.wwww, r3.xyxx
    mul r5.xy, r5.xyxx, cb4[2].wwww
    ftou r5.xy, |r5.xyxx|
    iadd r3.w, r5.y, r5.x
    xor r4.w, r3.w, l(61)
    ushr r3.w, r3.w, l(16)
    xor r3.w, r3.w, r4.w
    imul null, r3.w, r3.w, l(9)
    ushr r4.w, r3.w, l(4)
    xor r3.w, r3.w, r4.w
    imul null, r3.w, r3.w, l(0x27d4eb2d)
    ushr r4.w, r3.w, l(15)
    xor r3.w, r3.w, r4.w
    utof r3.w, r3.w
    mul r3.w, r3.w, l(2.328306437E-010)
    movc r2.w, r2.w, r3.w, l(1.000000)
    if_nz r0.x
      sqrt r0.x, r3.z
      max r0.x, r0.x, l(1.000000)
      div r0.x, l(1.000000, 1.000000, 1.000000, 1.000000), r0.x
      mul r5.xy, r1.ywyy, -cb4[2].zzzz
      mul r5.xy, r0.xxxx, r5.xyxx
      mul r5.xy, r2.wwww, r5.xyxx
	  
	  
      mad r6.xyzw, r5.xyxy, l(0.00111111114, 0.00111111114, 0.010000, 0.010000), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r6.xyzw, r3.xyxy, r6.xyzw, cb4[1].xyxy
      dp2 r0.x, r6.xyxx, r6.xyxx
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r6.xxxy
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r7.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r8.xyzw, r5.xyxy, l(0.00222222228, 0.00222222228, 0.00333333341, 0.00333333341), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      dp2 r0.x, r8.xyxx, r8.xyxx
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.xxxy
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mul r9.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000)
      mad r7.xyz, r7.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r9.xyzx
      dp2 r0.x, r8.zwzz, r8.zwzz
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.zzzw
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r8.xyzw, r5.xyxy, l(0.00444444455, 0.00444444455, 0.00555555569, 0.00555555569), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      dp2 r0.x, r8.xyxx, r8.xyxx
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.xxxy
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      dp2 r0.x, r8.zwzz, r8.zwzz
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.zzzw
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r8.xyzw, r5.xyxy, l(0.00666666683, 0.00666666683, 0.00777777797, 0.00777777797), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      dp2 r0.x, r8.xyxx, r8.xyxx
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.xxxy
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      dp2 r0.x, r8.zwzz, r8.zwzz
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.zw, r0.xxxx, r8.zzzw
      mad r5.zw, r5.zzzw, r1.zzzz, l(0.000000, 0.000000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r5.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r5.xy, r5.xyxx, l(0.00888888910, 0.00888888910, 0.000000, 0.000000), l(1.000000, 1.000000, 0.000000, 0.000000)
      mad r5.xy, r3.xyxx, r5.xyxx, cb4[1].xyxx
      dp2 r0.x, r5.xyxx, r5.xyxx
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r5.xy, r0.xxxx, r5.xyxx
      mad r5.xy, r5.xyxx, r1.zzzz, l(0.500000, 0.500000, 0.000000, 0.000000)
      sample_l_indexable(texture2d)(float,float,float,float) r5.xyz, r5.xyxx, t0.xyzw, s0, l(0.000000)
      mad r5.xyz, r5.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      dp2 r0.x, r6.zwzz, r6.zwzz
      mad r0.x, r1.x, r0.x, l(1.000000)
      mul r6.xy, r0.xxxx, r6.zwzz
      mad r1.xz, r6.xxyx, r1.zzzz, l(0.500000, 0.000000, 0.500000, 0.000000)
      sample_l_indexable(texture2d)(float,float,float,float) r6.xyz, r1.xzxx, t0.xyzw, s0, l(0.000000)
      mad r5.xyz, r6.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r5.xyzx
      mul r5.xyz, r5.xyzx, cb4[0].xyzx
      mul r5.xyz, r5.xyzx, v2.xxxx
      max r0.x, r5.y, r5.x
      max r0.x, r5.z, r0.x
      and r1.x, r0.x, l(0x7f800000)
      ieq r1.x, r1.x, l(0x7f800000)
      if_nz r1.x
        mov r6.xyz, l(1.000000,1.000000,1.000000,0)
      endif
      if_z r1.x
        mad r0.x, r0.x, cb1[0].y, l(1.000000)
        div r6.xyz, r5.xyzx, r0.xxxx
      endif
      mov_sat r6.xyz, r6.xyzx
      mul r5.xyz, r4.xyzx, cb4[0].xyzx
      mad r5.xyz, r5.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r6.xyzx
    else
      sqrt r0.x, r3.z
      max r0.x, r0.x, l(1.000000)
      div r0.x, l(1.000000, 1.000000, 1.000000, 1.000000), r0.x
      mul r1.xy, r1.ywyy, -cb4[2].zzzz
	  
	  
	  
      mul r1.xy, r0.xxxx, r1.xyxx
      mul r1.xy, r2.wwww, r1.xyxx
      mad r6.xyzw, r1.xyxy, l(0.00111111114, 0.00111111114, 0.010000, 0.010000), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r6.xyzw, r3.xyxy, r6.xyzw, cb4[1].xyxy
      add r6.xyzw, r6.xyzw, l(0.500000, 0.500000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r7.xyz, r6.xyxx, t0.xyzw, s0, l(0.000000)
      mad r8.xyzw, r1.xyxy, l(0.00222222228, 0.00222222228, 0.00333333341, 0.00333333341), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      add r8.xyzw, r8.xyzw, l(0.500000, 0.500000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r8.xyxx, t0.xyzw, s0, l(0.000000)
      mul r9.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000)
      mad r7.xyz, r7.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r9.xyzx
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r8.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r8.xyzw, r1.xyxy, l(0.00444444455, 0.00444444455, 0.00555555569, 0.00555555569), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      add r8.xyzw, r8.xyzw, l(0.500000, 0.500000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r8.xyxx, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r8.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r8.xyzw, r1.xyxy, l(0.00666666683, 0.00666666683, 0.00777777797, 0.00777777797), l(1.000000, 1.000000, 1.000000, 1.000000)
      mad r8.xyzw, r3.xyxy, r8.xyzw, cb4[1].xyxy
      add r8.xyzw, r8.xyzw, l(0.500000, 0.500000, 0.500000, 0.500000)
      sample_l_indexable(texture2d)(float,float,float,float) r9.xyz, r8.xyxx, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r9.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      sample_l_indexable(texture2d)(float,float,float,float) r8.xyz, r8.zwzz, t0.xyzw, s0, l(0.000000)
      mad r7.xyz, r8.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      mad r1.xy, r1.xyxx, l(0.00888888910, 0.00888888910, 0.000000, 0.000000), l(1.000000, 1.000000, 0.000000, 0.000000)
      mad r1.xy, r3.xyxx, r1.xyxx, cb4[1].xyxx
      add r1.xy, r1.xyxx, l(0.500000, 0.500000, 0.000000, 0.000000)
      sample_l_indexable(texture2d)(float,float,float,float) r1.xyz, r1.xyxx, t0.xyzw, s0, l(0.000000)
      mad r1.xyz, r1.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r7.xyzx
      sample_l_indexable(texture2d)(float,float,float,float) r3.xyw, r6.zwzz, t0.xywz, s0, l(0.000000)
      mad r1.xyz, r3.xywx, l(0.100000, 0.100000, 0.100000, 0.000000), r1.xyzx
      mul r1.xyz, r1.xyzx, cb4[0].xyzx
      mul r1.xyz, r1.xyzx, v2.xxxx
      max r0.x, r1.y, r1.x
      max r0.x, r1.z, r0.x
      and r1.w, r0.x, l(0x7f800000)
      ieq r1.w, r1.w, l(0x7f800000)
      if_nz r1.w
        mov r3.xyw, l(1.000000,1.000000,0,1.000000)
      endif
      if_z r1.w
        mad r0.x, r0.x, cb1[0].y, l(1.000000)
        div r3.xyw, r1.xyxz, r0.xxxx
      endif
      mov_sat r3.xyw, r3.xyxw
      mul r1.xyz, r4.xyzx, cb4[0].xyzx
      mad r5.xyz, r1.xyzx, l(0.100000, 0.100000, 0.100000, 0.000000), r3.xywx
    endif
    lt r0.x, l(0.000000), cb4[2].x
    if_nz r0.x
      sqrt r0.x, r3.z
      mad_sat r0.x, r0.x, cb4[1].z, cb4[1].w
      mul r1.x, r0.x, r0.x
      mad r0.x, -r0.x, l(2.000000), l(3.000000)
      mul r0.x, r0.x, r1.x
      mad r0.x, cb4[2].x, r0.x, cb4[2].y
      add r1.xyz, -r4.xyzx, r5.xyzx
      mad r5.xyz, r0.xxxx, r1.xyzx, r4.xyzx
    endif
    add r1.xyz, -r4.xyzx, r5.xyzx
    mad r4.xyz, r0.yyyy, r1.xyzx, r4.xyzx
  else
    mov r4.xyz, r2.xyzx
  endif
endif
div r1.xyz, v1.xyzx, v1.wwww
dp3 r0.x, r1.xyzx, r1.xyzx
rsq r0.x, r0.x
mul r0.x, r0.x, r1.z
mad_sat r0.y, |r0.x|, cb2[0].x, cb2[0].y

// Vignette ORIGINAL LINE is l(1.000000)
if_nz r21.x
	add r0.y, -r0.y, l(100.000000)
else
	add r0.y, -r0.y, l(1.000000)
endif

mul r0.x, |r0.x|, |r0.x|
mul r0.x, r0.x, r0.x
mul r0.x, r0.y, r0.x
min r0.x, r0.x, l(1.000000)
mul r1.xyz, r0.xxxx, r4.xyzx
if_nz r0.z
  mad r0.yz, cb5[0].zzwz, cb0[23].xxyx, v0.xxyx
  mul r0.yz, r0.yyzy, cb5[1].wwww
  round_ni r0.yz, r0.yyzy
  dp2 r1.w, r0.yzyy, l(0.0671105608, 0.00583714992, 0.000000, 0.000000)
  frc r1.w, r1.w
  mul r1.w, r1.w, l(52.982918)
  frc r1.w, r1.w
  lt r2.x, r1.w, cb5[1].x
  if_nz r2.x
    mul r0.y, r0.z, r0.y
    ftou r0.y, r0.y
    xor r0.y, r0.y, l(0x00bc602f)
    imul null, r0.y, r0.y, l(0x003779b9)
    ishl r0.z, r0.y, l(6)
    ushr r2.x, r0.y, l(26)
    xor r0.y, r0.y, r0.z
    xor r0.y, r0.y, r2.x
    utof r0.y, r0.y
    mul r0.y, r0.y, l(2.328306437E-010)
  else
    mov r0.y, l(0)
  endif
  mul r0.z, r1.w, l(757.484680)
  frc r0.z, r0.z
  lt r1.w, r0.z, cb5[1].x
  if_nz r1.w
    xor r1.w, r0.z, l(0x00bc602f)
    imul null, r1.w, r1.w, l(0x003779b9)
    ishl r2.x, r1.w, l(6)
    ushr r2.y, r1.w, l(26)
    xor r1.w, r1.w, r2.x
    xor r1.w, r1.w, r2.y
    utof r1.w, r1.w
    mad r1.w, r1.w, l(2.328306437E-010), l(-0.500000)
  else
    mov r1.w, l(0)
  endif
  mul r0.z, r0.z, l(757.484680)
  frc r0.z, r0.z
  lt r2.x, r0.z, cb5[1].x
  if_nz r2.x
    xor r0.z, r0.z, l(0x00bc602f)
    imul null, r0.z, r0.z, l(0x003779b9)
    ishl r2.x, r0.z, l(6)
    ushr r2.y, r0.z, l(26)
    xor r0.z, r0.z, r2.x
    xor r0.z, r0.z, r2.y
    utof r0.z, r0.z
    mad r0.z, r0.z, l(2.328306437E-010), l(-0.500000)
  else
    mov r0.z, l(0)
  endif
  mul r2.xy, r0.yzyy, cb5[0].xyxx
  mul r2.z, r1.w, cb5[0].y
  dp2 r3.x, r2.xzxx, l(1.000000, 1.402000, 0.000000, 0.000000)
  dp3 r3.y, r2.xyzx, l(1.000000, -0.344000, -0.714000, 0.000000)
  dp2 r3.z, r2.xyxx, l(1.000000, 1.772000, 0.000000, 0.000000)
  dp3_sat r0.y, r1.xyzx, l(0.299000, -0.169000, 0.500000, 0.000000)
  add r0.y, -r0.y, l(1.000000)
  log r0.y, r0.y
  mul r0.y, r0.y, cb5[1].y
  exp r0.y, r0.y
  mul r0.y, r0.y, cb5[1].z
  mad r2.xyz, -r4.xyzx, r0.xxxx, r3.xyzx
  mad r1.xyz, r0.yyyy, r2.xyzx, r1.xyzx
endif
//Color correction.
if_nz r0.w
  mov_sat r1.xyz, r1.xyzx
  mul r0.x, cb6[0].w, l(0.500000)
  ge r0.yzw, l(0.000000, 0.00313080009, 0.00313080009, 0.00313080009), r1.xxyz
  mul r2.xyz, r1.xyzx, l(12.920000, 12.920000, 12.920000, 0.000000)
  log r3.xyz, r1.xyzx
  mul r3.xyz, r3.xyzx, l(0.416666657, 0.416666657, 0.416666657, 0.000000)
  exp r3.xyz, r3.xyzx
  mad r3.xyz, r3.xyzx, l(1.055000, 1.055000, 1.055000, 0.000000), l(-0.055000, -0.055000, -0.055000, 0.000000)
  movc r0.yzw, r0.yyzw, r2.xxyz, r3.xxyz
  add r1.w, -cb6[0].w, l(1.000000)
  mad r0.xyz, r0.yzwy, r1.wwww, r0.xxxx
  lt r2.xy, l(0.000000, 0.000000, 0.000000, 0.000000), cb6[0].yzyy
  and r0.w, r2.y, r2.x
  if_nz r0.w
    sample_l_indexable(texture3d)(float,float,float,float) r3.xyz, r0.xyzx, t2.xyzw, s1, l(0.000000)
    sample_l_indexable(texture3d)(float,float,float,float) r4.xyz, r0.xyzx, t3.xyzw, s1, l(0.000000)
    add r4.xyz, -r3.xyzx, r4.xyzx
    mad r3.xyz, cb6[0].yyyy, r4.xyzx, r3.xyzx
    ge r4.xyz, l(0.00313080009, 0.00313080009, 0.00313080009, 0.000000), r3.xyzx
    mul r5.xyz, r3.xyzx, l(12.920000, 12.920000, 12.920000, 0.000000)
    log r6.xyz, r3.xyzx
    mul r6.xyz, r6.xyzx, l(0.416666657, 0.416666657, 0.416666657, 0.000000)
    exp r6.xyz, r6.xyzx
    mad r6.xyz, r6.xyzx, l(1.055000, 1.055000, 1.055000, 0.000000), l(-0.055000, -0.055000, -0.055000, 0.000000)
    movc r4.xyz, r4.xyzx, r5.xyzx, r6.xyzx
    sample_l_indexable(texture3d)(float,float,float,float) r4.xyz, r4.xyzx, t4.xyzw, s1, l(0.000000)
    add r4.xyz, -r3.xyzx, r4.xyzx
    mad r3.xyz, cb6[0].zzzz, r4.xyzx, r3.xyzx
  else
    if_nz r2.x
      sample_l_indexable(texture3d)(float,float,float,float) r2.xzw, r0.xyzx, t2.xwyz, s1, l(0.000000)
      sample_l_indexable(texture3d)(float,float,float,float) r4.xyz, r0.xyzx, t3.xyzw, s1, l(0.000000)
      add r4.xyz, -r2.xzwx, r4.xyzx
      mad r3.xyz, cb6[0].yyyy, r4.xyzx, r2.xzwx
    else
      if_nz r2.y
        sample_l_indexable(texture3d)(float,float,float,float) r2.xyz, r0.xyzx, t2.xyzw, s1, l(0.000000)
        ge r4.xyz, l(0.00313080009, 0.00313080009, 0.00313080009, 0.000000), r2.xyzx
        mul r5.xyz, r2.xyzx, l(12.920000, 12.920000, 12.920000, 0.000000)
        log r6.xyz, r2.xyzx
        mul r6.xyz, r6.xyzx, l(0.416666657, 0.416666657, 0.416666657, 0.000000)
        exp r6.xyz, r6.xyzx
        mad r6.xyz, r6.xyzx, l(1.055000, 1.055000, 1.055000, 0.000000), l(-0.055000, -0.055000, -0.055000, 0.000000)
        movc r4.xyz, r4.xyzx, r5.xyzx, r6.xyzx
        sample_l_indexable(texture3d)(float,float,float,float) r4.xyz, r4.xyzx, t4.xyzw, s1, l(0.000000)
        add r4.xyz, -r2.xyzx, r4.xyzx
        mad r3.xyz, cb6[0].zzzz, r4.xyzx, r2.xyzx
      else
        sample_l_indexable(texture3d)(float,float,float,float) r3.xyz, r0.xyzx, t2.xyzw, s1, l(0.000000)
      endif
    endif
  endif
  mul r0.xyz, r3.yyyy, cb6[2].xyzx
  mad r0.xyz, r3.xxxx, cb6[1].xyzx, r0.xyzx
  mad r0.xyz, r3.zzzz, cb6[3].xyzx, r0.xyzx
  add r1.xyz, r0.xyzx, cb6[4].xyzx
endif
and r0.xy, cb9[0].xxxx, l(8, 16, 0, 0)
if_nz r0.x
  dp3_sat r2.x, r1.xyzx, cb7[0].xyzx
  dp3_sat r2.y, r1.xyzx, cb7[1].xyzx
  dp3_sat r2.z, r1.xyzx, cb7[2].xyzx
  mov r1.xyz, r2.xyzx
endif
if_nz r0.y
  mul r0.xy, v0.xyxx, cb0[23].zwzz
  sample_l_indexable(texture2d)(float,float,float,float) r2.xyzw, r0.xyxx, t5.xyzw, s0, l(0.000000)
  mul r3.xyzw, r2.xyzw, cb8[0].xyzw
  sample_l_indexable(texture2d)(float,float,float,float) r0.x, r0.xyxx, t6.xyzw, s0, l(0.000000)
  mad_sat r0.x, r0.x, cb8[1].x, cb8[1].y
  mul r0.x, r3.w, r0.x
  lt r0.yzw, r3.xxyz, l(0.000000, 0.500000, 0.500000, 0.500000)
  mul r3.xyz, r1.xyzx, r3.xyzx
  add r3.xyz, r3.xyzx, r3.xyzx
  mad r2.xyz, -r2.xyzx, cb8[0].xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  add r2.xyz, r2.xyzx, r2.xyzx
  add r4.xyz, -r1.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  mad r2.xyz, -r2.xyzx, r4.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  movc r0.yzw, r0.yyzw, r3.xxyz, r2.xxyz
  add r0.yzw, -r1.xxyz, r0.yyzw
  mad r1.xyz, r0.xxxx, r0.yzwy, r1.xyzx
endif
mov o0.xyz, r1.xyzx
mov o0.w, l(0)
ret
// Approximately 457 instruction slots used

///////////////////////////////// HLSL Code /////////////////////////////////
// // ---- Created with 3Dmigoto v1.3.15 on Fri Mar 08 23:57:43 2019
//
// struct RadialBlurComputeResult
// {
//     float computeAlpha;            // Offset:    0
// };
//
// cbuffer SceneInfo : register(b0)
// {
//   row_major float4x4 viewProjMat : packoffset(c0);
//   row_major float3x4 transposeViewMat : packoffset(c4);
//   row_major float3x4 transposeViewInvMat : packoffset(c7);
//   float4 projElement[2] : packoffset(c10);
//   float4 projInvElements[2] : packoffset(c12);
//   row_major float4x4 viewProjInvMat : packoffset(c14);
//   row_major float4x4 prevViewProjMat : packoffset(c18);
//   float3 ZToLinear : packoffset(c22);
//   float subdivisionLevel : packoffset(c22.w);
//   float2 screenSize : packoffset(c23);
//   float2 screenInverseSize : packoffset(c23.z);
//   float2 cullingHelper : packoffset(c24);
//   float cameraNearPlane : packoffset(c24.z);
//   float cameraFarPlane : packoffset(c24.w);
//   float4 viewFrustum[6] : packoffset(c25);
//   float4 clipplane : packoffset(c31);
// }
//
// cbuffer Tonemap : register(b1)
// {
//   float exposureAdjustment : packoffset(c0);
//   float tonemapRange : packoffset(c0.y);
//   float sharpness : packoffset(c0.z);
//   float preTonemapRange : packoffset(c0.w);
//   int useAutoExposure : packoffset(c1);
//   float echoBlend : packoffset(c1.y);
//   float AABlend : packoffset(c1.z);
//   float AASubPixel : packoffset(c1.w);
//   float ResponsiveAARate : packoffset(c2);
// }
//
// cbuffer CameraKerare : register(b2)
// {
//   float kerare_scale : packoffset(c0);
//   float kerare_offset : packoffset(c0.y);
// }
//
// cbuffer LensDistortionParam : register(b3)
// {
//   float fDistortionCoef : packoffset(c0);
//   float fRefraction : packoffset(c0.y);
//   uint aberrationEnable : packoffset(c0.z);
//   uint reserved : packoffset(c0.w);
// }
//
// cbuffer RadialBlurRenderParam : register(b4)
// {
//   float4 cbRadialColor : packoffset(c0);
//   float2 cbRadialScreenPos : packoffset(c1);
//   float2 cbRadialMaskSmoothstep : packoffset(c1.z);
//   float2 cbRadialMaskRate : packoffset(c2);
//   float cbRadialBlurPower : packoffset(c2.z);
//   float cbRadialSharpRange : packoffset(c2.w);
//   uint cbRadialBlurFlags : packoffset(c3);
//   float cbRadialReserve0 : packoffset(c3.y);
//   float cbRadialReserve1 : packoffset(c3.z);
//   float cbRadialReserve2 : packoffset(c3.w);
// }
//
// cbuffer FilmGrainParam : register(b5)
// {
//   float2 fNoisePower : packoffset(c0);
//   float2 fNoiseUVOffset : packoffset(c0.z);
//   float fNoiseDensity : packoffset(c1);
//   float fNoiseContrast : packoffset(c1.y);
//   float fBlendRate : packoffset(c1.z);
//   float fReverseNoiseSize : packoffset(c1.w);
// }
//
// cbuffer ColorCorrectTexture : register(b6)
// {
//   float fTextureSize : packoffset(c0);
//   float fTextureBlendRate : packoffset(c0.y);
//   float fTextureBlendRate2 : packoffset(c0.z);
//   float fTextureInverseSize : packoffset(c0.w);
//   row_major float4x4 fColorMatrix : packoffset(c1);
// }
//
// cbuffer ColorDeficientTable : register(b7)
// {
//   float4 cvdR : packoffset(c0);
//   float4 cvdG : packoffset(c1);
//   float4 cvdB : packoffset(c2);
// }
//
// cbuffer ImagePlaneParam : register(b8)
// {
//   float4 ColorParam : packoffset(c0);
//   float Levels_Rate : packoffset(c1);
//   float Levels_Range : packoffset(c1.y);
//   uint Blend_Type : packoffset(c1.z);
// }
//
// cbuffer CBControl : register(b9)
// {
//   uint cPassEnabled : packoffset(c0);
// }
//
// SamplerState BilinearClamp_s : register(s0);
// SamplerState TrilinearClamp_s : register(s1);
// Texture2D<float4> SourceImage : register(t0);
// StructuredBuffer<RadialBlurComputeResult> ComputeResultSRV : register(t1);
// Texture3D<float4> tTextureMap0 : register(t2);
// Texture3D<float4> tTextureMap1 : register(t3);
// Texture3D<float4> tTextureMap2 : register(t4);
// Texture2D<float4> ImagePlameBase : register(t5);
// Texture2D<float> ImagePlameAlpha : register(t6);
//
//
// // 3Dmigoto declarations
// #define cmp -
// Texture1D<float4> IniParams : register(t120);
// Texture2D<float4> StereoParams : register(t125);
//
//
// void main(
//   float4 v0 : SV_Position0,
//   float4 v1 : Kerare0,
//   float v2 : Exposure0,
//   out float4 o0 : SV_Target0)
// {
//   float4 r0,r1,r2,r3,r4,r5,r6,r7,r8,r9;
//   uint4 bitmask, uiDest;
//   float4 fDest;
//
//   r0.xyzw = cPassEnabled & int4(1,32,2,4);
//   if (r0.x != 0) {
//     r1.xy = v0.xy * screenInverseSize.xy + float2(-0.5,-0.5);
//     r1.z = fDistortionCoef * 0.5 + 1;
//     r1.z = max(1, r1.z);
//     r1.z = rcp(r1.z);
//     r1.w = dot(r1.xy, r1.xy);
//     r2.x = fDistortionCoef * r1.w + 1;
//     r2.xy = r2.xx * r1.xy;
//     r2.xy = r2.xy * r1.zz + float2(0.5,0.5);
//     if (aberrationEnable == 0) {
//       r3.xyz = SourceImage.Sample(BilinearClamp_s, r2.xy).xyz;
//       r3.xyz = v2.xxx * r3.xyz;
//       r2.z = max(r3.x, r3.y);
//       r2.z = max(r2.z, r3.z);
//       r2.w = (int)r2.z & 0x7f800000;
//       r2.w = cmp((int)r2.w == 0x7f800000);
//       if (r2.w != 0) {
//         r4.xyz = float3(1,1,1);
//       }
//       if (r2.w == 0) {
//         r2.z = r2.z * tonemapRange + 1;
//         r4.xyz = r3.xyz / r2.zzz;
//       }
//       r4.xyz = saturate(r4.xyz);
//     } else {
//       r1.w = fRefraction + r1.w;
//       r2.z = fDistortionCoef * r1.w + 1;
//       r2.zw = r2.zz * r1.xy;
//       r2.zw = r2.zw * r1.zz + float2(0.5,0.5);
//       r1.w = fRefraction + r1.w;
//       r1.w = fDistortionCoef * r1.w + 1;
//       r1.xy = r1.xy * r1.ww;
//       r1.xy = r1.xy * r1.zz + float2(0.5,0.5);
//       r3.xyz = SourceImage.Sample(BilinearClamp_s, r2.xy).xyz;
//       r3.xyz = v2.xxx * r3.xyz;
//       r1.w = max(r3.x, r3.y);
//       r1.w = max(r1.w, r3.z);
//       r2.x = (int)r1.w & 0x7f800000;
//       r2.x = cmp((int)r2.x == 0x7f800000);
//       if (r2.x != 0) {
//         r4.x = 1;
//       }
//       if (r2.x == 0) {
//         r1.w = r1.w * tonemapRange + 1;
//         r4.x = r3.x / r1.w;
//       }
//       r2.xyz = SourceImage.Sample(BilinearClamp_s, r2.zw).xyz;
//       r2.xyz = v2.xxx * r2.xyz;
//       r1.w = max(r2.x, r2.y);
//       r1.w = max(r1.w, r2.z);
//       r2.x = (int)r1.w & 0x7f800000;
//       r2.x = cmp((int)r2.x == 0x7f800000);
//       if (r2.x != 0) {
//         r4.y = 1;
//       }
//       if (r2.x == 0) {
//         r1.w = r1.w * tonemapRange + 1;
//         r4.y = r2.y / r1.w;
//       }
//       r1.xyw = SourceImage.Sample(BilinearClamp_s, r1.xy).xyz;
//       r1.xyw = v2.xxx * r1.xyw;
//       r1.x = max(r1.x, r1.y);
//       r1.x = max(r1.x, r1.w);
//       r1.y = (int)r1.x & 0x7f800000;
//       r1.y = cmp((int)r1.y == 0x7f800000);
//       if (r1.y != 0) {
//         r4.z = 1;
//       }
//       if (r1.y == 0) {
//         r1.x = r1.x * tonemapRange + 1;
//         r4.z = r1.w / r1.x;
//       }
//       r4.xyz = saturate(r4.xyz);
//     }
//     r1.x = fDistortionCoef;
//   } else {
//     r2.xy = (uint2)v0.xy;
//     r2.zw = float2(0,0);
//     r2.xyz = SourceImage.Load(r2.xyz).xyz;
//     r2.xyz = v2.xxx * r2.xyz;
//     r1.y = max(r2.x, r2.y);
//     r1.y = max(r1.y, r2.z);
//     r1.w = (int)r1.y & 0x7f800000;
//     r1.w = cmp((int)r1.w == 0x7f800000);
//     if (r1.w != 0) {
//       r4.xyz = float3(1,1,1);
//     }
//     if (r1.w == 0) {
//       r1.y = r1.y * tonemapRange + 1;
//       r4.xyz = r2.xyz / r1.yyy;
//     }
//     r4.xyz = saturate(r4.xyz);
//     r1.xz = float2(0,1);
//   }
//   if (r0.y != 0) {
//     r0.y = asint(cbRadialBlurFlags) & 2;
//     r1.yw = r0.yy ? float2(1,0) : float2(0,1);
//     r0.y = ComputeResultSRV[0].computeAlpha;
//     r0.y = r0.y * r1.y + r1.w;
//     r0.y = cbRadialColor.w * r0.y;
//     r1.y = cmp(r0.y == 0.000000);
//     if (r1.y != 0) {
//       r2.xyz = r4.xyz;
//     }
//     if (r1.y == 0) {
//       r0.x = r0.x ? 1 : 0;
//       r1.yw = screenInverseSize.xy * v0.xy;
//       r3.xy = v0.xy * screenInverseSize.xy + float2(-0.5,-0.5);
//       r3.xy = -cbRadialScreenPos.xy + r3.xy;
//       r3.zw = cmp(r3.xy < float2(0,0));
//       r5.xy = -v0.xy * screenInverseSize.xy + float2(1,1);
//       r1.yw = r3.zw ? r5.xy : r1.yw;
//       r2.w = asint(cbRadialBlurFlags) & 1;
//       r3.z = dot(r3.xy, r3.xy);
//       r3.w = rsqrt(r3.z);
//       r5.xy = r3.xy * r3.ww;
//       r5.xy = cbRadialSharpRange * r5.xy;
//       r5.xy = (uint3)abs(r5.xy);
//       r3.w = (int)r5.y + (int)r5.x;
//       r4.w = (int)r3.w ^ 61;
//       r3.w = (uint)r3.w >> 16;
//       r3.w = (int)r3.w ^ (int)r4.w;
//       r3.w = (int)r3.w * 9;
//       r4.w = (uint)r3.w >> 4;
//       r3.w = (int)r3.w ^ (int)r4.w;
//       r3.w = (int)r3.w * 0x27d4eb2d;
//       r4.w = (uint)r3.w >> 15;
//       r3.w = (int)r3.w ^ (int)r4.w;
//       r3.w = (uint)r3.w;
//       r3.w = 2.32830644e-010 * r3.w;
//       r2.w = r2.w ? r3.w : 1;
//       if (r0.x != 0) {
//         r0.x = sqrt(r3.z);
//         r0.x = max(1, r0.x);
//         r0.x = 1 / r0.x;
//         r5.xy = -cbRadialBlurPower * r1.yw;
//         r5.xy = r5.xy * r0.xx;
//         r5.xy = r5.xy * r2.ww;
//         r6.xyzw = r5.xyxy * float4(0.00111111114,0.00111111114,0.00999999978,0.00999999978) + float4(1,1,1,1);
//         r6.xyzw = r3.xyxy * r6.xyzw + cbRadialScreenPos.xyxy;
//         r0.x = dot(r6.xy, r6.xy);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r6.xy * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r7.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r8.xyzw = r5.xyxy * float4(0.00222222228,0.00222222228,0.00333333341,0.00333333341) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r0.x = dot(r8.xy, r8.xy);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.xy * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r9.xyz = float3(0.100000001,0.100000001,0.100000001) * r9.xyz;
//         r7.xyz = r7.xyz * float3(0.100000001,0.100000001,0.100000001) + r9.xyz;
//         r0.x = dot(r8.zw, r8.zw);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.zw * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyzw = r5.xyxy * float4(0.00444444455,0.00444444455,0.00555555569,0.00555555569) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r0.x = dot(r8.xy, r8.xy);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.xy * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r7.xyz = r9.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r0.x = dot(r8.zw, r8.zw);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.zw * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyzw = r5.xyxy * float4(0.00666666683,0.00666666683,0.00777777797,0.00777777797) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r0.x = dot(r8.xy, r8.xy);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.xy * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r7.xyz = r9.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r0.x = dot(r8.zw, r8.zw);
//         r0.x = r1.x * r0.x + 1;
//         r5.zw = r8.zw * r0.xx;
//         r5.zw = r5.zw * r1.zz + float2(0.5,0.5);
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r5.xy = r5.xy * float2(0.0088888891,0.0088888891) + float2(1,1);
//         r5.xy = r3.xy * r5.xy + cbRadialScreenPos.xy;
//         r0.x = dot(r5.xy, r5.xy);
//         r0.x = r1.x * r0.x + 1;
//         r5.xy = r5.xy * r0.xx;
//         r5.xy = r5.xy * r1.zz + float2(0.5,0.5);
//         r5.xyz = SourceImage.SampleLevel(BilinearClamp_s, r5.xy, 0).xyz;
//         r5.xyz = r5.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r0.x = dot(r6.zw, r6.zw);
//         r0.x = r1.x * r0.x + 1;
//         r6.xy = r6.zw * r0.xx;
//         r1.xz = r6.xy * r1.zz + float2(0.5,0.5);
//         r6.xyz = SourceImage.SampleLevel(BilinearClamp_s, r1.xz, 0).xyz;
//         r5.xyz = r6.xyz * float3(0.100000001,0.100000001,0.100000001) + r5.xyz;
//         r5.xyz = cbRadialColor.xyz * r5.xyz;
//         r5.xyz = v2.xxx * r5.xyz;
//         r0.x = max(r5.x, r5.y);
//         r0.x = max(r0.x, r5.z);
//         r1.x = (int)r0.x & 0x7f800000;
//         r1.x = cmp((int)r1.x == 0x7f800000);
//         if (r1.x != 0) {
//           r6.xyz = float3(1,1,1);
//         }
//         if (r1.x == 0) {
//           r0.x = r0.x * tonemapRange + 1;
//           r6.xyz = r5.xyz / r0.xxx;
//         }
//         r6.xyz = saturate(r6.xyz);
//         r5.xyz = cbRadialColor.xyz * r4.xyz;
//         r5.xyz = r5.xyz * float3(0.100000001,0.100000001,0.100000001) + r6.xyz;
//       } else {
//         r0.x = sqrt(r3.z);
//         r0.x = max(1, r0.x);
//         r0.x = 1 / r0.x;
//         r1.xy = -cbRadialBlurPower * r1.yw;
//         r1.xy = r1.xy * r0.xx;
//         r1.xy = r1.xy * r2.ww;
//         r6.xyzw = r1.xyxy * float4(0.00111111114,0.00111111114,0.00999999978,0.00999999978) + float4(1,1,1,1);
//         r6.xyzw = r3.xyxy * r6.xyzw + cbRadialScreenPos.xyxy;
//         r6.xyzw = float4(0.5,0.5,0.5,0.5) + r6.xyzw;
//         r7.xyz = SourceImage.SampleLevel(BilinearClamp_s, r6.xy, 0).xyz;
//         r8.xyzw = r1.xyxy * float4(0.00222222228,0.00222222228,0.00333333341,0.00333333341) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r8.xyzw = float4(0.5,0.5,0.5,0.5) + r8.xyzw;
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.xy, 0).xyz;
//         r9.xyz = float3(0.100000001,0.100000001,0.100000001) * r9.xyz;
//         r7.xyz = r7.xyz * float3(0.100000001,0.100000001,0.100000001) + r9.xyz;
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyzw = r1.xyxy * float4(0.00444444455,0.00444444455,0.00555555569,0.00555555569) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r8.xyzw = float4(0.5,0.5,0.5,0.5) + r8.xyzw;
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.xy, 0).xyz;
//         r7.xyz = r9.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyzw = r1.xyxy * float4(0.00666666683,0.00666666683,0.00777777797,0.00777777797) + float4(1,1,1,1);
//         r8.xyzw = r3.xyxy * r8.xyzw + cbRadialScreenPos.xyxy;
//         r8.xyzw = float4(0.5,0.5,0.5,0.5) + r8.xyzw;
//         r9.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.xy, 0).xyz;
//         r7.xyz = r9.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r8.xyz = SourceImage.SampleLevel(BilinearClamp_s, r8.zw, 0).xyz;
//         r7.xyz = r8.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r1.xy = r1.xy * float2(0.0088888891,0.0088888891) + float2(1,1);
//         r1.xy = r3.xy * r1.xy + cbRadialScreenPos.xy;
//         r1.xy = float2(0.5,0.5) + r1.xy;
//         r1.xyz = SourceImage.SampleLevel(BilinearClamp_s, r1.xy, 0).xyz;
//         r1.xyz = r1.xyz * float3(0.100000001,0.100000001,0.100000001) + r7.xyz;
//         r3.xyw = SourceImage.SampleLevel(BilinearClamp_s, r6.zw, 0).xyz;
//         r1.xyz = r3.xyw * float3(0.100000001,0.100000001,0.100000001) + r1.xyz;
//         r1.xyz = cbRadialColor.xyz * r1.xyz;
//         r1.xyz = v2.xxx * r1.xyz;
//         r0.x = max(r1.x, r1.y);
//         r0.x = max(r0.x, r1.z);
//         r1.w = (int)r0.x & 0x7f800000;
//         r1.w = cmp((int)r1.w == 0x7f800000);
//         if (r1.w != 0) {
//           r3.xyw = float3(1,1,1);
//         }
//         if (r1.w == 0) {
//           r0.x = r0.x * tonemapRange + 1;
//           r3.xyw = r1.xyz / r0.xxx;
//         }
//         r3.xyw = saturate(r3.xyw);
//         r1.xyz = cbRadialColor.xyz * r4.xyz;
//         r5.xyz = r1.xyz * float3(0.100000001,0.100000001,0.100000001) + r3.xyw;
//       }
//       r0.x = cmp(0 < cbRadialMaskRate.x);
//       if (r0.x != 0) {
//         r0.x = sqrt(r3.z);
//         r0.x = saturate(r0.x * cbRadialMaskSmoothstep.x + cbRadialMaskSmoothstep.y);
//         r1.x = r0.x * r0.x;
//         r0.x = -r0.x * 2 + 3;
//         r0.x = r1.x * r0.x;
//         r0.x = cbRadialMaskRate.x * r0.x + cbRadialMaskRate.y;
//         r1.xyz = r5.xyz + -r4.xyz;
//         r5.xyz = r0.xxx * r1.xyz + r4.xyz;
//       }
//       r1.xyz = r5.xyz + -r4.xyz;
//       r4.xyz = r0.yyy * r1.xyz + r4.xyz;
//     } else {
//       r4.xyz = r2.xyz;
//     }
//   }
//   r1.xyz = v1.xyz / v1.www;
//   r0.x = dot(r1.xyz, r1.xyz);
//   r0.x = rsqrt(r0.x);
//   r0.x = r1.z * r0.x;
//   r0.y = saturate(abs(r0.x) * kerare_scale + kerare_offset);
//   r0.y = 1 + -r0.y;
//   r0.x = abs(r0.x) * abs(r0.x);
//   r0.x = r0.x * r0.x;
//   r0.x = r0.x * r0.y;
//   r0.x = min(1, r0.x);
//   r1.xyz = r4.xyz * r0.xxx;
//   if (r0.z != 0) {
//     r0.yz = fNoiseUVOffset.xy * screenSize.xy + v0.xy;
//     r0.yz = fReverseNoiseSize * r0.yz;
//     r0.yz = floor(r0.yz);
//     r1.w = dot(r0.yz, float2(0.0671105608,0.00583714992));
//     r1.w = frac(r1.w);
//     r1.w = 52.9829178 * r1.w;
//     r1.w = frac(r1.w);
//     r2.x = cmp(r1.w < fNoiseDensity);
//     if (r2.x != 0) {
//       r0.y = r0.y * r0.z;
//       r0.y = (uint)r0.y;
//       r0.y = (int)r0.y ^ 0x00bc602f;
//       r0.y = (int)r0.y * 0x003779b9;
//       r0.z = (uint)r0.y << 6;
//       r2.x = (uint)r0.y >> 26;
//       r0.y = (int)r0.y ^ (int)r0.z;
//       r0.y = (int)r0.y ^ (int)r2.x;
//       r0.y = (uint)r0.y;
//       r0.y = 2.32830644e-010 * r0.y;
//     } else {
//       r0.y = 0;
//     }
//     r0.z = 757.48468 * r1.w;
//     r0.z = frac(r0.z);
//     r1.w = cmp(r0.z < fNoiseDensity);
//     if (r1.w != 0) {
//       r1.w = (int)r0.z ^ 0x00bc602f;
//       r1.w = (int)r1.w * 0x003779b9;
//       r2.x = (uint)r1.w << 6;
//       r2.y = (uint)r1.w >> 26;
//       r1.w = (int)r1.w ^ (int)r2.x;
//       r1.w = (int)r1.w ^ (int)r2.y;
//       r1.w = (uint)r1.w;
//       r1.w = r1.w * 2.32830644e-010 + -0.5;
//     } else {
//       r1.w = 0;
//     }
//     r0.z = 757.48468 * r0.z;
//     r0.z = frac(r0.z);
//     r2.x = cmp(r0.z < fNoiseDensity);
//     if (r2.x != 0) {
//       r0.z = (int)r0.z ^ 0x00bc602f;
//       r0.z = (int)r0.z * 0x003779b9;
//       r2.x = (uint)r0.z << 6;
//       r2.y = (uint)r0.z >> 26;
//       r0.z = (int)r0.z ^ (int)r2.x;
//       r0.z = (int)r0.z ^ (int)r2.y;
//       r0.z = (uint)r0.z;
//       r0.z = r0.z * 2.32830644e-010 + -0.5;
//     } else {
//       r0.z = 0;
//     }
//     r2.xy = fNoisePower.xy * r0.yz;
//     r2.z = fNoisePower.y * r1.w;
//     r3.x = dot(r2.xz, float2(1,1.40199995));
//     r3.y = dot(r2.xyz, float3(1,-0.344000012,-0.713999987));
//     r3.z = dot(r2.xy, float2(1,1.77199996));
//     r0.y = saturate(dot(r1.xyz, float3(0.298999995,-0.169,0.5)));
//     r0.y = 1 + -r0.y;
//     r0.y = log2(r0.y);
//     r0.y = fNoiseContrast * r0.y;
//     r0.y = exp2(r0.y);
//     r0.y = fBlendRate * r0.y;
//     r2.xyz = -r4.xyz * r0.xxx + r3.xyz;
//     r1.xyz = r0.yyy * r2.xyz + r1.xyz;
//   }
//   if (r0.w != 0) {
//     r1.xyz = saturate(r1.xyz);
//     r0.x = 0.5 * fTextureInverseSize;
//     r0.yzw = cmp(float3(0.00313080009,0.00313080009,0.00313080009) >= r1.xyz);
//     r2.xyz = float3(12.9200001,12.9200001,12.9200001) * r1.xyz;
//     r3.xyz = log2(r1.xyz);
//     r3.xyz = float3(0.416666657,0.416666657,0.416666657) * r3.xyz;
//     r3.xyz = exp2(r3.xyz);
//     r3.xyz = r3.xyz * float3(1.05499995,1.05499995,1.05499995) + float3(-0.0549999997,-0.0549999997,-0.0549999997);
//     r0.yzw = r0.yzw ? r2.xyz : r3.xyz;
//     r1.w = 1 + -fTextureInverseSize;
//     r0.xyz = r0.yzw * r1.www + r0.xxx;
//     r2.xy = cmp(float2(0,0) < fTextureBlendRate);
//     r0.w = r2.y ? r2.x : 0;
//     if (r0.w != 0) {
//       r3.xyz = tTextureMap0.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//       r4.xyz = tTextureMap1.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//       r4.xyz = r4.xyz + -r3.xyz;
//       r3.xyz = fTextureBlendRate * r4.xyz + r3.xyz;
//       r4.xyz = cmp(float3(0.00313080009,0.00313080009,0.00313080009) >= r3.xyz);
//       r5.xyz = float3(12.9200001,12.9200001,12.9200001) * r3.xyz;
//       r6.xyz = log2(r3.xyz);
//       r6.xyz = float3(0.416666657,0.416666657,0.416666657) * r6.xyz;
//       r6.xyz = exp2(r6.xyz);
//       r6.xyz = r6.xyz * float3(1.05499995,1.05499995,1.05499995) + float3(-0.0549999997,-0.0549999997,-0.0549999997);
//       r4.xyz = r4.xyz ? r5.xyz : r6.xyz;
//       r4.xyz = tTextureMap2.SampleLevel(TrilinearClamp_s, r4.xyz, 0).xyz;
//       r4.xyz = r4.xyz + -r3.xyz;
//       r3.xyz = fTextureBlendRate2 * r4.xyz + r3.xyz;
//     } else {
//       if (r2.x != 0) {
//         r2.xzw = tTextureMap0.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//         r4.xyz = tTextureMap1.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//         r4.xyz = r4.xyz + -r2.xzw;
//         r3.xyz = fTextureBlendRate * r4.xyz + r2.xzw;
//       } else {
//         if (r2.y != 0) {
//           r2.xyz = tTextureMap0.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//           r4.xyz = cmp(float3(0.00313080009,0.00313080009,0.00313080009) >= r2.xyz);
//           r5.xyz = float3(12.9200001,12.9200001,12.9200001) * r2.xyz;
//           r6.xyz = log2(r2.xyz);
//           r6.xyz = float3(0.416666657,0.416666657,0.416666657) * r6.xyz;
//           r6.xyz = exp2(r6.xyz);
//           r6.xyz = r6.xyz * float3(1.05499995,1.05499995,1.05499995) + float3(-0.0549999997,-0.0549999997,-0.0549999997);
//           r4.xyz = r4.xyz ? r5.xyz : r6.xyz;
//           r4.xyz = tTextureMap2.SampleLevel(TrilinearClamp_s, r4.xyz, 0).xyz;
//           r4.xyz = r4.xyz + -r2.xyz;
//           r3.xyz = fTextureBlendRate2 * r4.xyz + r2.xyz;
//         } else {
//           r3.xyz = tTextureMap0.SampleLevel(TrilinearClamp_s, r0.xyz, 0).xyz;
//         }
//       }
//     }
//     r0.xyz = fColorMatrix._m10_m11_m12 * r3.yyy;
//     r0.xyz = r3.xxx * fColorMatrix._m00_m01_m02 + r0.xyz;
//     r0.xyz = r3.zzz * fColorMatrix._m20_m21_m22 + r0.xyz;
//     r1.xyz = fColorMatrix._m30_m31_m32 + r0.xyz;
//   }
//   r0.xy = cPassEnabled & int2(8,16);
//   if (r0.x != 0) {
//     r2.x = saturate(dot(r1.xyz, cvdR.xyz));
//     r2.y = saturate(dot(r1.xyz, cvdG.xyz));
//     r2.z = saturate(dot(r1.xyz, cvdB.xyz));
//     r1.xyz = r2.xyz;
//   }
//   if (r0.y != 0) {
//     r0.xy = screenInverseSize.xy * v0.xy;
//     r2.xyzw = ImagePlameBase.SampleLevel(BilinearClamp_s, r0.xy, 0).xyzw;
//     r3.xyzw = ColorParam.xyzw * r2.xyzw;
//     r0.x = ImagePlameAlpha.SampleLevel(BilinearClamp_s, r0.xy, 0).x;
//     r0.x = saturate(r0.x * Levels_Rate + Levels_Range);
//     r0.x = r0.x * r3.w;
//     r0.yzw = cmp(r3.xyz < float3(0.5,0.5,0.5));
//     r3.xyz = r3.xyz * r1.xyz;
//     r3.xyz = r3.xyz + r3.xyz;
//     r2.xyz = -r2.xyz * ColorParam.xyz + float3(1,1,1);
//     r2.xyz = r2.xyz + r2.xyz;
//     r4.xyz = float3(1,1,1) + -r1.xyz;
//     r2.xyz = -r2.xyz * r4.xyz + float3(1,1,1);
//     r0.yzw = r0.yzw ? r3.xyz : r2.xyz;
//     r0.yzw = r0.yzw + -r1.xyz;
//     r1.xyz = r0.xxx * r0.yzw + r1.xyz;
//   }
//   o0.xyz = r1.xyz;
//   o0.w = 0;
//   return;
// }
//////////////////////////////// HLSL Errors ////////////////////////////////
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(151,18-40): warning X3203: signed/unsigned mismatch, unsigned assumed
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(174,18-40): warning X3203: signed/unsigned mismatch, unsigned assumed
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(187,18-40): warning X3203: signed/unsigned mismatch, unsigned assumed
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(200,18-40): warning X3203: signed/unsigned mismatch, unsigned assumed
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(219,16-38): warning X3203: signed/unsigned mismatch, unsigned assumed
// E:\SteamLibrary\steamapps\common\Devil May Cry 5\ShaderFixes\ebb9cb0dd42f0b5a-ps_replace.txt(253,15-31): error X3017: cannot convert from 'const float2' to 'uint3'
/////////////////////////////////////////////////////////////////////////////
