if(mciError) {
mciGetErrorString(mciError,buf,128); printf("%s\n",buf); getchar(); } }
void lrcmaker(char*music,char*txt)//主要部分 {
int musictime=getmusictime(music); FILE* txtfile,*lrcfile;
if(NULL==(txtfile=fopen(txt,"r")))//打开文件才可以用 {
cout<<"no this txt."<<endl; getchar(); }
int pointpos=0;
for(int i=0;music[i]!=NULL;i++) {
if('.'==music[i]) pointpos=i;//记住.的位置 }
char*lrc=new char[pointpos+4];//lrc为lrc文件名 lrc=music;
//for(i=0;i<=pointpos;i++) //lrc[i]=music[i]; //lrc[pointpos+1]='l'; //lrc[pointpos+2]='r';
//lrc[pointpos+3]='c';//写歌词文件名 if(NULL==(lrcfile=fopen(lrc,"r+"))) {
cout<<"cannot open lrc."<<endl; getchar(); }