Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/engines/eevee/shaders/object_motion_vert.glsl
| #pragma BLENDER_REQUIRE(common_view_lib.glsl) | #pragma BLENDER_REQUIRE(common_view_lib.glsl) | ||||
| #pragma BLENDER_REQUIRE(common_hair_lib.glsl) | #pragma BLENDER_REQUIRE(common_hair_lib.glsl) | ||||
| uniform mat4 currModelMatrix; | |||||
| uniform mat4 prevModelMatrix; | |||||
| uniform mat4 nextModelMatrix; | |||||
| uniform bool useDeform; | |||||
| #ifdef HAIR | |||||
| uniform samplerBuffer prvBuffer; /* RGBA32F */ | |||||
| uniform samplerBuffer nxtBuffer; /* RGBA32F */ | |||||
| #else | |||||
| in vec3 pos; | |||||
| in vec3 prv; /* Previous frame position. */ | |||||
| in vec3 nxt; /* Next frame position. */ | |||||
| #endif | |||||
| out vec3 currWorldPos; | |||||
| out vec3 prevWorldPos; | |||||
| out vec3 nextWorldPos; | |||||
| void main() | void main() | ||||
| { | { | ||||
| GPU_INTEL_VERTEX_SHADER_WORKAROUND | GPU_INTEL_VERTEX_SHADER_WORKAROUND | ||||
| #ifdef HAIR | #ifdef HAIR | ||||
| bool is_persp = (ProjectionMatrix[3][3] == 0.0); | bool is_persp = (ProjectionMatrix[3][3] == 0.0); | ||||
| float time, thick_time, thickness; | float time, thick_time, thickness; | ||||
| vec3 tan, binor; | vec3 tan, binor; | ||||
| Show All 29 Lines | |||||