aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/lua/paths_agg.lua
blob: deb212e7d6d9bf442af8490832323474d1f892fa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41

clips = 0
draws = 0
clipPaths = 0
drawPaths = 0
swClipPaths = 0
swDrawPaths = 0

skpsTotal = 0
skpsWithPath = 0
skpsWithSWPath = 0

dofile("/tmp/lua-output")

io.write("Number of clips: ", clips, "\n");
io.write("Number of draws: ", draws, "\n");
io.write("Number of clipped paths: ", clipPaths, "\n");
io.write("Number of drawn paths: ", drawPaths, "\n");
io.write("Number of clipped software paths: ", swClipPaths, "\n");
io.write("Number of drawn software paths: ", swDrawPaths, "\n");

io.write("\n")

io.write("Number of SKPs total: ", skpsTotal, "\n")
io.write("Number of SKPs that draw paths: ", skpsWithPath, "\n")
io.write("Number of SKPs that draw SW paths: ", skpsWithSWPath, "\n")

io.write("\n")
io.write("\n")

totalSWPaths = swDrawPaths + swClipPaths
totalPaths = drawPaths + clipPaths

io.write("Percentage of paths needing software: ", (100*(totalSWPaths / totalPaths)), "\n")
io.write("Percentage of draws/clips needing software: ",
         (100*(totalSWPaths / (draws + clips))), "\n")

io.write("\n")

io.write("Percentage of SKPs that draw paths: ", (100*(skpsWithPath / skpsTotal)), "\n")
io.write("Percentage of SKPs that draw SW paths: ", (100*(skpsWithSWPath / skpsTotal)), "\n")