Why are HLSL cosines fucked
This commit is contained in:
1 parent
1db6af2055
commit
b0f41dffa0
4 files changed
+3
-3
No files matched your search
@@ -19,7 +19,7 @@ float2 uLegacyArmorSheetSize;
|
||||
float4 PixelShaderFunction(float4 sampleColor : COLOR0, float2 coords : TEXCOORD0) : COLOR0
|
||||
{
|
||||
float4 returnColor = tex2D(uImage0, coords);
|
||||
returnColor.rgb *= uColor * max(1, (cos(uTime) * 0.5 + 0.5) * 0.3 + 1.3);
|
||||
returnColor.rgb *= uColor * max(1, (sin(uTime) * 0.5 + 0.5) * 0.3 + 1.3);
|
||||
return returnColor;
|
||||
}
|
||||
technique Technique1
|
||||
|
||||
Binary file not shown.
@@ -36,9 +36,9 @@ VertexShaderOutput VertexShaderFunction(in VertexShaderInput input)
|
||||
VertexShaderOutput output = (VertexShaderOutput) 0;
|
||||
float2 coords = input.Coordinates - 0.5;
|
||||
float rotationSine = sin(uSaturation);
|
||||
float rotationCosine = cos(uSaturation);
|
||||
float rotationCosine = sin(uSaturation + 1.57);
|
||||
float rotationOriginSine = sin(uCircularRotation);
|
||||
float rotationOriginCosine = cos(uCircularRotation);
|
||||
float rotationOriginCosine = sin(uCircularRotation + 1.57);
|
||||
float2x2 rotationMatrix = float2x2(rotationCosine, -rotationSine, rotationSine, rotationCosine);
|
||||
float2x2 circularRotationMatrix = float2x2(rotationOriginCosine, -rotationOriginSine, rotationOriginSine, rotationOriginCosine);
|
||||
float2x2 scalingMatrix = float2x2(2, 0, 0, 1);
|
||||
|
||||
Binary file not shown.
Reference in new issue
Block a user