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
80 changes: 47 additions & 33 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,14 @@ bevy = { git = "https://github.com/bevyengine/bevy", branch = "main" }
processing = { path = "." }
processing_pyo3 = { path = "crates/processing_pyo3" }
processing_render = { path = "crates/processing_render" }
processing_midi = { path = "crates/processing_midi" }

[dependencies]
bevy = { workspace = true }
processing_render = { workspace = true }
processing_midi = { workspace = true }

[dev-dependencies]
glfw = "0.60.0"
rand = "0.10.0"

[target.'cfg(target_os = "linux")'.dev-dependencies]
glfw = { version = "0.60.0", features = ["wayland"] }
Expand Down
12 changes: 0 additions & 12 deletions crates/processing_midi/Cargo.toml

This file was deleted.

25 changes: 0 additions & 25 deletions crates/processing_midi/src/lib.rs

This file was deleted.

26 changes: 26 additions & 0 deletions crates/processing_pyo3/examples/midi.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
from processing import *
import random

def setup():
size(800, 600)

# Refresh midi port list, and connect to first one
midi_refresh_ports()
midi_connect(0)

def draw():
background(220)

fill(255, 0, 100)
stroke(1)
stroke_weight(2)
rect(100, 100, 200, 150)

# pick a random note value, and duration value for that note
# then send the midi command
note = random.randint(57,68)
note_duration = random.randint(25, 250)
midi_play_notes(note, note_duration)

# TODO: this should happen implicitly on module load somehow
run()
Loading
Loading