Skip to content

rse/vmix-vptz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vMix-VPTZ

vMix Virtual PTZ Management

About

vMix-VPTZ is a client/server applications for the external management of the virtual pan/tilt/zoom (PTZ) settings of VirtualSet's in the video mixing application vMix. It has the following four distinct features:

  • Reset/Switch VPTZ: It allows you to reset the virtual PTZ set belonging to a physical PTZ once after vMix startup, and automatically switches to the individual virtual PTZ set belonging to a physical PTZ on every physical PTZ activation. For this, the physical PTZ activations have to be routed through vMix-VPTZ, which in turn activates the physical PTZ in vMix and updates all corresponding virtual PTZs. Rationale: This allows you to have (and activate) a true individual virtual PTZ per each physical PTZ.

  • Track Preview/Program: It tracks the program and preview for active VirtualSet inputs to know which virtual PTZ(s) are currently in preview. Rationale: This allows vMix-VPTZ to know to which VirtualSet a virtual PTZ adjustments is applied to.

  • Track VPTZ per PTZ: It tracks individual virtual PTZ settings of VirtualSet inputs per each physical PTZ of a camera input. This allows you to select a physical PTZ input of a camera and get a unique set of virtual PTZ settings in the corresponding VirtualSet inputs. For this, all virtual PTZ adjustments have to be routed through vMix-VPTZ, which records the virtual PTZ adjustments and routes them to vMix, too. Rationale: This allows you to have a true individual virtual PTZ per each physical PTZ.

  • Cutted Drive: It allows you to VPTZ-drive from VPTZ A (in preview) to VPTZ B (in program) via a Cut and a subsequent Drive operation like t = vptz(A), vptz(A, vptz(B)), cut(A), drive(A, t). In other words: it remembers the target virtual PTZ of A, sets A to the virtual PTZ of B, cuts A into program and then drives A to the remembered target virtual PTZ. Rationale: This allows the video mixing engineer to perform a (usually pre-configured or ad-hoc) live camera drive between to regular VirtualSet inputs.

  • Direct Drive: It allows you to VPTZ-drive from VPTZ A (in preview) to B (in program) via a direct Drive operation like drive(B, vptz(A)). In other words: it drives B to the virtual PTZ of A without any Cuts. Rationale: This allows the video mixing engineer to perform an ad-hoc camera drive for a regular VirtualSet input based on a preview-only "scratch" VirtualSet.

The application, written in TypeScript, consists of a central Node.js-based server component and a HTML5 Single-Page Application (SPA) as the client component.

Motivation

In case of a greenscreen-based production, you can combine vMix with Studio-Canvas and render the chroma-keyed background with the help of a game engine and synchronize its orientation with the physical PTZ information of your cameras. That works just fine. For more flexibility, you usually then also want to use multile virtual PTZ for each physical PTZ. This can be achieved with the help of VirtualSet inputs inside vMix. Unfortunately, vMix has very limited functionality to control the virtual PTZ information in a VirtualSet. This vMix-VPTZ application fixes the situation outside of vMix.

Scenario

Currently, the hard-coded scenario is to have the following distinct vMix input set:

  • 5 PTZ-type inputs (directly attached to the camera input), named PTZ - CAMx-W-V ("wide-virtual") (x = 1 ... 5), as the physical PTZ input.

  • 5x8 PTZ-type inputs (directly attached to the camera input), named PTZ - CAMx-W-V-y (x = 1...5, y = A...H), as inputs just holding pre-configured physical PTZ information for PTZ - CAMx-W-V.

  • 5x7 VirtualSet-type inputs (using the underlying PTZ - CAMx-W-V on top of dynamically rendered background canvas inputs), named VPTZ - CAMx-z (x = 1...5, z = C-L/C-C/C-R/F-L/F-C/F-R/W-C), as inputs for the virtual PTZ.

Usage (Production)

  • Under Windows/macOS/Linux install Node.js for the server run-time, Google Chrome for the client run-time, and vMix for the target application.

  • Install all dependencies:
    npm install --production

  • Run the production build-process once:
    npm start build

  • Run the bare server component:
    npm start server

  • Open the control client in Google Chrome:
    https://127.0.0.1:12345/

Usage (Development)

  • Under Windows/macOS/Linux install Node.js for the server run-time and Google Chrome for the client run-time, plus Visual Studio Code with its TypeScript, ESLint and VueJS extensions.

  • Install all dependencies:
    npm install

  • Run the development build-process once:
    npm start build-dev

  • Run the development build-process and server component continuously:
    npm start dev

  • Open the control client in Google Chrome:
    https://127.0.0.1:12345/

See Also

Copyright & License

Copyright © 2023-2024 Dr. Ralf S. Engelschall
Licensed under GPL 3.0