修改水

This commit is contained in:
2026-01-01 22:00:33 +08:00
parent 040a222bd6
commit 9ceffccd39
1800 changed files with 103929 additions and 139495 deletions

View File

@@ -18,8 +18,8 @@
#pragma fragment frag
#pragma fragmentoption ARB_precision_hint_fastest
#include "../../Resources/ObiMaterials/Common/ObiEllipsoids.cginc"
#include "../../Resources/ObiMaterials/Common/ObiUtils.cginc"
#include "../../Resources/ObiMaterials/ObiEllipsoids.cginc"
#include "../../Resources/ObiMaterials/ObiUtils.cginc"
fixed4 _Color;
@@ -42,7 +42,6 @@
float3 lightDir : TEXCOORD2;
float3 a2 : TEXCOORD3;
float3 a3 : TEXCOORD4;
//float3x3 P : TEXCOORD5;
};
struct fout
@@ -66,7 +65,6 @@
o.mapping = float4(v.corner.xy,1/length(eye),radius); // A[1]
o.viewRay = mul((float3x3)UNITY_MATRIX_V,view); // A[0]
o.color = v.color * _Color;
//o.P = float3x3(v.t0.xyz,v.t1.xyz,v.t2.xyz);
BuildAuxiliaryNormalVectors(v.vertex,worldPos,view,P,IP,o.a2,o.a3);
@@ -88,19 +86,6 @@
// clip space position:
float4 pos = mul(UNITY_MATRIX_P,float4(p,1.0));
// local space normal, use to calculate UVs
/*float3 ln = mul(mul((float3x3)i.P,UNITY_MATRIX_I_V) ,n);
float2 uv = float2(
// atan returns a value between -pi and pi
// so we divide by pi * 2 to get -0.5 to 0.5
atan2(ln.x, ln.y) / (3.1415 * 2.0),
// acos returns 0.0 at the top, pi at the bottom
// so we flip the y to align with Unity's OpenGL style
// texture UVs so 0.0 is at the bottom
acos(-ln.z) / 3.1415
);*/
// simple lighting: ambient
float3 modelUp = mul (UNITY_MATRIX_IT_MV,float3(0,1,0));
float vecHemi = dot(n, modelUp) * 0.5f + 0.5f;