Esempio n. 1
0
 void IBMDSwitcherCallback.Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
 {
     if (eventType == _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected)
     {
         SwitcherDisconnected?.Invoke(this, null);
     }
 }
Esempio n. 2
0
        public int GetVideoHeight()
        {
            this.Connect();
            _BMDSwitcherVideoMode videoMode;

            this.switcher.GetVideoMode(out videoMode);
            _BMDSwitcherVideoMode switcherVideoMode = videoMode;

            switch (switcherVideoMode)
            {
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode4KHDp2398:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode4KHDp24:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode4KHDp25:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode4KHDp2997:
                return(2160);

            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode720p50:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode720p5994:
                return(720);

            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080i50:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080i5994:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p50:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p2398:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p24:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p25:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p2997:
            case _BMDSwitcherVideoMode.bmdSwitcherVideoMode1080p5994:
                return(1080);

            default:
                throw new SwitcherLibException(String.Format("Unsupported resolution: {0}", videoMode.ToString()));
            }
        }
Esempio n. 3
0
 public void Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
 {
     switch (eventType)
     {
     case _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected:
         SwitcherDisconnected?.Invoke(Switcher, this);
         break;
     }
 }
Esempio n. 4
0
 void IBMDSwitcherCallback.Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
 {
     if (eventType == _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected)
     {
         if (SwitcherDisconnected != null)
         {
             SwitcherDisconnected();
         }
     }
 }
        public void Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
        {
            switch (eventType)
            {
            case _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected:
                _mediator.Publish(new ConnectionChangeNotify {
                    Connected = false
                });
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeTimeCodeChanged:
                break;

            default:
                _mediator.Publish(new SwitcherMessageNotify {
                    Message = $"Switcher says: {eventType}"
                });
                break;
            }
        }
Esempio n. 6
0
        void IBMDSwitcherCallback.Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
        {
            this._switcherEventArgs = new SwitcherEventArgs();
            switch (eventType)
            {
            case _BMDSwitcherEventType.bmdSwitcherEventType3GSDIOutputLevelChanged:
                this.SwitcherEventType3GSDIOutputLevelChanged?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected:
                this._switcherEventArgs = new SwitcherEventArgs {
                    _coreVideoMode = coreVideoMode
                };
                this.SwitcherEventTypeDisconnected?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeDownConvertedHDVideoModeChanged:
                this.SwitcherEventTypeDownConvertedHDVideoModeChanged?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeMethodForDownConvertedSDChanged:
                this.SwitcherEventTypeMethodForDownConvertedSDChanged?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeMultiViewVideoModeChanged:
                this.SwitcherEventTypeMultiViewVideoModeChanged?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypePowerStatusChanged:
                this.SwitcherEventTypePowerStatusChanged?.Invoke(this, this._switcherEventArgs);
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeVideoModeChanged:
                this.SwitcherEventTypeVideoModeChanged?.Invoke(this, this._switcherEventArgs);
                break;
            }
        }
Esempio n. 7
0
        public void Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
        {
            switch (eventType)
            {
            case _BMDSwitcherEventType.bmdSwitcherEventTypeVideoModeChanged:
                VideoModeChangedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeMethodForDownConvertedSDChanged:
                MethodForDownConvertedSDChangedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeDownConvertedHDVideoModeChanged:
                DownConvertedHDVideoModeChangedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeMultiViewVideoModeChanged:
                MultiViewVideoModeChangedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypePowerStatusChanged:
                PowerStatusChangedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventTypeDisconnected:
                DisconnectedEvent?.Invoke(this, new EventArgs());
                break;

            case _BMDSwitcherEventType.bmdSwitcherEventType3GSDIOutputLevelChanged:
                SDI3GOutputLevelChangedEvent?.Invoke(this, new EventArgs());
                break;

            default:
                break;
            }
        }
Esempio n. 8
0
 public void Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
 {
     throw new NotImplementedException();
 }
Esempio n. 9
0
 public void Notify(_BMDSwitcherEventType eventType, _BMDSwitcherVideoMode coreVideoMode)
 {
     Notify(eventType);
 }
Esempio n. 10
0
 public _BMDSwitcherVideoMode GetMultiViewVideoMode(_BMDSwitcherVideoMode coreVideMode)
 {
     this.Switcher.GetMultiViewVideoMode(coreVideMode, out _multiviewVideoMode);
     return(this._multiviewVideoMode);
 }
Esempio n. 11
0
 public void SetMultiViewVideoMode(_BMDSwitcherVideoMode coreVideoMode, _BMDSwitcherVideoMode multiviewVideoMode)
 {
     this.Switcher.SetMultiViewVideoMode(coreVideoMode, multiviewVideoMode);
 }
Esempio n. 12
0
 public void DownConvertedHDVideoMode(_BMDSwitcherVideoMode coreVideoMode, _BMDSwitcherVideoMode downConvertedHDVideoMode)
 {
     this.Switcher.SetDownConvertedHDVideoMode(coreVideoMode, downConvertedHDVideoMode);
 }
Esempio n. 13
0
 public _BMDSwitcherVideoMode DownConvertedHDVideoMode(_BMDSwitcherVideoMode coreVideoMode)
 {
     this.Switcher.GetDownConvertedHDVideoMode(coreVideoMode, out this._downConvertedHDVideoMode);
     return(this._downConvertedHDVideoMode);
 }
Esempio n. 14
0
 public int DoesSupportVideoMode(_BMDSwitcherVideoMode videoMode)
 {
     this.Switcher.DoesSupportVideoMode(videoMode, out this._supported3);
     return(this._supported3);
 }
Esempio n. 15
0
 public int DoesSupportMultiViewVideoMode(_BMDSwitcherVideoMode coreVideoMode, _BMDSwitcherVideoMode multiviewVideoMode)
 {
     this.Switcher.DoesSupportMultiViewVideoMode(coreVideoMode, multiviewVideoMode, out this._supported2);
     return(this._supported2);
 }
Esempio n. 16
0
 public int DoesSupportDownConvertedHDVideoMode(_BMDSwitcherVideoMode coreVideoMode, _BMDSwitcherVideoMode downConvertedHDVideoMode)
 {
     this.Switcher.DoesSupportDownConvertedHDVideoMode(coreVideoMode, downConvertedHDVideoMode, out this._supported1);
     return(this._supported1);
 }