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

232
Vistas
Finding perpendicular and parallel points

How to find the points marked in a picture (P0', P1', P2 ', P3')

Points are known:

  • P0, P1, P2, P3
  • l1 and l2

Point = Vector3(x,y,z)

EDIT:

Initially I am trying to set the point P0'

var l1 = 1.2f;
var l2 = 0.7f;

var v30n = (P3 + P0).normalized;
var v10n = (P1 + P0).normalized;

var pl1 = P0 + v30n * l1;
var pl2 = P0 - v10n * l2;
var P0prim = pl1 + pl2;

enter image description here

over 4 years ago · Santiago Trujillo
2 Respuestas
Responde la pregunta

0

Careful with the directions:

var l1 = 1.2f;
var l2 = 0.7f;

var v30n = (P0 - P3).normalized; //corrected here
var v10n = (P0 - P1).normalized; //corrected here

var pl1 =  v30n * l1;
var pl2 = v10n * l2; // corrected here
var P0prim = P0 + pl1 + pl2;

Did not debug that out, but the direction is: (final point - starting point).normlized

over 4 years ago · Santiago Trujillo Denunciar

0

What @rustyBucketBay says is the correct answer (he was faster than me!), but in case you know that the proportions of l1 and l2 are equals, you can also do the follow:

We know that If you sum all the X's and divide by 4 (the number of corners) and do the same for the Y's, you will have the center of the square.

So if we sum l1+l2 to every point of the square, and do the same, we will have the expected square but displaced. Now we want to relocate the center of the new big square.

To achieve that we only have to calculate the center of the new big square (again, divide by 4 X's and Y's) and calculate the vector between both square centers, the small one and the big one.

With this calculated vector, we can just sum it to the new big square points, and will be relocated.

over 4 years ago · Santiago Trujillo Denunciar
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