| 251 | } |
| 252 | |
| 253 | bool SpherePrimitiveEvaluator::closestPoint( const V3f &p, PrimitiveEvaluator::Result *result ) const |
| 254 | { |
| 255 | assert( dynamic_cast<Result *>( result ) ); |
| 256 | |
| 257 | Result *sr = static_cast<Result *>( result ); |
| 258 | |
| 259 | sr->m_p = p.normalized() * m_sphere->radius(); |
| 260 | |
| 261 | return true; |
| 262 | } |
| 263 | |
| 264 | bool SpherePrimitiveEvaluator::pointAtUV( const Imath::V2f &uv, PrimitiveEvaluator::Result *result ) const |
| 265 | { |