private void StartRecord()//开始录制
{
string path_root = Application.persistentDataPath + "/";
if (Application.platform==RuntimePlatform.Android)
{
path_root= "/sdcard/Movies/";
//动态创建文件夹
if (!Directory.Exists(path_root))
{
Directory.CreateDirectory(path_root);
}
}
//录制
ARBuilder.Instance.RecorderBehaviour.OutputFile= path_root + System.DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss") + ".mp4";
ARBuilder.Instance.RecorderBehaviour.StartRecording();
isRecording = true;
}
private void StopRecord()//结束录制
{
ARBuilder.Instance.RecorderBehaviour.StopRecording();
MessageManager.Instance.ShowBottomMessage("录制完成:"+ ARBuilder.Instance.RecorderBehaviour.OutputFile,2f);
isRecording = false;
}