I need to find a random position outside a box but is inside a circle, basically the random position between the the box and the circle. What i think of is just rand() a position inside a circle, and check whether the position is outside the box, basically doing a collision check. Is there a more efficient way than this method?
Aucun commentaire:
Enregistrer un commentaire