public async Task VideoCaptureAsync(Ruyi.SDK.Overlay.VideoCaptureState arguments, CancellationToken cancellationToken) { await OutputProtocol.WriteMessageBeginAsync(new TMessage("VideoCapture", TMessageType.Call, SeqId), cancellationToken); var args = new VideoCaptureArgs(); args.Arguments = arguments; await args.WriteAsync(OutputProtocol, cancellationToken); await OutputProtocol.WriteMessageEndAsync(cancellationToken); await OutputProtocol.Transport.FlushAsync(cancellationToken); var msg = await InputProtocol.ReadMessageBeginAsync(cancellationToken); if (msg.Type == TMessageType.Exception) { var x = await TApplicationException.ReadAsync(InputProtocol, cancellationToken); await InputProtocol.ReadMessageEndAsync(cancellationToken); throw x; } var result = new VideoCaptureResult(); await result.ReadAsync(InputProtocol, cancellationToken); await InputProtocol.ReadMessageEndAsync(cancellationToken); return; }
public async Task VideoCaptureAsync(Ruyi.SDK.Overlay.VideoCaptureState arguments) { await Task.Run(() => { VideoCapture(arguments); }); }
public void send_VideoCapture(Ruyi.SDK.Overlay.VideoCaptureState arguments) { oprot_.WriteMessageBegin(new TMessage("VideoCapture", TMessageType.Call, seqid_)); VideoCapture_args args = new VideoCapture_args(); args.Arguments = arguments; args.Write(oprot_); oprot_.WriteMessageEnd(); oprot_.Transport.Flush(); }
public void VideoCapture(Ruyi.SDK.Overlay.VideoCaptureState arguments) { #if SILVERLIGHT var asyncResult = Begin_VideoCapture(null, null, arguments); End_VideoCapture(asyncResult); #else send_VideoCapture(arguments); recv_VideoCapture(); #endif }
public async Task ReadAsync(TProtocol iprot, CancellationToken cancellationToken) { iprot.IncrementRecursionDepth(); try { TField field; await iprot.ReadStructBeginAsync(cancellationToken); while (true) { field = await iprot.ReadFieldBeginAsync(cancellationToken); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.Struct) { Arguments = new Ruyi.SDK.Overlay.VideoCaptureState(); await Arguments.ReadAsync(iprot, cancellationToken); } else { await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken); } break; default: await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken); break; } await iprot.ReadFieldEndAsync(cancellationToken); } await iprot.ReadStructEndAsync(cancellationToken); } finally { iprot.DecrementRecursionDepth(); } }
public void Read(TProtocol iprot) { iprot.IncrementRecursionDepth(); try { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.Struct) { Arguments = new Ruyi.SDK.Overlay.VideoCaptureState(); Arguments.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); } finally { iprot.DecrementRecursionDepth(); } }
public IAsyncResult send_VideoCapture(AsyncCallback callback, object state, Ruyi.SDK.Overlay.VideoCaptureState arguments) { oprot_.WriteMessageBegin(new TMessage("VideoCapture", TMessageType.Call, seqid_)); VideoCapture_args args = new VideoCapture_args(); args.Arguments = arguments; args.Write(oprot_); oprot_.WriteMessageEnd(); return(oprot_.Transport.BeginFlush(callback, state)); }
public IAsyncResult Begin_VideoCapture(AsyncCallback callback, object state, Ruyi.SDK.Overlay.VideoCaptureState arguments) { return(send_VideoCapture(callback, state, arguments)); }
public void VideoCapture(Ruyi.SDK.Overlay.VideoCaptureState arguments) { var asyncResult = Begin_VideoCapture(null, null, arguments); End_VideoCapture(asyncResult); }