Search across packages, versions, files, declarations, and comments. Use multiple terms to narrow results (AND), and add @vertex, @fragment, or @compute to filter by shader stage.
1#define_import_path bevy_gaussian_splatting::transform
3#import bevy_gaussian_splatting::bindings::view
5fn world_to_clip(world_pos: vec3<f32>) -> vec4<f32> {
6 let homogenous_pos = view.unjittered_clip_from_world * vec4<f32>(world_pos, 1.0);
7 return homogenous_pos / (homogenous_pos.w + 0.000000001);
8}
10fn in_frustum(clip_space_pos: vec3<f32>) -> bool {
11 return abs(clip_space_pos.x) < 1.1
12 && abs(clip_space_pos.y) < 1.1
13 && abs(clip_space_pos.z - 0.5) < 0.5;
Contents