From a19a216bc60160c162e616145ef091dd18ce4e61 Mon Sep 17 00:00:00 2001 From: Skip Montanaro Date: Tue, 16 Feb 2021 14:40:46 -0600 Subject: Python 0.9.1 as posted in alt.sources --- demo/sgi/gl_panel/flying/objdict.py | 41 +++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 demo/sgi/gl_panel/flying/objdict.py (limited to 'demo/sgi/gl_panel/flying/objdict.py') diff --git a/demo/sgi/gl_panel/flying/objdict.py b/demo/sgi/gl_panel/flying/objdict.py new file mode 100644 index 0000000..a5d5371 --- /dev/null +++ b/demo/sgi/gl_panel/flying/objdict.py @@ -0,0 +1,41 @@ + +from data import * + +# +#the color light-blue +# +LightBlue = lightblue + +# the 'object' dictionary contains the strings of the menu items +# that denote the objects +objects = {} + +# object dictionary initialization +objects['sphere'] = [ZERO, o1] +objects['cylinder'] = [ZERO, o2] +objects['cube'] = [ONE, o3] +objects['icecream'] = [ZERO, o4] +objects['disk'] = [ZERO, o5] +objects['diamond'] = [ZERO, o6] +#objects['glass'] = [ZERO] +objects['pyramid'] = [ZERO, o7] +objects['table'] = [ZERO, o8] + +# 'putDict' sets the value of entry 'key' of dictionary 'dict' +def putDict(dict, key, val) : + dict[key][0] = val + +# +# 'getDict' get the contents of entry i of key 'key' +# of dictionary 'dict' +# +def getDict(dict, key, i) : + return dict[key][i] + +# the 'options' dictionary contains the strings of the menu items +# that denote the options +options = {} + +# option dictionary initialization +options['wire'] = [ZERO] +options['filled'] = [ONE] -- cgit v1.2.3