Do renders have a solid idea about the refractive indices in the objects that they propagate rays? Since the formula for propagation is n1sin(theta_1) = n_2 sin(theta_2) where the n_1, n_2 are dependent on the materials used and the theta is dependent on the material). In this case, we refract between air and glass (I suppose), so without a dictionary of index is there any shortcut?
@philippe-eecs In this case, I believe we'd be storing the refractive index of any translucent material as one of the material's properties, the same way we need to store information about the texture/color/roughness/etc. of objects. You could keep a "default" refractive index that you use in cases where it's not specified, but most scenes probably won't have enough variation of materials where storing a different one for each translucent material type is actually taxing in any way.
When I took 61a someone implemented a ray tracing algorithm in Scheme for the final art project. I thought it was crazy then, and now, after learning the algorithm 3 years later in 184, I'm honestly even more impressed