Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(232)

Side by Side Diff: tracing/tracing/base/math/piecewise_linear_function.html

Issue 2771723003: [tracing] Move math utilities from base into their own subdirectory (attempt 2) (Closed)
Patch Set: rebase Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
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>
OLDNEW
« no previous file with comments | « tracing/tracing/base/math/math_test.html ('k') | tracing/tracing/base/math/piecewise_linear_function_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698