From 0e13dabf71ce1e4fc15d310a5e9eb5a05f068b3a Mon Sep 17 00:00:00 2001 From: itten Date: Tue, 14 Jul 2026 19:55:54 +0300 Subject: [PATCH] 2110-20 Rx --- src/components/NodePalette.vue | 3 ++- src/components/nodes/StudioNode.vue | 9 ++++++++- src/nodeTypes.ts | 28 +++++++++++++++++++++++++++- src/types.ts | 2 +- 4 files changed, 38 insertions(+), 4 deletions(-) diff --git a/src/components/NodePalette.vue b/src/components/NodePalette.vue index 7f2980b..bd8e2a3 100644 --- a/src/components/NodePalette.vue +++ b/src/components/NodePalette.vue @@ -11,7 +11,7 @@ interface PaletteGroup { } const groups: PaletteGroup[] = [ - { label: 'SOURCES', types: ['testpattern', 'ndiin', 'decklinkin', 'videoin'] }, + { label: 'SOURCES', types: ['testpattern', 'ndiin', 'decklinkin', 'videoin', '2110'] }, { label: 'PROCESS', types: ['mix', 'pip', 'gaindb'] }, { label: 'SINKS', types: ['ndiout', 'decklinkout', 'fakesink'] }, ] @@ -27,6 +27,7 @@ const iconMap: Record = { mix: '⊕', pip: '⊞', gaindb: '◎', + 2110: '◬', } function onDragStart(event: DragEvent, nodeType: string) { diff --git a/src/components/nodes/StudioNode.vue b/src/components/nodes/StudioNode.vue index 3426dad..761abbc 100644 --- a/src/components/nodes/StudioNode.vue +++ b/src/components/nodes/StudioNode.vue @@ -129,6 +129,13 @@ function onDeleteNode() { {{ opt.label }} + = { { id: 'audio-out', kind: 'audio', direction: 'out' }, ], params: [ - { key: 'file', label: 'File', type: 'input', default: '0.ts' } + { key: 'file', label: 'File', type: 'file', default: '0.ts' } ], }, mix: { @@ -183,6 +192,23 @@ export const NODE_TYPES: Record = { { key: 'gain_db', label: 'Gain (dB)', type: 'number', default: 0, min: -60, max: 20 }, ], }, + 2110: { + type: '2110', + label: 'SMPTE 2110-20 Rx', + ports: [ + { id: 'video-out', kind: 'video', direction: 'out' }, + ], + params: [ + { key: 'interface', label: 'NIC', type: 'select', options: NIC_OPTIONS, default: "eno1np0", group: 'NETWORK' }, + { key: 'local_ip', label: 'NIC IP', type: 'input', default: "192.168.0.3", group: 'NETWORK' }, + { key: 'source_ip', label: 'Src IP', type: 'input', default: "192.168.0.2", group: 'NETWORK' }, + { key: 'mcast_ip', label: 'Mcast IP', type: 'input', default: "239.255.197.181", group: 'NETWORK' }, + { key: 'udp_port', label: 'UDP Port', type: 'number', default: 16388, min: 1, max: 65536, group: 'NETWORK' }, + { key: 'payload_type', label: 'Payload Type', type: 'number', default: 96, min: 1, max: 255, group: 'VIDEO' }, + { key: 'res', label: 'Resolution', type: 'select', options: RESOLUTION_OPTIONS, default: '1920x1080', group: 'VIDEO' }, + { key: 'fps', label: 'FPS', type: 'select', options: FPS_OPTIONS, default: '25', group: 'VIDEO' }, + ] + } } // Default params for a new node of the given type diff --git a/src/types.ts b/src/types.ts index 5b5c491..4817a6b 100644 --- a/src/types.ts +++ b/src/types.ts @@ -10,7 +10,7 @@ export interface PortDef { export interface ParamDef { key: string label: string - type: 'select' | 'number' | 'input' + type: 'select' | 'number' | 'file' | 'input' options?: { label: string; value: string | number }[] default: string | number min?: number