Skip to main content

Timeline for answer to What is this wacky math in three.js by slebetman

Current License: CC BY-SA 3.0

Post Revisions

7 events
when toggle format what by license comment
Aug 21, 2016 at 15:43 comment added slebetman @joeb: FWIW, the answer is in ratio. Typically though, we'd call it "fraction" as in what fraction of the screen is the mouse in. It's not useful for things like "where do I draw this?" because you need pixel values for that but it's useful for "is this close enough?" or "am I somewhere in the center?"
Aug 21, 2016 at 15:40 vote accept joeb
Aug 21, 2016 at 15:40 comment added joeb nevermind. Found my answer in this image google.com/…
Aug 21, 2016 at 15:24 comment added joeb @slebetman. Thanks for the pretty thorough explanation. Let me expand a bit on what I take away from it. If I am understanding you correctly, then 0,0 is always dead center of my screen. Let me put the math into literal. (1000 / 1920) * 2 - 1 = 0.041666. Is the sum of this equation also in radians? My brain was expecting a pixel value. The rotation explanation i totally get, i have no questions there.
Aug 21, 2016 at 15:10 history edited slebetman CC BY-SA 3.0
added 433 characters in body
Aug 21, 2016 at 15:07 comment added Gerardo Furtado I was about to hit enter and explain what is a normalized position ranging from -1 to +1... Good on you, upvoted.
Aug 21, 2016 at 15:06 history answered slebetman CC BY-SA 3.0