Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/Waves.activity/waves.py
diff options
context:
space:
mode:
Diffstat (limited to 'Waves.activity/waves.py')
-rw-r--r--Waves.activity/waves.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/Waves.activity/waves.py b/Waves.activity/waves.py
new file mode 100644
index 0000000..15b0307
--- /dev/null
+++ b/Waves.activity/waves.py
@@ -0,0 +1,28 @@
+import csndsugui
+from sugar.activity import activity
+
+
+class Waves(activity.Activity):
+
+ def __init__(self, handle):
+
+ activity.Activity.__init__(self, handle)
+
+
+ # colours
+ red = (0xFFFF,0,0)
+ bg = (0xF000, 0xFF00, 0xFFFF)
+ win = csndsugui.CsoundGUI(self,bg)
+
+ win.csd("waves.csd")
+ txt = win.text("Making Waves")
+ sfbox = win.box(False)
+ bfbox = win.box(False)
+ sbox = win.framebox("frequencies", False, sfbox, red, 40)
+ bbox = win.framebox("oscillators", False, bfbox, red, 40)
+
+ win.buttonbank(8,bbox)
+ win.spin(0,0,10,0.5,1,bbox,0, "main_volume")
+ win.vsliderbank(8,400.0,400.0,500.0,80,200,sbox)
+
+ win.play()