feat(all): 迁移扩展相关功能
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
#include <utils>
|
||||
|
||||
uniform mat4 projectionMatrix;
|
||||
uniform mat4 modelViewMatrix;
|
||||
|
||||
in vec3 position;
|
||||
|
||||
out vec3 pos;
|
||||
|
||||
|
||||
void main() {
|
||||
pos = position.xyz;
|
||||
pos.x *= poolHalfSize.x;
|
||||
pos.z *= poolHalfSize.y;
|
||||
// 墙体高度与水面齐平:y ∈ [-1, 1] 映射到 [-poolHeight, 0]
|
||||
pos.y = ((1.0 - pos.y) * 0.5 - 1.0) * poolHeight;
|
||||
|
||||
gl_Position = projectionMatrix * modelViewMatrix * vec4(pos, 1.0);
|
||||
}
|
||||
Reference in New Issue
Block a user