{"id":20220,"date":"2013-02-22T14:54:38","date_gmt":"2013-02-22T21:54:38","guid":{"rendered":"http:\/\/css-tricks.com\/?p=20220"},"modified":"2013-02-22T16:44:42","modified_gmt":"2013-02-22T23:44:42","slug":"w3conf-luz-caballero-device-disorientation","status":"publish","type":"post","link":"https:\/\/css-tricks.com\/w3conf-luz-caballero-device-disorientation\/","title":{"rendered":"[W3Conf] Luz Caballero: “Device (dis)orientation?”"},"content":{"rendered":"
Luz Caballero (@gerbille<\/a>) used to be Dev Relations at Opera and talked about the mathematical world of device orientation on mobile devices.<\/p>\n <\/p>\n These are my notes from her presentation at W3Conf<\/a> in San Francisco as part of this live blog series<\/a>.<\/p>\n<\/div>\n Device orientation. It’s not just “portrait” and “landscape.” It’s made of three things:<\/p>\n There are different types of apps that can make use of this information:<\/p>\n Static application<\/strong> = measure things and make a one-off use of that information (like a maps app) Luz showed off a cool demo of a teapot drawn in WebGL and rotated it all around in 3D just by moving her phone around. The connection was made from phone to web through Web Sockets.<\/p>\n Orientation is a bit complex mathemantically (Tait-Bryan angles<\/a>). There are three axis and then different combinations of them. Alpha, Beta, and Gamma (they have other names too, like “the pitch.”).<\/p>\n\n
\nDynamic application<\/strong> = constant moving of device, using that information constantly to affect app (like a driving game)<\/p>\n