Skip to content

Commit caa0429

Browse files
author
Mr. X
committed
change some defaults in example JS
1 parent 1c4ca4b commit caa0429

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

example/example.js

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
const LineGraph = new GPUjsRealRenderer.RealLineGraph({
22
canvasTag: 'line-canvas',
3-
dimensions: [1280, 720],
3+
dimensions: [420, 360],
44

5-
xScaleFactor: 10,
6-
yScaleFactor: 1,
5+
xScaleFactor: 20,
6+
yScaleFactor: 0.2,
77

88
bgColor: [0.2, 0.2, 0.2],
99
axesColor: [0.2, 1, 1],
@@ -15,11 +15,14 @@ const LineGraph = new GPUjsRealRenderer.RealLineGraph({
1515
yOffset: 10, // 10%
1616

1717
progressiveAxis: 'x', // x -> Graph moves along x-axis; y -> Graph moves along y-axis
18-
progressionMode: 'continous', // continous -> Axis always moves; overfloa -> Axis only moves when space for new data is inadequate;
18+
progressionMode: 'overflow', // continous -> Axis always moves; overfloa -> Axis only moves when space for new data is inadequate;
1919
progressInterval: 0.4, // Axis moves by one pixel every 0.4 internal time units (Only for continous type)
2020

21-
brushSize: 1, // The radius of one point of data, in coordinate units
22-
brushColor: [1, 0, 0] // Color of the brush
21+
brushSize: 0.1, // The radius of one point of data, in coordinate units
22+
brushColor: [1, 0, 0], // Color of the brush
23+
24+
lineThickness: 0.03, // Thickness of the line joining points
25+
lineColor: [0, 0, 1]
2326
})
2427

2528
LineGraph.draw();

0 commit comments

Comments
 (0)