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

📄 hwrawdatac.cc

📁 手写识别是模式识别中研究得一个热点
💻 CC
字号:
#include "HWRawDataC.hh"#define MYDEBUG 0ostream& operator << (ostream& outfile, HWHeaderC Header){  outfile << Header.Magic << '\n' << Header.String << '\n';  return outfile;}ostream& operator << (ostream& outfile, HWRawDataC Record){  outfile << Record.Type << ' ' << Record.Time;  if (Record.Type == 0)    {      outfile << ' ' << Record.DataPoint.XPos << ' ' << Record.DataPoint.YPos	<< ' ' << Record.DataPoint.XTilt << ' ' << Record.DataPoint.YTilt	  << ' ' << Record.DataPoint.Pressure;    }  outfile << '\n';  return outfile;}ostream& operator << (ostream& outfile, HWDataPointC Point){  outfile << Point.XPos << ", " << Point.YPos;  return outfile;}istream& operator >> (istream& infile, HWHeaderC& Header){  char ch;  if (MYDEBUG)    cerr << "Start read: " << infile.tellg() << '\n';  infile.getline(Header.Magic, 20, '\n');  if (MYDEBUG)    cerr << "Mid read: " << infile.tellg() << '\n';  infile.getline(Header.String, 1000, '\n');  if (MYDEBUG)    cerr << "End read: " << infile.tellg() << " String is " << Header.String << "\n";  return infile;}istream& operator >> (istream& infile, HWRawDataC& Record){  if (MYDEBUG)    cerr << "Start read: " << infile.tellg() << '\n';  infile >> Record.Type >> Record.Time;  if (MYDEBUG)    cerr << "Read, type = " << Record.Type << '\n';  if (Record.Type == 0)    {      infile >> Record.DataPoint.XPos >> Record.DataPoint.YPos	>> Record.DataPoint.XTilt >> Record.DataPoint.YTilt	  >> Record.DataPoint.Pressure;    }  if (MYDEBUG)    cerr << "End read: " << infile.tellg() << '\n';  return infile;}int operator ==(const HWDataPointC& P1, const HWDataPointC& P2){  return P1.XPos == P2.XPos && P1.YPos == P2.YPos;}

⌨️ 快捷键说明

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