random point in circle
| 167 | |
| 168 | // random point in circle |
| 169 | inline vec2f randCircle() |
| 170 | { |
| 171 | vec2f r; |
| 172 | |
| 173 | do { |
| 174 | r = vec2f(sfrand(), sfrand()); |
| 175 | } while (length(r) > 1.0f); |
| 176 | |
| 177 | return r; |
| 178 | } |
| 179 | |
| 180 | // random point in sphere |
| 181 | inline vec3f randSphere() |
no test coverage detected