Skip to content

Commit 9f7ee89

Browse files
committed
Merge branch 'main' into development
2 parents 28b86d1 + 53215b8 commit 9f7ee89

31 files changed

Lines changed: 5431 additions & 1467 deletions

.github/workflows/release.yml

Lines changed: 147 additions & 70 deletions
Large diffs are not rendered by default.

Cargo.lock

Lines changed: 1590 additions & 517 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 9 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
[package]
22
name = "tether-artnet-controller"
3-
version = "0.2.0"
3+
version = "0.8.4"
44
edition = "2021"
55
repository = "https://github.com/RandomStudio/tether-artnet-controller"
6+
homepage = "https://github.com/RandomStudio/tether-artnet-controller"
67
authors = ["Stephen Buchanan"]
7-
description= "A remote control software lighting desk"
8+
description = "A remote control software lighting desk"
9+
license = "MIT"
810

911
[package.metadata.wix]
1012
upgrade-guid = "8E5F37FF-2FE0-464D-B307-5F64A0466ACF"
@@ -15,7 +17,7 @@ eula = false
1517
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
1618

1719
[dependencies]
18-
tether-agent = "0.12.1"
20+
tether-agent = "0.14"
1921
artnet_protocol = "0.4.1"
2022
tween = "2.0.0"
2123
rand = "0.8.5"
@@ -25,27 +27,14 @@ log = "0.4.18"
2527
serde = { version = "1.0", features = ["derive"] }
2628
serde_json = "1.0.91"
2729
rmp-serde = "1.1.1"
28-
eframe = "0.22.0"
29-
egui = { version = "0.22.0", features = ["persistence"] }
30+
egui = { version = "0.26.2", features = ["persistence"] }
3031
anyhow = "1.0.75"
3132
rfd = "0.12.1"
33+
eframe = "0.26.2"
34+
ctrlc = "3.4.2"
35+
indexmap = { version = "2.2.5", features = ["serde"] }
3236

3337
# The profile that 'cargo dist' will build with
3438
[profile.dist]
3539
inherits = "release"
3640
lto = "thin"
37-
38-
# Config for 'cargo dist'
39-
[workspace.metadata.dist]
40-
# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax)
41-
cargo-dist-version = "0.8.0"
42-
# CI backends to support
43-
ci = ["github"]
44-
# The installers to generate for each app
45-
installers = ["shell", "msi"]
46-
# Target platforms to build apps for (Rust target-triple syntax)
47-
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu", "x86_64-pc-windows-msvc"]
48-
# Publish jobs to run in CI
49-
pr-run-mode = "plan"
50-
51-

README.md

Lines changed: 42 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,51 @@
11
# Tether ArtNet Controller
22

3-
A reasonably generic ArtNet control system with the following features:
4-
- Software-based "Lighting Desk" for manually manipulating light fixtures
5-
- Controllable via a MIDI controller
6-
- Controllable via Tether "remote commands" including animations
3+
Sometimes you don't need pixel-mapping, you just need to control some DMX fixtures. **This application works like a lighting desk, but better.**
4+
5+
Runs on Mac, Linux and even Windows.
6+
7+
![screenshot](./screenshot.png)
8+
9+
This application lets you achieve the following:
10+
11+
- fiddle with some sliders to figure out what each channel is doing, without even needing to set up "fixtures" or "mapping" first
12+
- set up a Project with Fixtures, complete with easy-to-access documentation about what each channel does
13+
- define Macros which are labelled shortcuts to the channel(s) you care about most for each kind of Fixture
14+
- set up Scenes which apply Macros to the entire system, either immediately or over time (animated transition)
15+
16+
In addition, the main features above (Macros, Scenes, Animations) can be controlled in multiple ways:
17+
18+
- using a friendly GUI interface
19+
- using a MIDI controller
20+
- using Tether messaging
21+
22+
Use this application for your lighting design in GUI mode, then run with `--headless` to launch as a server which can be controlled remotely via third-party applications. Nice!
723

824
## CLI
925

26+
Get all the available options by appending `--help`
27+
1028
Example: start with connected interface:
29+
1130
```
12-
cargo run --release -- --artnet.interface 10.0.0.100 --artnet.destination 10.0.0.99
31+
tether-artnet-controller myproject.json --artnet.interface 10.0.0.100 --artnet.destination 10.0.0.99
1332
```
1433

1534
Example: start with local testing for ArtnetView:
35+
1636
```
17-
cargo run -- --artnet.interface 10.112.10.187 --artnet.destination 10.112.10.187 --loglevel debug
37+
tether-artnet-controller --artnet.interface 10.112.10.187 --artnet.destination 10.112.10.187 --loglevel debug
1838
```
1939

