| 239 | } |
| 240 | |
| 241 | void updateInstance (RTCScene scene, Instance* instance) |
| 242 | { |
| 243 | #if ENABLE_NATIVE_INSTANCING |
| 244 | rtcSetGeometryTransform(instance->geometry,0,RTC_FORMAT_FLOAT4X4_COLUMN_MAJOR,(float*)&instance->local2world); |
| 245 | #endif |
| 246 | |
| 247 | instance->world2local = rcp(instance->local2world); |
| 248 | instance->normal2world = transposed(rcp(instance->local2world.l)); |
| 249 | rtcCommitGeometry(instance->geometry); |
| 250 | } |
| 251 | |
| 252 | // ======================================================================== // |
| 253 | // User defined sphere geometry // |
no test coverage detected