35 lines
744 B
C#
35 lines
744 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using System.Diagnostics;
|
|
using UnityEngine;
|
|
/// <summary>
|
|
/// 语音转文字
|
|
/// </summary>
|
|
public class STT : MonoBehaviour
|
|
{
|
|
|
|
/// <summary>
|
|
/// 语音识别api地址
|
|
/// </summary>
|
|
[SerializeField] protected string m_SpeechRecognizeURL = String.Empty;
|
|
/// <summary>
|
|
/// 计算方法调用的时间
|
|
/// </summary>
|
|
[SerializeField] protected Stopwatch stopwatch = new Stopwatch();
|
|
/// <summary>
|
|
/// 语音识别
|
|
/// </summary>
|
|
public virtual void StartSpeechToText(Action<string> _callback)
|
|
{
|
|
|
|
}
|
|
/// <summary>
|
|
/// 结束语音识别
|
|
/// </summary>
|
|
public virtual void StopSpeechToText(Action<string> _callback)
|
|
{
|
|
|
|
}
|
|
}
|