Calculate the coordinates of the sampling point in the world coordinate system according to the light origin, direction and depth value of the sampling point Args: ray_start (tensor, N_rays*1*3): ray's origin coordinates in world coordinate. ray_dir (tensor, N_rays
(ray_start, ray_dir, depths)
| 5 | |
| 6 | |
| 7 | def ray(ray_start, ray_dir, depths): |
| 8 | """ |
| 9 | Calculate the coordinates of the sampling point in the world coordinate system according to the light origin, |
| 10 | direction and depth value of the sampling point |
| 11 | |
| 12 | Args: |
| 13 | ray_start (tensor, N_rays*1*3): ray's origin coordinates in world coordinate. |
| 14 | ray_dir (tensor, N_rays*1*3): ray's dir in world coordinate. |
| 15 | depths (tensor, N_rays*N_points*1): depths of sampling points along the ray. |
| 16 | |
| 17 | Returns: |
| 18 | ray_start+ray_dir*depth (tensor, N_rays*N_points*3): sampling points in world |
| 19 | """ |
| 20 | return ray_start + ray_dir * depths |
| 21 | |
| 22 | |
| 23 | def fill_in(shape, mask, input, initial=1.0): |
no outgoing calls
no test coverage detected