Skip to content

Commit

Permalink
Feat: v26 15 Mix support
Browse files Browse the repository at this point in the history
  • Loading branch information
thedist committed Oct 28, 2022
1 parent ed4a875 commit ab58692
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 35 deletions.
13 changes: 12 additions & 1 deletion src/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -961,7 +961,7 @@ interface CommandCallback {
interface MixSelectCallback {
action: 'mixSelect'
options: Readonly<{
mix: 0 | 1 | 2 | 3
mix: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14
}>
}

Expand Down Expand Up @@ -3106,6 +3106,17 @@ export function getActions(instance: VMixInstance): VMixActions {
{ id: 1, label: '2' },
{ id: 2, label: '3' },
{ id: 3, label: '4' },
{ id: 4, label: '5' },
{ id: 5, label: '6' },
{ id: 6, label: '7' },
{ id: 7, label: '8' },
{ id: 8, label: '9' },
{ id: 9, label: '10' },
{ id: 10, label: '1' },
{ id: 11, label: '12' },
{ id: 12, label: '13' },
{ id: 13, label: '14' },
{ id: 14, label: '15' },
],
},
],
Expand Down
41 changes: 9 additions & 32 deletions src/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ export interface VMixData {
inputs: Input[]
overlays: Overlay[]
transitions: Transition[]
mix: [Mix, Mix, Mix, Mix]
mix: Mix[]
audio: AudioBus[]
status: Status
recording: Recording
Expand Down Expand Up @@ -208,7 +208,7 @@ export class VMixData {
inputs: Input[]
overlays: Overlay[]
transitions: Transition[]
mix: [Mix, Mix, Mix, Mix]
mix: Mix[]
audio: AudioBus[]
status: Status
recording: Recording
Expand All @@ -226,40 +226,17 @@ export class VMixData {
this.inputs = []
this.overlays = []
this.transitions = []
this.mix = [
{
number: 1,
active: true,
this.mix = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15].map((mixNumber) => {
return {
number: mixNumber,
active: mixNumber === 1,
preview: 0,
program: 0,
previewTally: [],
programTally: [],
},
{
number: 2,
active: false,
preview: 0,
program: 0,
previewTally: [],
programTally: [],
},
{
number: 3,
active: false,
preview: 0,
program: 0,
previewTally: [],
programTally: [],
},
{
number: 4,
active: false,
preview: 0,
program: 0,
previewTally: [],
programTally: [],
},
]
}
})

this.audio = []
this.status = {
fadeToBlack: false,
Expand Down
13 changes: 12 additions & 1 deletion src/feedback.ts
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ interface InputOnMultiviewCallback {
interface MixSelectCallback {
type: 'mixSelect'
options: Readonly<{
mix: 0 | 1 | 2 | 3
mix: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14
fg: number
bg: number
}>
Expand Down Expand Up @@ -1617,6 +1617,17 @@ export function getFeedbacks(instance: VMixInstance): VMixFeedbacks {
{ id: 1, label: '2' },
{ id: 2, label: '3' },
{ id: 3, label: '4' },
{ id: 4, label: '5' },
{ id: 5, label: '6' },
{ id: 6, label: '7' },
{ id: 7, label: '8' },
{ id: 8, label: '9' },
{ id: 9, label: '10' },
{ id: 10, label: '11' },
{ id: 11, label: '12' },
{ id: 12, label: '13' },
{ id: 13, label: '14' },
{ id: 14, label: '15' },
],
},
options.foregroundColor,
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ interface RoutingData {
destinationInput: null | string
destinationLayer: null | string
}
mix: 0 | 1 | 2 | 3
mix: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14
}

/**
Expand Down
11 changes: 11 additions & 0 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,17 @@ export const options: Options = {
{ id: 1, label: '2' },
{ id: 2, label: '3' },
{ id: 3, label: '4' },
{ id: 4, label: '5' },
{ id: 5, label: '6' },
{ id: 6, label: '7' },
{ id: 7, label: '8' },
{ id: 8, label: '9' },
{ id: 9, label: '10' },
{ id: 10, label: '11' },
{ id: 11, label: '12' },
{ id: 12, label: '13' },
{ id: 13, label: '14' },
{ id: 14, label: '15' },
{ id: -1, label: 'Selected' },
],
},
Expand Down

0 comments on commit ab58692

Please sign in to comment.