Re: Transformed Pointer Coordinates?

On Feb 12, 2013, at 8:26 PM, Rik Cabanier <cabanier@gmail.com> wrote:

> On Wed, Feb 13, 2013 at 3:08 PM, Simon Fraser <smfr@me.com> wrote:
> On Feb 12, 2013, at 9:29 AM, Rik Cabanier <cabanier@gmail.com> wrote:
> 
>> I agree. The vast majority of people are just interested in the 2d transform.
>> 
>> Another issue with 3d is how transform-style [1] is treated.
>> for intstance:
>> <div id="a">
>> <div style="transform: rotate3d(...); transform-style: preserve-3d">
>> <div id="b" style="transform: rotate3d(...); transform-style: flat">
>> 
>> Does it make sense to transform point between a and b?
> 
> Sure, I don't see anything wrong with this. Even mapping into an element with transform-style: preserve-3d is fine; you're just mapping into the plane of that element.
> 
> yeah, preserve-3d is not so bad. I thought 'flat' would be harder to do but maybe not.
> How do you handle edge cases where a plane becomes a line? 

Yeah, that can be problematic. In fact, mapping onto a plane becomes problematic whenever the w component in point projection is < 0 (which can happen when mapping into elements with rotations in X or Y under a perspective).

I'm not sure how to handle these edge cases. Throwing an exception is probably too disruptive for authors.

Simon

Received on Wednesday, 13 February 2013 04:56:59 UTC