setTother.tcl
4.24 KB
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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
#-------------------------Set Other Mode-------------------------------------------
set G_TT_NONE 0
set G_TT_RGBA16 2
set G_TT_IA16 3
set setTotherOptions {.setTotherDetailMB .setTotherTlutMB .setTotherTexFiltMB .setTotherConvertMB .setTotherPerspCB .setTotherLodCB .setTotherDoneB}
set setTotherEntries {.setTotherDetailL .setTotherTlutL .setTotherTexFiltL .setTotherConvertL}
for {set i 0} {$i < [llength $setTotherOptions]} {incr i 1} {
frame .setTotherFrame$i
}
label .setTotherL -text "setTother" -relief groove
checkbutton .setTotherPerspCB -text "texPersp" -variable setTotherPersp
set setTotherPersp 1
menubutton .setTotherDetailMB -width 10 -text "texCSD" -relief raised -menu .setTotherDetailMB.menu -bg LightGray -activebackground LightGray
menu .setTotherDetailMB.menu
.setTotherDetailMB.menu add radiobutton -label Clamp -command CsetTotherDetail -variable setTotherDetail -value 0
.setTotherDetailMB.menu add radiobutton -label Sharpen -command CsetTotherDetail -variable setTotherDetail -value 1
.setTotherDetailMB.menu add radiobutton -label Detail -command CsetTotherDetail -variable setTotherDetail -value 2
#set setTotherDetail 0
#set LsetTotherDetail Clamp
label .setTotherDetailL -width 9 -relief sunken -textvariable LsetTotherDetail
proc CsetTotherDetail {} {
global setTotherDetail
global LsetTotherDetail
switch $setTotherDetail {
0 {set LsetTotherDetail Clamp}
1 {set LsetTotherDetail Sharpen}
2 {set LsetTotherDetail Detail}
}
}
checkbutton .setTotherLodCB -text "texLOD" -variable setTotherLOD
set setTotherLOD 0
menubutton .setTotherTlutMB -width 10 -text "texTLUT" -relief raised -menu .setTotherTlutMB.menu -bg LightGray -activebackground LightGray
menu .setTotherTlutMB.menu
.setTotherTlutMB.menu add radiobutton -label None -command CsetTotherTlut -variable setTotherTlut -value 0
.setTotherTlutMB.menu add radiobutton -label RGBA16 -command CsetTotherTlut -variable setTotherTlut -value 2
.setTotherTlutMB.menu add radiobutton -label IA16 -command CsetTotherTlut -variable setTotherTlut -value 3
#set setTotherTlut $G_TT_NONE
#set LsetTotherTlut None
label .setTotherTlutL -width 9 -relief sunken -textvariable LsetTotherTlut
proc CsetTotherTlut {} {
global setTotherTlut
global LsetTotherTlut
switch $setTotherTlut {
0 {set LsetTotherTlut None }
2 {set LsetTotherTlut RGBA16 }
3 {set LsetTotherTlut IA16 }
}
}
menubutton .setTotherTexFiltMB -width 10 -text "texFilt" -relief raised -menu .setTotherTexFiltMB.menu -bg LightGray -activebackground LightGray
menu .setTotherTexFiltMB.menu
.setTotherTexFiltMB.menu add radiobutton -label Bilerp -command CsetTotherTexFilt -variable setTotherTexFilt -value 2
.setTotherTexFiltMB.menu add radiobutton -label Average -command CsetTotherTexFilt -variable setTotherTexFilt -value 3
.setTotherTexFiltMB.menu add radiobutton -label Point -command CsetTotherTexFilt -variable setTotherTexFilt -value 0
#set setTotherTexFilt 2
#set LsetTotherTexFilt Bilerp
label .setTotherTexFiltL -width 9 -relief sunken -textvariable LsetTotherTexFilt
proc CsetTotherTexFilt {} {
global setTotherTexFilt
global LsetTotherTexFilt
switch $setTotherTexFilt {
2 {set LsetTotherTexFilt Bilerp}
3 {set LsetTotherTexFilt Average}
0 {set LsetTotherTexFilt Point }
}
}
menubutton .setTotherConvertMB -width 10 -text "texConvert" -relief raised -menu .setTotherConvertMB.menu -bg LightGray -activebackground LightGray
menu .setTotherConvertMB.menu
.setTotherConvertMB.menu add radiobutton -label Filt -command CsetTotherConvert -variable setTotherConvert -value 6
.setTotherConvertMB.menu add radiobutton -label FiltConv -command CsetTotherConvert -variable setTotherConvert -value 5
.setTotherConvertMB.menu add radiobutton -label Conv -command CsetTotherConvert -variable setTotherConvert -value 0
#set setTotherConvert 6
#set LsetTotherConvert Filt
label .setTotherConvertL -width 9 -relief sunken -textvariable LsetTotherConvert
proc CsetTotherConvert {} {
global setTotherConvert
global LsetTotherConvert
switch $setTotherConvert {
6 {set LsetTotherConvert Filt}
5 {set LsetTotherConvert FiltConv}
0 {set LsetTotherConvert Conv}
}
}
button .setTotherDoneB -command setTother -text "done"