コード例 #1
0
 private void OnQueryReceived(ReceivedQuery query)
 {
     if (query.Command == MessageQueryNames.GetBlendShapeNames)
     {
         query.Result = string.Join("\t", TryGetBlendShapeNames());
     }
 }
コード例 #2
0
        public IObservable <string> ReceiveQuery(ReceivedQuery query)
        {
            var item = new QueryQueueItem(query);

            _receivedQueries.Enqueue(item);
            return(item.ResultSubject);
        }
コード例 #3
0
 private void OnQueryReceived(ReceivedQuery q)
 {
     if (q.Command == MessageQueryNames.GetQualitySettingsInfo)
     {
         q.Result = JsonUtility.ToJson(new ImageQualityInfo()
         {
             ImageQualityNames   = QualitySettings.names,
             CurrentQualityIndex = QualitySettings.GetQualityLevel(),
         });
     }
 }
コード例 #4
0
        private void OnQueryRequested(ReceivedQuery query)
        {
            switch (query.Command)
            {
            case MessageQueryNames.CurrentMicrophoneDeviceName:
                query.Result = _lipSyncContext.DeviceName;
                break;

            case MessageQueryNames.MicrophoneDeviceNames:
                query.Result = string.Join("\t", Microphone.devices);
                break;
            }
        }
コード例 #5
0
 public QueryQueueItem(ReceivedQuery query)
 {
     Query         = query;
     ResultSubject = new AsyncSubject <string>();
 }