private void HandleAudioPreviewSelectionChanged(StreamOption audioStream)
        {
            SmoothStreamingVideoAsset smoothStreamingVideoAsset = this.Asset as SmoothStreamingVideoAsset;

            if (smoothStreamingVideoAsset != null)
            {
                this.VideoAssetInOut.PreviewAudioStream = smoothStreamingVideoAsset.AudioStreams.First(a => a.Name == audioStream.Name);
            }
        }
Esempio n. 2
0
        /// <summary>
        /// 本函数为Form添加FormClosingEvent,关闭窗口时关闭rs实例。构造函数依据Stream.***Option来使用
        /// </summary>
        /// <param name="so"></param>
        public Stream(Form f, StreamOption so = StreamOption.None, AlgoOption ao = AlgoOption.Face, RecordOption ro = RecordOption.Record, Label lb = null)
        {
            m_algoOption   = ao;
            m_streamOption = so;
            m_recordOption = ro;

            m_label = lb;

            f.FormClosing += new System.Windows.Forms.FormClosingEventHandler(FormClosingHandler);

            InitPowerState();
        }
Esempio n. 3
0
        /// <summary>
        /// 构造函数依据Stream.***Option来使用
        /// </summary>
        /// <param name="so"></param>
        public Stream(StreamOption so = StreamOption.None, AlgoOption ao = AlgoOption.Face, RecordOption ro = RecordOption.Record)
        {
            m_algoOption   = ao;
            m_streamOption = so;
            m_recordOption = ro;

            if (session == null)
            {
                session = PXCMSession.CreateInstance();
            }

            InitPowerState();
        }
Esempio n. 4
0
 public LimitStream(Stream input, long last, StreamOption option, bool leave_open = false)
     : this(input, last, leave_open)
 {
     if (StreamOption.Fill == option)
     {
         if (m_can_seek && input.Length < m_last)
         {
             input.Position = m_position;
             m_can_seek     = false;
         }
         m_fill = true;
     }
 }
Esempio n. 5
0
        public Stream(
            string id,
            DateTime updated,
            DateTime accessed,
            string ownername,
            string name,
            PathSpec parent,
            PathSpec baseparent,
            StreamType type,
            string description,
            StreamOption options,
            string firmerthanparent,
            string changeflowstoparent,
            string changeflowsfromparent,
            ViewMap paths,
            ViewMap remapped,
            ViewMap ignored,
            ViewMap view,
            ViewMap changeview,
            FormSpec spec,
            Dictionary <string, object> customfields,
            ParentView parentview)

        {
            Id                    = id;
            Updated               = updated;
            Accessed              = accessed;
            OwnerName             = ownername;
            Name                  = name;
            Parent                = parent;
            BaseParent            = baseparent;
            Type                  = type;
            Description           = description;
            Options               = options;
            FirmerThanParent      = firmerthanparent;
            ChangeFlowsToParent   = changeflowstoparent;
            ChangeFlowsFromParent = changeflowsfromparent;
            Paths                 = paths;
            Remapped              = remapped;
            Ignored               = ignored;
            View                  = view;
            ChangeView            = changeview;
            Spec                  = spec;
            CustomFields          = customfields;
            ParentView            = parentview;
        }
        private void HandleAudioSequenceSelectionChanged(StreamOption audioStream)
        {
            if (this.availableAudioStreams.Count(s => s.SequenceSelected) > maxNumberOfAudioTracks + 1)
            {
                audioStream.SequenceSelected = false;
                return;
            }

            SmoothStreamingVideoAsset smoothStreamingVideoAsset = this.Asset as SmoothStreamingVideoAsset;

            if (smoothStreamingVideoAsset != null)
            {
                var audio = smoothStreamingVideoAsset.AudioStreams.First(a => a.Name == audioStream.Name);
                if (audioStream.SequenceSelected)
                {
                    this.VideoAssetInOut.SequenceAudioStreams.Add(audio);
                }
                else
                {
                    this.VideoAssetInOut.SequenceAudioStreams.Remove(audio);
                }
            }
        }
 private void HandleVideoSequenceSelectionChanged(StreamOption videoCamera)
 {
     this.VideoAssetInOut.SequenceVideoCamera = videoCamera.Name;
 }
 private void HandleVideoPreviewSelectionChanged(StreamOption videoCamera)
 {
     this.VideoAssetInOut.PreviewVideoCamera = videoCamera.Name;
 }
 public int nabtoStreamSetOption(IntPtr stream, StreamOption optionName, int optionValue, int optionLength)
 {
     return(Win32NativeMethods.nabtoStreamSetOption(stream, optionName, ref optionValue, (IntPtr)optionLength));
 }
Esempio n. 10
0
 public NabtoStatus nabtoStreamSetOption(IntPtr stream, StreamOption optionName, int optionValue, int optionLength)
 {
     return(NabtoStatusHandler(concretePlatformAdapter.nabtoStreamSetOption(stream, optionName, optionValue, optionLength), "nabtoStreamSetOption"));
 }
Esempio n. 11
0
 extern static public int nabtoStreamSetOption(IntPtr stream, StreamOption optionName, ref int optionValue, IntPtr optionLength);
 public NabtoStatus nabtoStreamSetOption(IntPtr stream, StreamOption optionName, int optionValue, int optionLength)
 {
     return((NabtoStatus)interopAdapter.nabtoStreamSetOption(stream, optionName, optionValue, optionLength));
 }
 void SetOption(StreamOption option, Int32 value)
 {
     PlatformAdapter.Instance.nabtoStreamSetOption(handle.DangerousGetHandle(), option, value, 4);
 }