Home
last modified time | relevance | path

Searched refs:ray (Results 1 – 1 of 1) sorted by relevance

/AliOS-Things-master/components/py_engine/tests/perf_bench/
A Dmisc_raytrace.py92 def intersect(self, ray): argument
93 v = self.centre - ray.p
94 b = v.dot(ray.d)
116 def intersect(self, ray): argument
145 def trace_ray(scene, ray, depth): argument
150 t = obj.intersect(ray)
160 point = ray.p + ray.d * hit_t
162 if ray.d.dot(surf_norm) > 0:
166 reflected = ray.d - surf_norm * (surf_norm.dot(ray.d) * 2)
191 col += trace_ray(scene, Ray(point + ray.d * EPS, ray.d), depth - 1) * surf.transp
[all …]

Completed in 3 milliseconds