Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

153
Vistas
Raycaster with threejs and draw points on the plane by clicking

Hellow everyone ,I had some question with my procedure about threejs with Raycaster I add a plane to scene and I want to draw a point by clicking on the plane,but the DOM don't fill the screen

Here is my selection handler, used in vue.js:

const canvas = this.$refs.dreamview.getBoundingClientRect();
const pointer = new THREE.Vector2();
pointer.x =((event.clientX - canvas.left) /canvas.width) *2 1;
pointer.y =-((event.clientY - canvas.top) /canvas.height) *2 +1;
this.raycaster.setFromCamera(pointer, this.camera);
const intersects = this.raycaster.intersectObjects(scene.children, false);
let plane = intersects.find((e) => e.object.name === "plane");

I get the set of coordinates using the code above,but the plane.point is incorrect,i don't understand what went wrong;

Thank you all for any advice that you could give on this.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda