Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions native/intuitives_daw/intlib/ipc/daw.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,3 +226,14 @@

def save_audio_inputs(self):
self.send_configure("ai", "")

def text_to_melody(self, a_uid, a_text):

Check notice on line 230 in native/intuitives_daw/intlib/ipc/daw.py

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

native/intuitives_daw/intlib/ipc/daw.py#L230

Missing function or method docstring
self.send_configure(
"tm",
"|".join(
str(x) for x in (
a_uid,
a_text,
)
),
)
11 changes: 10 additions & 1 deletion native/intuitives_daw/intui/widgets/generators.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
COLOR_TERTIARY,
CHROMA_COLORS,
)
from intlib import constants
from intui.daw import shared as daw_shared


class GeneratorPanel(QWidget):
Expand Down Expand Up @@ -284,7 +286,14 @@ def on_generate_text(self):
if not text.strip():
text = "Intuitives"
print(f"📝 Converting text to melody: '{text[:20]}...'")
# TODO: Call engine IPC

if daw_shared.CURRENT_ITEM is None:
print("⚠️ No item selected. Open an item in the sequencer first.")
return

if constants.DAW_IPC:
constants.DAW_IPC.text_to_melody(daw_shared.CURRENT_ITEM.uid, text)

self.melody_generated.emit([])

def on_color_selected(self, color, note_index):
Expand Down