Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

233
Views
angleMode (GRADOS) en p5.js no hace ninguna diferencia

Hice un boceto de reloj usando p5. Hasta ahora, solo se ha agregado la aguja de segundos. Pero cuando comencé el proyecto, no tenía idea de que funcionaba en radianes. Ahora quiero convertirlo a grados, probé lo siguiente:

 d = new Date() h = d.getHours() s = d.getSeconds() let c let stheta = 90 let r function setup() { c = createCanvas(400, 400); r = c.height/2 } function draw() { background(220); translate(c.width/2,c.height/2) strokeWeight(1) circle(0,0,c.height+5) strokeWeight(5) point(0,0) angleMode(DEGREES) line(0,0,Math.sin(stheta)*r,Math.cos(stheta)*r) } setInterval(()=>{ stheta+=6 },1000)

Pero esto no dio el mismo resultado. Aquí está el boceto de lo que probé con grados. ¿Cómo puedo convertirlo en grados? Gracias por adelantado.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!