⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ancr_03.cc

📁 这是一个从音频信号里提取特征参量的程序
💻 CC
字号:
// file: $isip/class/asr/Anchor/ancr_03.cc//// isip include files//#include "Anchor.h"// method: read//// arguments://  Sof& sof: (input) sof file object//  long tag: (input) sof object instance tag//  const String& name: (input) sof object instance name//// return: a boolean value indicating status//// this method has the object read itself from an Sof file//boolean Anchor::read(Sof& sof_a, long tag_a, const String& name_a) {  // read the instance of the object from the Sof file  //  if (!sof_a.find(name_a, tag_a)) {    return false;  }    // read the actual data from the sof file  //  if (!readData(sof_a)) {    return false;  }    // exit gracefully  //  return true;  }// method: readData//// arguments://  Sof& sof: (input) sof file object//  const String& pname: (input) parameter name//  long size: (input) size in bytes of object (or full_size)//  boolean param: (input) is the parameter name in the file?//  boolean nested: (input) are we nested?//// return: a boolean value indicating status//// this method has the object read itself from an Sof file. it assumes// that the Sof file is already positioned correctly.//boolean Anchor::readData(Sof& sof_a, const String& pname_a,			  long size_a, boolean param_a,			  boolean nested_a) {  // set i/o parameters  //  Integral::DEBUG debug_level = Integral::NONE;  SofParser parser;  parser.setDebug(debug_level);      // ignore implicit parameter setting  //  // clear the object  //  this->clear();    // are we nested?  //  if (nested_a) {    parser.setNest();  }    // load the parse  //  if (!parser.load(sof_a, size_a)) {    return Error::handle(name(), L"readData", Error::READ,			 __FILE__, __LINE__, Error::WARNING);  }	      // get the id  //  if (!id_d.readData(sof_a, PARAM_ID,			parser.getEntry(sof_a, PARAM_ID),			false, false)) {    return Error::handle(name(), L"readData", Error::READ,			 __FILE__, __LINE__, Error::WARNING);  }    // get the offset  //  if (!offset_d.readData(sof_a, PARAM_OFFSET,			parser.getEntry(sof_a, PARAM_OFFSET),			false, false)) {    return Error::handle(name(), L"readData", Error::READ,			 __FILE__, __LINE__, Error::WARNING);  }  // get the unit  //  if (!unit_d.readData(sof_a, PARAM_UNIT,			parser.getEntry(sof_a, PARAM_UNIT),			false, false)) {    return Error::handle(name(), L"readData", Error::READ,			 __FILE__, __LINE__, Error::WARNING);  }  // get the anchored  //  if (!anchored_d.readData(sof_a, PARAM_ANCHORED,			parser.getEntry(sof_a, PARAM_ANCHORED),			false, false)) {    return Error::handle(name(), L"readData", Error::READ,			 __FILE__, __LINE__, Error::WARNING);  }	            // exit gracefully  //  return true;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -