aboutsummaryrefslogtreecommitdiffstats
path: root/src/sketch.py
diff options
context:
space:
mode:
authorNao Pross <np@0hm.ch>2021-11-03 18:10:16 +0100
committerNao Pross <np@0hm.ch>2021-11-03 18:10:16 +0100
commitb7d133536ad885d792836601bec0eacd5a91659f (patch)
tree4ee64380c3a72a05c1880d0d72d8f4133f186d54 /src/sketch.py
parentUpdate workflow (diff)
downloadFading-b7d133536ad885d792836601bec0eacd5a91659f.tar.gz
Fading-b7d133536ad885d792836601bec0eacd5a91659f.zip
Delete demo.py and and comments to sketch.py
Diffstat (limited to 'src/sketch.py')
-rwxr-xr-x[-rw-r--r--]src/sketch.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/sketch.py b/src/sketch.py
index aa9d879..8118c5f 100644..100755
--- a/src/sketch.py
+++ b/src/sketch.py
@@ -1,12 +1,20 @@
+#!/usr/bin/env python3
+
from dearpygui.dearpygui import *
from dearpygui.demo import show_demo
+# Create GL context and initialize DearPyGUI
create_context()
create_viewport()
setup_dearpygui()
+# Show demo for dev
show_demo()
+
+#================================================
+# GUI Callback functions
+
def _on_params_close():
pass
@@ -19,6 +27,9 @@ def _on_rx_node_delink(sender, app_data):
link_id = app_data
delete_item(link_id)
+#================================================
+# Flow Graph Window
+
with window(label="RX DSP Flow Graph", width=800, height=800, on_close=_on_params_close, pos=(100,100), tag="rx_win"):
with node_editor(callback=_on_rx_node_link, delink_callback=_on_rx_node_delink):
with node(label="USRP Source", pos=(20,100)):
@@ -55,6 +66,8 @@ with window(label="RX DSP Flow Graph", width=800, height=800, on_close=_on_param
add_node_link(get_alias_id("eq_out"), get_alias_id("pll_in"))
+#================================================
+# Start window and main loop
show_viewport()
start_dearpygui()