-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vmdrc
51 lines (45 loc) · 1.67 KB
/
.vmdrc
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
# Desaturated colors
color change rgb 0 0.1 0.2 0.7 ;# blue
color change rgb 1 0.7 0.2 0.1 ;# red
color change rgb 3 0.7 0.4 0.0 ;# orange
color change rgb 4 0.8 0.7 0.1 ;# yellow
color change rgb 7 0.1 0.7 0.2 ;# green
#color change rgb 10 0.1 0.7 0.8 ;# cyan
color change rgb 11 0.6 0.1 0.6 ;# purple
# New shortcuts for display options
user add key o {display projection orthographic} ;
user add key p {display projection perspective} ;
user add key d { if {[display get rendermode] != "Normal" } {display rendermode Normal} {display rendermode GLSL}} ;
user add key D { if {[display get depthcue] != "on" } {display depthcue on} {display depthcue off}} ;
# Predefined color schemas
user add key v { color Display {Background} white; color Axes {Labels} black; } ;
user add key b { color Display {Background} black; color Axes {Labels} white; } ;
# Saving views
proc save_viewpoint {} {
global viewpoints
if [info exists viewpoints] {unset viewpoints}
# get the current matricies
foreach mol [molinfo list] {
set viewpoints($mol) [molinfo $mol get {center_matrix rotate_matrix scale_matrix global_matrix}]
}
}
proc restore_viewpoint {} {
global viewpoints
foreach mol [molinfo list] {
puts "Trying $mol"
if [info exists viewpoints($mol)] {
molinfo $mol set {center_matrix rotate_matrix scale_matrix global_matrix} $viewpoints($mol)
}
}
}
user add key q "save_viewpoint"
user add key w "restore_viewpoint"
# Open windows
menu main on ;
menu graphics on ;
# set up sensible default display options
mol default material Diffuse ;
display rendermode GLSL ;
display projection orthographic ;
display nearclip set 0 ; # Why should it be > 0?
animate style once ;