-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathapp_config.py
executable file
·95 lines (78 loc) · 2.02 KB
/
app_config.py
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
from os.path import dirname, join
import kivy
from kivy.config import Config
from kivy.resources import resource_add_path
kivy.require('1.0.6')
app_name = "MoSculp"
# Window size
Config.set('graphics', 'width', '1080')
Config.set('graphics', 'height', '720')
# Resource directories
app_dir = dirname(__file__)
resource_add_path(join(app_dir, 'cm-unicode-0.7.0'))
resource_add_path(join(app_dir, 'icons'))
results_dir = join(app_dir, 'results')
web_root = 'http://mosculp.csail.mit.edu/demo-ui-data'
tmp_root = '/tmp/mosculp_gui'
clips = ['Ballet-1', 'Ballet-2', 'Olympic', 'Cartwheel', 'Federer']
readable2real = {
'Ballet-1': 'ballet11-2',
'Ballet-2': 'ballet11-1',
'Olympic': 'olympicRunning_cut',
'Cartwheel': 'as-somersault',
'Federer': 'federer_cut',
}
real2readable = {v: k for k, v in readable2real.iteritems()}
body_parts = [
"Body",
"Left Upper Arm",
"Left Lower Arm",
"Right Upper Arm",
"Right Lower Arm",
"Left Upper Leg",
"Left Lower Leg",
"Right Upper Leg",
"Right Lower Leg",
]
possible_mats = [
"Leather",
"Tarp",
"Wood",
"Original",
]
part_mat = {k: possible_mats[0] for k in body_parts}
lights = [
"Left",
"Middle",
"Right",
]
params_default = {
'clip': 'ballet11-2',
'mode_3d': 'sculpture',
'body_parts': ["Right Lower Arm"],
'part_mat': part_mat,
'lights': lights,
'sculp_spec': True,
'artistic_bg': False,
'stickfig_density': 0,
'sculp_transp': 0,
}
myred = (0.52, 0.19, 0.29)
myblue = (0.087, 0.39, 0.52)
mypurple = (0.29, 0, 0.45)
mygreen = (0, 0.40, 0.36)
mylightgreen = (0.47, 0.88, 0)
mylime = (0.86, 0.93, 0.78)
myyellow = (0.46, 0.41, 0.14)
label_color = mylime + (1,)
button_color = myblue + (1,)
togglebutton_colors = {
'3D Model': myred + (1,),
'Rendering': myred + (1,),
'Sculpture Specularity: On': mygreen + (1,),
'Synthetic\nBackground: On': myyellow + (1,),
}
switchbutton_colors = {
'Mode: Sculpture': mypurple + (1,),
'Mode: Collection of Humans': myyellow + (1,),
}