Welcome to mirror list, hosted at ThFree Co, Russian Federation.

object_outline_prepass_vert.glsl « shaders « modes « draw « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: ba824a7c0079185378640ef57959c4cca5a2c5da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

uniform mat4 ModelViewMatrix;
uniform mat4 ModelViewProjectionMatrix;

in vec3 pos;

out vec4 pPos;
out vec3 vPos;

void main()
{
	vPos = (ModelViewMatrix * vec4(pos, 1.0)).xyz;
	pPos = ModelViewProjectionMatrix * vec4(pos, 1.0);
	/* Small bias to always be on top of the geom. */
	pPos.z -= 1e-3;
}