(depth, z_near, z_far)
| 3309 | |
| 3310 | |
| 3311 | def convert_depth_to_frame(depth, z_near, z_far): |
| 3312 | w = len(depth[0]) |
| 3313 | h = len(depth) |
| 3314 | frame = [[None] * w for _ in range(h)] |
| 3315 | for y in range(h): |
| 3316 | for x in range(w): |
| 3317 | frame[y][x] = (int(255 * (z_far - depth[y][x]) / (z_far - z_near)),) * 3 |
| 3318 | return frame |
| 3319 | |
| 3320 | |
| 3321 | def fxaa(frame, threshold=0.1, channel=0) -> list: |
nothing calls this directly
no outgoing calls
no test coverage detected