Files
cocos4/editor/assets/effects/builtin-wireframe.effect
T
Jare Guo 0319477911 fix decorator warning of ValueTypes (#7553)
* fix decorator warning of ValueTypes (sync #6285)

* refresh copyright
2020-10-21 16:31:41 +08:00

50 lines
927 B
Plaintext

// Copyright (c) 2017-2020 Xiamen Yaji Software Co., Ltd.
CCEffect %{
techniques:
- name: opaque
passes:
- vert: wireframe-vs:vert
frag: wireframe-fs:frag
properties:
lineColor: { value: [1, 1, 1, 1] }
}%
CCProgram wireframe-vs %{
precision mediump float;
#include <cc-global>
#include <cc-local-batch>
#include <input>
uniform TexCoords {
vec4 lineColor;
};
out vec2 bary;
out vec4 lineCol;
vec4 vert () {
vec4 position;
CCVertInput(position);
mat4 matWorld;
CCGetWorldMatrix(matWorld);
bary = a_texCoord;
lineCol = lineColor;
return cc_matProj * (cc_matView * matWorld) * position;;
}
}%
CCProgram wireframe-fs %{
precision mediump float;
#include <output>
in vec2 bary;
in vec4 lineCol;
vec4 frag () {
return CCFragOutput(lineCol);
}
}%