| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <!-- | 2 <!-- |
| 3 Copyright 2016 The Chromium Authors. All rights reserved. | 3 Copyright 2016 The Chromium Authors. All rights reserved. |
| 4 Use of this source code is governed by a BSD-style license that can be | 4 Use of this source code is governed by a BSD-style license that can be |
| 5 found in the LICENSE file. | 5 found in the LICENSE file. |
| 6 --> | 6 --> |
| 7 | 7 |
| 8 <link rel="import" href="/tracing/base/base.html"> | 8 <link rel="import" href="/tracing/base/base.html"> |
| 9 | 9 |
| 10 <script> | 10 <script> |
| 11 'use strict'; | 11 'use strict'; |
| 12 | 12 |
| 13 tr.exportTo('tr.b', function() { | 13 tr.exportTo('tr.b.math', function() { |
| 14 var PERCENTILE_PRECISION = 1e-7; | 14 var PERCENTILE_PRECISION = 1e-7; |
| 15 /** | 15 /** |
| 16 * A function that consists of linear pieces. | 16 * A function that consists of linear pieces. |
| 17 * See https://en.wikipedia.org/wiki/Piecewise_linear_function. | 17 * See https://en.wikipedia.org/wiki/Piecewise_linear_function. |
| 18 * @constructor | 18 * @constructor |
| 19 */ | 19 */ |
| 20 function PiecewiseLinearFunction() { | 20 function PiecewiseLinearFunction() { |
| 21 this.pieces = []; | 21 this.pieces = []; |
| 22 } | 22 } |
| 23 | 23 |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 get width() { | 134 get width() { |
| 135 return this.x2 - this.x1; | 135 return this.x2 - this.x1; |
| 136 } | 136 } |
| 137 }; | 137 }; |
| 138 | 138 |
| 139 return { | 139 return { |
| 140 PiecewiseLinearFunction, | 140 PiecewiseLinearFunction, |
| 141 }; | 141 }; |
| 142 }); | 142 }); |
| 143 </script> | 143 </script> |
| OLD | NEW |