J
J
Jeket2020-04-12 18:35:44
WebGL
Jeket, 2020-04-12 18:35:44

How to find all objects inside a CircleGeometry?

Good evening!
How to find all objects that fall wholly or partially inside a CircleGeometry?

I create a circle according to the instructions:

var geometry = new THREE.CircleGeometry( 10, 32 );
var material = new THREE.MeshBasicMaterial( {color: 0xffff00} );
var circle = new THREE.Mesh( geometry, material );


Next, I add the circle to the scene. The question is how to find other objects that are completely or partially within the circle?
For example, dots, lines, or part of a line.

Let's say there are a lot of points in the scene and it will take a long time to just sort through the coordinates. It is desirable to somehow use Raycaster, but I do not know if it is possible to rotate the beam like a radar in order to search for all intersections.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question