-
Notifications
You must be signed in to change notification settings - Fork 45
/
Copy pathtest.lua
45 lines (39 loc) · 959 Bytes
/
test.lua
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
42
43
44
45
do
local f = io.open("test.txt", "wt")
local function fw(str)
f:write(str.."\n")
end
--fw("-noui")
fw("-benchmarkframes 4")
fw("-vsync 0")
fw("-culling 1")
local drawmodes = 4
local results = 3
local methods = 3
-- functional
for m=0,methods-1 do
for d=0,drawmodes-1 do
for r=0,results-1 do
fw("-animateoffset "..(m*methods+d*drawmodes+r*results))
fw("-method "..m)
fw("-drawmode "..d)
fw("-result "..r)
fw('benchmark "m'..m.."d"..d.."r"..r..'"')
fw('-screenshot "test_m'..m.."d"..d.."r"..r..'.bmp"')
end
end
end
fw("-animateoffset 0")
fw("-method 2")
fw("-result 2")
-- permutation of drawmodes
for from=0,drawmodes-1 do
for to=0,drawmodes-1 do
fw("-drawmode "..from)
fw('benchmark "a_fd'..from.."td"..to..'"')
fw("-drawmode "..to)
fw('benchmark "b_fd'..from.."td"..to..'"')
end
end
f:close()
end