Untitled
Loading...
Searching...
No Matches
focal_distance.comp File Reference

Go to the source code of this file.

Data Structures

struct  MeshNode
 MeshNodes that describe the position of Meshes, GLTF nodes for GLTFAnimations, or hold references to other MeshNodes. More...

Macros

#define MAX_MESH_NODES   1024

Functions

 layout (local_size_x=1, local_size_y=1, local_size_z=1) in
 layout (std140, binding=0) uniform CameraData
 layout (std430, binding=15) buffer MeshNodeData
vec3 get_view_pos_from_depth (vec2 uv, float depth, mat4 invProjMatrix)
float linearize (float z)
void main ()

Variables

uniform sampler2D gDepth
uniform vec2 uTexelSize
uniform vec2 uResolution
uniform float uDT

Macro Definition Documentation

◆ MAX_MESH_NODES

#define MAX_MESH_NODES   1024

Definition at line 33 of file focal_distance.comp.

Function Documentation

◆ layout() [1/3]

layout ( local_size_x = 1,
local_size_y = 1,
local_size_z = 1 )

References layout().

◆ layout() [2/3]

layout ( std140 ,
binding = 0 )

Definition at line 6 of file focal_distance.comp.

References layout(), projection, and view.

◆ layout() [3/3]

layout ( std430 ,
binding = 15 )

Definition at line 34 of file focal_distance.comp.

References layout(), and MAX_MESH_NODES.

◆ get_view_pos_from_depth()

vec3 get_view_pos_from_depth ( vec2 uv,
float depth,
mat4 invProjMatrix )

Definition at line 49 of file focal_distance.comp.

References get_view_pos_from_depth(), uv, and vec4::w.

◆ linearize()

float linearize ( float z)

Definition at line 58 of file focal_distance.comp.

References linearize().

◆ main()

void main ( )

Definition at line 65 of file focal_distance.comp.

References gDepth, get_view_pos_from_depth(), main(), uDT, uResolution, uTexelSize, uv, and vec3::z.

Variable Documentation

◆ gDepth

uniform sampler2D gDepth

Definition at line 44 of file focal_distance.comp.

◆ uTexelSize

uniform vec2 uTexelSize

Definition at line 45 of file focal_distance.comp.

◆ uResolution

uniform vec2 uResolution

Definition at line 46 of file focal_distance.comp.

Referenced by main().

◆ uDT

uniform float uDT

Definition at line 47 of file focal_distance.comp.

Referenced by main().