This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 26526 - Fix aspect ratio constraint
Summary: Fix aspect ratio constraint
Status: RESOLVED WONTFIX
Alias: None
Product: WebRTC Working Group
Classification: Unclassified
Component: Media Capture and Streams (show other bugs)
Version: unspecified
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: public-media-capture@w3.org
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-05 16:28 UTC by Martin Thomson
Modified: 2014-09-25 14:48 UTC (History)
4 users (show)

See Also:


Attachments

Description Martin Thomson 2014-08-05 16:28:16 UTC
A floating point value for a constraint won't compare to itself safely.  1.778 != 16/9.

I think that we need to have an epsilon value defined for comparison here.  Either that or we define a string microformat (bleargh) or a new structure (puke).

A numeric value does allow for a cleaner evaluation of the ideal thing.
Comment 1 Silvia Pfeiffer 2014-08-07 01:09:17 UTC
We handle width and height separately, why not { aspect: {x : 16, y : 9} }. Doesn't seem that complicated.
Comment 2 Cullen Jennings 2014-09-11 14:42:06 UTC
We previously decided match to 10 decimal points. I'd be perfectly happy to say an epsilon of 1e-10. (or any other value, 1e-10 was picked sort of randomly as being very small so will work with video camera that are 10k by 10k but still large enough that it easily fit inside a double. If someone has a different value of epsilon to propose, I'd be fine with that.
Comment 3 Jan-Ivar Bruaroey [:jib] 2014-09-11 16:21:11 UTC
I think the existing epsilon covers inaccuracies in double just fine, and that arguments to change it were in the opposite direction, chasing the problem of interpreting expectations correctly of people entering decimals by hand.

I believe Harald proposed 1/1000 [1], and I indicated perhaps 1/100 as being better, citing wikipedia [2] as evidence that accuracy-needs on aspect don't rise with higher resolutions.

[1] http://lists.w3.org/Archives/Public/public-media-capture/2014Aug/0056.html
[2] http://lists.w3.org/Archives/Public/public-media-capture/2014Aug/0084.html
Comment 4 Cullen Jennings 2014-09-25 14:48:53 UTC
Chairs editors talked about this and it seemed like the current doc is fine - all this proposes is a different value of epsilon and no argument was made why current value is not OK. If someone objects, don't shoot me, I'm just the messenger.