20-
## Remote control
40+
## Test Tether control using Tether Egui
41+
2142
If you have Tether Egui installed (`cargo install tether-egui`) then the easiest way to test Tether remote control is to launch Tether Egui with the example project file included, i.e.:
2243
`tether-egui tether-egui-testing.json`
2344

45+
---
46+
2447
## TODO
48+
2549
- [x] Add labels for which channels are already "taken"/assigned in master slider list
2650
- [x] Add indications of "range values" for channels where this applies (under fixture section)
2751
- [x] Allow macros to be (temporarily) disabled so Fixture>Mapping values can be adjusted directly without being overridden
@@ -32,9 +56,15 @@ If you have Tether Egui installed (`cargo install tether-egui`) then the easiest
3256
- [x] Provide simple/advanced views (e.g. "macros only" vs "the kitchen sink")
3357
- [x] Scenes should be triggered by Tether messages
3458
- [x] Hit a button to save the current state of all macros to a new Scene
35-
- [ ] Project JSON should save ArtNet configuration (but can override via CLI args)
36-
- [ ] Colour conversions should be possible manually, e.g. RGB -> CMY
37-
- [ ] With macros, add some visual indicators of state, e.g. Colour, Brightness and Pan/Tilt
38-
- [ ] At the moment, macros simply get "inactive" when something further downstream is applied (fixture controls, individual channels); it would be nice to propagate any live changes applied back "up" to the macro values as well.
39-
- [ ] Add 16-bit control, at least for macros (single slider adjusts the two channels as split between first and second 8-bit digits)
59+
- [x] Project JSON should save ArtNet configuration (but can override via CLI args)
60+
- [x] Colour conversions should be possible manually, e.g. RGB -> CMY
61+
- [x] With macros, add some visual indicators of state, e.g. Colour, Brightness and Pan/Tilt
62+
- [x] Allow the app to launch just fine without Tether
63+
- [x] If no ArtNet provided in Project (and no settings provided from CLI), then do NOT connect, but allow editing / manual connect
64+
- [x] Allow Tether settings to be saved with project as well
65+
- [ ] Add amber Macros for some fixtures (and include these in scenes)
66+
- [ ] Keep project files sorted, e.g. by fixtures
67+
- [x] Allow the app to launch without any project file at all
68+
- [x] Add 16-bit control, at least for macros (single slider adjusts the two channels as split between first and second 8-bit digits)
4069
- [ ] ArtNet on separate thread, with more precise timing; this might require some messaging back and forth and/or mutex
70+
- [ ] It should be possible to add Macros from "Advanced Mode" into the available macros for the fixtures (and therefore the scenes). This would be part of a fixture-editing UI?

build.rs

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
use std::{
2+
fs::{self, File},
3+
io::{self, Write},
4+
};
5+
6+
fn main() {
7+
println!("cargo:rerun-if-changed=src/project.rs");
8+
9+
let entries = fs::read_dir("./fixtures")
10+
.expect("failed to list fixture files")
11+
.map(|res| res.map(|x| x.path()))
12+
.collect::<Result<Vec<_>, io::Error>>()
13+
.unwrap();
14+
15+
let mut entire_string = String::new();
16+
entire_string.push_str("[\n");
17+
18+
for (index, fixture_path) in entries.iter().enumerate() {
19+
println!("Fixture file: {:?}", fixture_path);
20+
if fixture_path.is_file() {
21+
match fs::read_to_string(fixture_path) {
22+
Ok(d) => {
23+
entire_string.push_str(&d);
24+
if index < (entries.len() - 1) {
25+
entire_string.push(',');
26+
}
27+
}
28+
Err(e) => {
29+
panic!(
30+
"Something went wrong reading the contents of the fixture file: {}",
31+
e
32+
);
33+
}
34+
}
35+
}
36+
}
37+
38+
entire_string.push_str("\n]");
39+
40+
let mut f = File::create("src/all_fixtures.json").expect("failed to create output file");
41+
f.write_all(entire_string.as_bytes())
42+
.expect("failed to write");
43+
}

dist-workspace.toml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[workspace]
2+
members = ["cargo:."]
3+
4+
# Config for 'dist'
5+
[dist]
6+
# The preferred dist version to use in CI (Cargo.toml SemVer syntax)
7+
cargo-dist-version = "0.27.0"
8+
# CI backends to support
9+
ci = "github"
10+
# The installers to generate for each app
11+
installers = ["homebrew", "msi"]
12+
# A GitHub repo to push Homebrew formulas to
13+
tap = "RandomStudio/homebrew-tap"
14+
# Target platforms to build apps for (Rust target-triple syntax)
15+
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu", "x86_64-pc-windows-msvc"]
16+
# Publish jobs to run in CI
17+
publish-jobs = ["homebrew"]
18+
19+
[dist.dependencies.apt]
20+
libgtk-3-dev = "*"

0 commit comments

Comments
 (0)