Skip to content

Commit fa5144b

Browse files
committed
Make channel colour optional
1 parent 8ee6a30 commit fa5144b

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ Options:
3030
* `channels`, an array of objects, where:
3131
* `name` is the channel name, displayed on screen
3232
* `file` is a path name to the audio file, and
33-
* `colour` contains the Red, Green, and Blue colour values (0-255).
33+
* `colour` (optional) - contains the Red, Green, and Blue colour values
34+
(0-255). Defaults to black, ie. `[0, 0, 0]`
3435
* `video_file_out` is a path name to the video that will be output.
3536

3637
```json

src/data/song.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ use symphonia::core::{
1818
pub struct Channel {
1919
pub name: String,
2020
pub file: String,
21+
22+
/// Colour is optional, and will default to black, ie. [0,0,0]
23+
#[serde(default)]
2124
pub colour: RGB,
2225

2326
#[serde(skip)]

0 commit comments

Comments
 (0)