0
0

New into this forum and using FMOD in a software Jukebox project for Linux.

Get_tags function seen to been incomplete and found some issues for MP3 files.

First I got a file where it diddent find any tags, even it read fine on Windows (not using FMOD). The file do not have a ID3v1 tags, but only ID3v2. Tried the index function, but did not work here.

Another issue is FMOD did not check when the tag was unicode and still return STRING as result and have no change to convert it to a unicode string (as BlitzMax use).

Here is the C code I tried to and used as a wrapper for BlitzMax:

[code:12q3avuz]
wchar_t FMOD_GetTags(int handle, char *tagname)
{ int error;
FMOD_RESULT result;
FMOD_SOUND *FMODSound;
error = FMOD_Sound_GetTag((FMOD_SOUND *)handle, tagname, 1, &tag);
if (error==FMOD_OK) { wchar_t dat=tag.data; return dat; }

error = FMOD_Sound_GetTag((FMOD_SOUND *)handle, tagname, 0, &tag);
if (error==FMOD_OK) { wchar_t dat=tag.data; return dat; }

return "";

}

[/code:12q3avuz]

I which if FMOD auto convert to a WCHAR_T string when unicode is detected (and same with UTF8 and UTF16)?

I might need to send the 2 problem mp3 files as test?

Please Note: The filename in the unicode problem did not use unicode, but only in tags (so it open the file fine).

  • You must to post comments
0
0

Hi spacefractal, it’ll be good if you could forward us the mp3’s to take a look at.

You can upload them to

http://ftp.fmod.org
u: upload
p: upload

  • You must to post comments
0
0

I guess it diddent detect ID3v2, but only ID3v1 in both files (where unicode show wrong in v1, but not in v2). Even I guesss index=1 should been v2 and index=0 v1 (because its tecnical 2 tags in same file)?

Uploaded them both and named using my forum username.

[EDIT]
When show in Winmap, the unicode file show wrong in v1 and correct in v2. The above can been misfostood. but both files diddent detect correctly.

  • You must to post comments
0
0

I just tried the files you uploaded in the "readtags" example that comes with the FMOD SDK and it is working fine. It displays the same information that WinAmp does.

As for unicode, FMOD_TAG.datatype will tell you what type of data it has returned (including if it is a unicode string, check fmod.h for all the data types). FMOD just gives you the raw tag data, you need to handle this data yourself.

I suggest having a look at the "readtags" example yourself.

  • You must to post comments
0
0

last time I checked datatype was just returned the same value regaardles it was unicode or not. But I recheck later again, when I have the new version of my software is done for Windows.

Otherwice is it any way to just retwrive the pointer where the id3 starts and manual checking for values (which is allready done for the Windows counterpart where I using BASS for the same software)?

  • You must to post comments
0
0

I guess I use GetNumTags Instead. Here I have a bette clue which tag names it come out.

It look like the first ID3v2 file diddent convert correct to ALBUM and ARTIST as documented. Instead you need the original ID3 naming tags to get it to work.

The unicode file I also sendt do both have TITLE and TPE1… Here I do prefer TPE1, since it used the unicoded format. I guess the TITLE was from ID3v1 tag.

So it isent documented you might need to use the orginal ID3v2 names to retrive the tags and not the converted ones.

So it just some errors in the document and not in FMOD.

  • You must to post comments
Showing 5 results
Your Answer

Please first to submit.