| | |
Working with mp3 files and folders.
![]() |
•
•
Join Date: Nov 2008
Posts: 1
Reputation:
Solved Threads: 0
Hi,
Recently I came up with an idea of making my own program for tagging mp3 files. I realised I'm lacking in knowledge. For now I need the following information:
1. After typing a path to a main folder, I'd like to read the names of the folders inside.
2. Than I want to visit each of those folders - get inside (Those folders will include mp3 files).
3. Finally I want to enter this section of a mp3 file where the information about e.g. atrist or genre is kept and I want to chane it.
Can anyone help tell me with this?
Thanx!
Recently I came up with an idea of making my own program for tagging mp3 files. I realised I'm lacking in knowledge. For now I need the following information:
1. After typing a path to a main folder, I'd like to read the names of the folders inside.
2. Than I want to visit each of those folders - get inside (Those folders will include mp3 files).
3. Finally I want to enter this section of a mp3 file where the information about e.g. atrist or genre is kept and I want to chane it.
Can anyone help tell me with this?
Thanx!
•
•
Join Date: Nov 2008
Posts: 15
Reputation:
Solved Threads: 0
the first 2 questions can be solved by the following sample code:
the information on artist in a mp3 file is stored in the last 128 bytes of the file. so you can simply read the last 128 bytes.
C++ Syntax (Toggle Plain Text)
find(char * lpPath) { char szFind[MAX_PATH]; WIN32_FIND_DATA FindFileData; strcpy(szFind,lpPath); strcat(szFind,"\\*.*"); HANDLE hFind=::FindFirstFile(szFind,&FindFileData); if(INVALID_HANDLE_VALUE == hFind) return; while(TRUE) { if(FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { if(FindFileData.cFileName[0]!='.') { strcpy(szFile,lpPath); strcat(szFile,"\\"); strcat(szFile,FindFileData.cFileName); find(szFile); } } else { cout << FindFileData.cFileName; } if(!FindNextFile(hFind,&FindFileData)) break; } FindClose(hFind); }
![]() |
Similar Threads
- Surf Sidekick has taken over my computer (Viruses, Spyware and other Nasties)
Other Threads in the C++ Forum
- Previous Thread: Help me to finish program. Urgently!
- Next Thread: Generate 6 Random Numbers
| Thread Tools | Search this Thread |
api application array based binary bitmap c# c++ c/c++ char class classes code coding compile compression console conversion count cpm delete deploy deque desktop developer dialog directshow dll download dynamic dynamiccharacterarray email encryption error file forms fstream function functions game givemetehcodez graph gui homeworkhelp homeworkhelper iamthwee ifstream input int integer introductory java lib linkedlist linkednodes linker loop looping loops map math matrix memory multiple news node numbertoword output parameter pointer problem program programming project python random read recursion reference rpg security sorting string strings temperature template test text text-file tree url variable vector video whyisthiscodecausingsegmentationfault win32 windows winsock wordfrequency wxwidgets





