Copyright © 2008-2018 MultiMedia Soft

How to edit tag info in sound files

Previous pageReturn to chapter overviewNext page

The majority of audio formats allows the insertion of metadata, also known as "tags", which helps describing the content of the audio file by inserting information such as the title, artist, album, track number and other information about the audio file to be stored in the file itself.

 

The TagsEditor COM object of Active Sound Editor allows reading and writing the most common tag formats: this can be accomplished by analyzing the audio file loaded inside an editing session, through the TagsEditor.ALL_AnalyzeSoundOnEditor method, or by accessing a sound file directly on the local disk through the TagsEditor.ALL_AnalyzeSoundFile method.

 

Both methods return a combination of flags which allow determining the specific tag formats embedded inside the audio file; certain audio formats allow embedding more than one tag format; for example, the MP3 format could contain ID3V1, ID3V2 and LYRICS3 formats: the combination of flags allows discriminating which of them are effectively available inside the audio file and to manage them separately; if the returned value should be 0, this would mean that no known tag format is embedded inside the audio file. A small example can be see inside the following code snippets:

 

Visual Basic 6

 

' perform tags analysis

Dim nTagFormat As enumTagAvailable

nTagFormat = ActiveSoundEditor1.TagsEditor.ALL_AnalyzeSoundOnEditor()

If nTagFormat = TAG_FLAG_NONE Then

   ' no tag detected

   Exit Sub

End If

 

' check tags availability: we use bitwise operators because more than one type of tag format could be available

If nTagFormat And TAG_FLAG_ID3V1 Then

   ...

 do something with ID3V1

   ...

End If

If nTagFormat And TAG_FLAG_ID3V2 Then

   ...

 do something with ID3V2

   ...

End If

If nTagFormat And TAG_FLAG_WMA Then

   ...

 do something with WMA

   ...

End If

If nTagFormat And TAG_FLAG_MP4 Then

   ...

 do something with MP4

   ...

End If

 

 

Visual C++

 

// perform tags analysis

long nTagFormat = ActiveSoundEditor1.GetTagsEditor().ALL_AnalyzeSoundOnEditor();

if (nTagFormat == TAG_FLAG_NONE)

   // no tag detected

   return;

 

// check tags availability: we use bitwise operators because more than one type of tag format could be available

if (nTagFormat & TAG_FLAG_ID3V1)

{

   ...

   do something with ID3V1

   ...

}

if (nTagFormat & TAG_FLAG_ID3V2)

{

   ...

   do something with ID3V2

   ...

}

if (nTagFormat & TAG_FLAG_WMA)

{

   ...

   do something with WMA

   ...

}

if (nTagFormat & TAG_FLAG_MP4)

{

   ...

   do something with MP4

   ...

}

 

 

Some of the tag fields, such as artist, title and album, are common to all of the tag formats so Active Sound Editor exposes a set of methods that allows accessing these common frames without the need to know the specific format of the audio file being edited: the combination of the TagsEditor.ALL_CommonFrameGet and TagsEditor.ALL_CommonFrameSet methods allows reading and writing these common frames; once completed, eventual modifications can be stored inside the original audio file through the TagsEditor.ALL_SaveChanges method.

 

IMPORTANT NOTE:When using the TagsEditor.ALL_AnalyzeSoundOnEditor and TagsEditor.ALL_AnalyzeSoundFile methods, subsequent calls to other methods of the TagsEditor COM object will be related to that specific analysis also if the calls are performed from different instances of the component.

If for example you have 2 instances of Active Sound Editor, named ActiveSoundEditor1 and ActiveSoundEditor2 respectively, and you want to obtain the title of the loaded song, after the following call

 

Dim nTagFormat As enumTagAvailable

nTagFormat = ActiveSoundEditor1.TagsEditor.ALL_AnalyzeSoundOnEditor()

Dim strTitle as String

strTitle = ActiveSoundEditor1.TagsEditor.ALL_CommonFrameGet (TAG_FIELD_TITLE)

 

the returned title will be about the sound file loaded inside ActiveSoundEditor1 while after the following call

 

nTagFormat = ActiveSoundEditor2.TagsEditor.ALL_AnalyzeSoundOnEditor()

strTitle = ActiveSoundEditor2.TagsEditor.ALL_CommonFrameGet (TAG_FIELD_TITLE)

 

the returned title will be about the sound file loaded inside ActiveSoundEditor2. This means that, in order to read further information about tags stored inside ActiveSoundEditor1, for example the author's name, you will have to perform a new analysis of the sound loaded in ActiveSoundEditor1 as seen below:

 

Dim strAuthor as String

nTagFormat = ActiveSoundEditor1.TagsEditor.ALL_AnalyzeSoundOnEditor()

strAuthor = ActiveSoundEditor1.TagsReader.ALL_CommonFrameGet (TAG_FIELD_ARTIST)

 

 

When dealing with specific audio formats, Active Sound Editor allows editing the following kind of tags:

 

ID3V1
ID3V2
LYRICS3
WMA
OGG Vorbis
MP4
APE
FLAC
WAV Chunks

 

 

ID3V1

 

The ID3V1 tag, intended for usage with MP3 files, occupies 128 bytes beginning with the string TAG and is placed at the end of the file. This tag allows 30 bytes each for the title, artist, album, and a "comment", four bytes for the year, and a byte to identify the genre of the song from a predefined list of 80 values (Winamp later extended this list to 148 values).

One improvement to ID3V1 uses the last two bytes of the comment field to store the track number. Such tags are referred to as ID3V1.1.

A full description of this tagging format can be found on this link.

 

You can know if the ID3V1 tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_ID3V1 this would mean that the ID3V1 tag is available.

 

ID3V1 fields can be read through the TagsEditor.ID3V1_FieldGet method and modified through the TagsEditor.ID3V1_FieldSet method. Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.ID3V1_SaveChanges method.

The ID3V1 tag can be removed through the TagsEditor.ID3V1_RemoveTag method: in this case the tag removal is performed directly on the original sound file.

 

 

ID3V2

 

ID3V2 is a tagging system that lets you put enriching and relevant information about your audio files within them. ID3V2 is a chunk of data prepended to the binary audio data. Each ID3V2 tag holds one or more smaller chunks of information, called frames. These frames can contain any kind of information and data you could think of such as title, album, performer, website, lyrics, equalizer presets, pictures etc.

A full description of this tagging format can be found on this link.

 

Active Sound Editor supports 3 different versions of ID3V2:

 

ID3V2.2
ID3V2.3
ID3V2.4

 

All of them are currently supported in both reading and writing by the component. This system allows the use of UNICODE characters in UTF-16 format and, when dealing with version ID3V2.4, in UTF-8 format as well.

 

You can know if the ID3V2 tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_ID3V2 this would mean that the ID3V2 tag is available.

 

The list of supported ID3V2 frames, with related identifiers and methods to access stored information, can be found on the table below:

 

Supported frame types

Frame identifiers

Multiple

Related methods

Text-based frames

TIT1, TIT2, TIT3, TALB, TOAL, TRCK, TPOS, TSST, TSRC, TPE1, TPE2, TPE3, TPE4, TOPE, TEXT, TOLY, TCOM, TMCL, TIPL, TENC, TBPM, TLEN, TKEY, TLAN, TCON, TFLT, TMED, TMOO, TCOP, TPRO, TPUB, TOWN, TRSN, TRSO, TOFN, TDLY, TDEN, TDOR, TDRC, TDRL, TDTG, TSSE, TSOA, TSOP, TSOT

No

TagsEditor.ID3V2_TextFrameGet

TagsEditor.ID3V2_TextFrameSet

User text frames

TXXX

Yes

TagsEditor.ID3V2_UserTextFrameAdd

TagsEditor.ID3V2_UserTextFrameDescriptionGet

TagsEditor.ID3V2_UserTextFrameGet

TagsEditor.ID3V2_UserTextFrameRemove

URL-based frames

WCOM, WCOP, WOAF, WOAR, WOAS, WORS, WPAY, WPUB

No

TagsEditor.ID3V2_URLFrameGet

TagsEditor.ID3V2_URLFrameSet

User URL frames

WXXX

Yes

TagsEditor.ID3V2_UserURLFrameAdd

TagsEditor.ID3V2_UserURLFrameDescriptionGet

TagsEditor.ID3V2_UserURLFrameGet

TagsEditor.ID3V2_UserURLFrameRemove

Comment frames

COMM

Yes

TagsEditor.ID3V2_CommentFrameAdd

TagsEditor.ID3V2_CommentFrameGet

TagsEditor.ID3V2_CommentFrameInfoGet

TagsEditor.ID3V2_CommentFrameRemove

Commercial frames

COMR

Yes

TagsEditor.ID3V2_CommercialFrameAddWithBitmap

TagsEditor.ID3V2_CommercialFrameAddWithFile

TagsEditor.ID3V2_CommercialFrameAddWithMemoryFile

TagsEditor.ID3V2_CommercialFrameInfoGet

TagsEditor.ID3V2_CommercialFramePictureBitmapGet

TagsEditor.ID3V2_CommercialFramePictureFileGet

TagsEditor.ID3V2_CommercialFramePictureMemoryFileGet

TagsEditor.ID3V2_CommercialFramePictureSizeGet

TagsEditor.ID3V2_CommercialFrameReceivedAsGet

TagsEditor.ID3V2_CommercialFrameRemove

Event timings (cue points) frame

ETCO

No

TagsEditor.ID3V2_EventTimingsFrameEventAdd

TagsEditor.ID3V2_EventTimingsFrameEventCountGet

TagsEditor.ID3V2_EventTimingsFrameEventInfoGet

TagsEditor.ID3V2_EventTimingsFrameEventRemove

TagsEditor.ID3V2_EventTimingsFrameRemove

General objects frames

GEOB

Yes

TagsEditor.ID3V2_GeneralObjectFrameAddFromFile

TagsEditor.ID3V2_GeneralObjectFrameAddFromMemoryFile

TagsEditor.ID3V2_GeneralObjectFrameFileGet

TagsEditor.ID3V2_GeneralObjectFrameInfoGet

TagsEditor.ID3V2_GeneralObjectFrameMemoryFileGet

TagsEditor.ID3V2_GeneralObjectFrameRemove

TagsEditor.ID3V2_GeneralObjectFrameSizeGet

Music CD identifier frames

MCDI

No

TagsEditor.ID3V2_MusicCdIdentifierFrameAdd

TagsEditor.ID3V2_MusicCdIdentifierFrameGet

TagsEditor.ID3V2_MusicCdIdentifierFrameRemove

TagsEditor.ID3V2_MusicCdIdentifierFrameSizeGet

Ownership frame

OWNE

No

TagsEditor.ID3V2_OwnershipFrameInfoGet

TagsEditor.ID3V2_OwnershipFrameRemove

TagsEditor.ID3V2_OwnershipFrameSet

Picture frames

APIC

Yes

TagsEditor.ID3V2_PictureFrameAddFromBitmap

TagsEditor.ID3V2_PictureFrameAddFromFile

TagsEditor.ID3V2_PictureFrameAddFromMemoryFile

TagsEditor.ID3V2_PictureFrameAddURL

TagsEditor.ID3V2_PictureFrameBitmapGet

TagsEditor.ID3V2_PictureFrameFileGet

TagsEditor.ID3V2_PictureFrameInfoGet

TagsEditor.ID3V2_PictureFrameMemoryFileGet

TagsEditor.ID3V2_PictureFrameRemove

TagsEditor.ID3V2_PictureFrameSizeGet

TagsEditor.ID3V2_PictureFrameTypeGet

Play counter frame

PCNT

No

TagsEditor.ID3V2_PlayCounterFrameCountGet

TagsEditor.ID3V2_PlayCounterFrameCountSet

TagsEditor.ID3V2_PlayCounterFrameRemove

Popularimiter frame

POPM

Yes

TagsEditor.ID3V2_PopularimeterFrameAdd

TagsEditor.ID3V2_PopularimeterFrameCounterGet

TagsEditor.ID3V2_PopularimeterFrameEmailGet

TagsEditor.ID3V2_PopularimeterFrameRatingGet

TagsEditor.ID3V2_PopularimeterFrameRemove

Private frame

PRIV

Yes

TagsEditor.ID3V2_PrivateFrameAddFromFile

TagsEditor.ID3V2_PrivateFrameAddFromMemoryFile

TagsEditor.ID3V2_PrivateFrameFileGet

TagsEditor.ID3V2_PrivateFrameMemoryFileGet

TagsEditor.ID3V2_PrivateFrameOwnerGet

TagsEditor.ID3V2_PrivateFrameRemove

TagsEditor.ID3V2_PrivateFrameSizeGet

Synchronized lyrics frames

SYLT

Yes

TagsEditor.ID3V2_SynchLyricsFrameAdd

TagsEditor.ID3V2_SynchLyricsFrameGet

TagsEditor.ID3V2_SynchLyricsFrameInfoGet

TagsEditor.ID3V2_SynchLyricsFrameInfoNumGet

TagsEditor.ID3V2_SynchLyricsFrameRemove

Terms of use frames

USER

Yes

TagsEditor.ID3V2_TermsOfUseFrameAdd

TagsEditor.ID3V2_TermsOfUseFrameGet

TagsEditor.ID3V2_TermsOfUseFrameLanguageGet

TagsEditor.ID3V2_TermsOfUseFrameRemove

Unsynchronized lyrics frames

USLT

Yes

TagsEditor.ID3V2_UnsynchLyricsFrameAdd

TagsEditor.ID3V2_UnsynchLyricsFrameGet

TagsEditor.ID3V2_UnsynchLyricsFrameInfoGet

TagsEditor.ID3V2_UnsynchLyricsFrameRemove

 

Support for other frames not available in the list above may be added in future versions of the component so, in case you should need the support of a specific frame, feel free to contact our technical support team.

 

The "Multiple" column specifies if more than one frame, having the same identifier, can be available inside the tag; in order to know how many frames are available for a specific identifier, you should use the ID3V2_FrameCountGet method. If for example you should need enumerating pictures stored inside the tag, you could do something similar:

 

Visual Basic 6

 

' perform tags analysis

Dim nTagFormat As enumTagAvailable

nTagFormat = ActiveSoundEditor1.TagsEditor.ALL_AnalyzeSoundOnEditor()

If nTagFormat And TAG_FLAG_ID3V2 Then

   ' check the availability of embedded pictures through the search of "APIC" frames

   Dim nAvailablePictures as Long

   nAvailablePictures = ActiveSoundEditor1.TagsEditor.ID3V2_FrameCountGet("APIC")

 

   ' output each picture's description

   Dim nIndex as Long

   For nIndex = 0 to nAvailablePictures - 1

      Debug.Print ActiveSoundEditor1.TagsEditor.ID3V2_PictureFrameInfoGet (nIndex, ID3V2_FRAME_INFO_DESCRIPTION)

   Next nIndex

End If

 

 

Visual C++

 

// perform tags analysis

long nTagFormat = ActiveSoundEditor1.GetTagsEditor().ALL_AnalyzeSoundOnEditor();

if(nTagFormat & TAG_FLAG_ID3V2)

{

   // check the availability of embedded pictures through the search of "APIC" frames

   long nAvailablePictures = ActiveSoundEditor1.GetTagsEditor().ID3V2_FrameCountGet(_T("APIC"));

 

   // output each picture's description

   for (long nIndex = 0; nIndex < nAvailablePictures; nIndex++)

      TRACE (ActiveSoundEditor1.GetTagsEditor().ID3V2_PictureFrameInfoGet (nIndex, ID3V2_FRAME_INFO_DESCRIPTION) + _T("\r\n"));

}

 

 

Identifiers of frames available inside the ID3V2 tag can be enumerated using the combination of the TagsEditor.ID3V2_UniqueFramesCountGet and TagsEditor.ID3V2_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.ID3V2_SaveChanges method: this method allows also specifying the version the ID3V2 standard and the text encoding used to store strings.

The ID3V2 tag can be removed through the TagsEditor.ID3V2_RemoveTag method: in this case the tag removal is performed directly on the original sound file.

 

 

 

LYRICS3

 

The Lyrics3 v2.00 tag resides between the audio and the ID3V1 tag, which must be present. The tag uses only text for everything from content to size descriptors, which are represented as numerical strings.

A full description of this tagging format can be found on this link.

 

You can know if the Lyrics3 tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_LYRICS3 this would mean that the Lyrics3 tag is available.

 

Text fields of the Lyrics3 tag can be read through the TagsEditor.LYRICS3_TextFieldGet method and modified through the TagsEditor.LYRICS3_TextFieldSet method.

The lyrics text can be read through the TagsEditor.LYRICS3_LyricsGet method and modified through the TagsEditor.LYRICS3_LyricsSet method.

The link to the image field can be read through the TagsEditor.LYRICS3_ImageLinkGet method and modified through the TagsEditor.LYRICS3_ImageLinkSet method.

 

Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.LYRICS3_SaveChanges method.

The Lyrics3 tag can be removed through the TagsEditor.LYRICS3_RemoveTag method: in this case the tag removal is performed directly on the original sound file.

 

 

 

WMA
 

You can know if the WMA tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_WMA this would mean that the WMA tag is available.

 

The list of supported WMA frames, with related identifiers and methods to access stored information, can be found on the table below:

 

Supported frame types

Frame identifiers

Multiple

Related methods

Text-based frames

You can use predefined identifiers or, in alternative, your own custom ones: a list of predefined identifiers can be found inside the Windows Media Format SDK.

No

TagsEditor.WMA_TextFrameGet

TagsEditor.WMA_TextFrameSet

Picture frames

WM/Picture

Yes

TagsEditor.WMA_PictureFrameAddFromBitmap

TagsEditor.WMA_PictureFrameAddFromFile

TagsEditor.WMA_PictureFrameAddFromMemoryFile

TagsEditor.WMA_PictureFrameBitmapGet

TagsEditor.WMA_PictureFrameCountGet

TagsEditor.WMA_PictureFrameFileGet

TagsEditor.WMA_PictureFrameInfoGet

TagsEditor.WMA_PictureFrameMemoryFileGet

TagsEditor.WMA_PictureFrameRemove

TagsEditor.WMA_PictureFrameSizeGet

TagsEditor.WMA_PictureFrameTypeGet

 

The "Multiple" column specifies that there may be more than one picture frame available inside the tag; you can know how many picture frames are available through the TagsEditor.WMA_PictureFrameCountGet method.

 

Identifiers of frames available inside the WMA tag can be enumerated using the combination of the TagsEditor.WMA_UniqueFramesCountGet and TagsEditor.WMA_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.WMA_SaveChanges method.

Frames related to metadata can be removed from the WMA tag through the TagsEditor.WMA_RemoveAllFrames method: in this case the removal is performed directly on the original sound file.

 

 

OGG Vorbis

 

Vorbis metadata, called Vorbis comments, supports metadata tags similar to those implemented in the ID3 standard for MP3. All strings are encoded as UTF-8. Music tags are typically implemented as strings of the form "[TAG]=[VALUE]", for instance, "ARTIST=The big band". The tags are case-insensitive, thus typing "ARTIST=The big band" would be the same as "artist=The big band".

 

You can know if the OGG Vorbis tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_OGG this would mean that the OGG Vorbis tag is available.

 

Predefined text frames can be read through the TagsEditor.OGG_TextFrameGet method and modified through the TagsEditor.OGG_TextFrameSet method.

User defined text frames can be read through the TagsEditor.OGG_UserFrameGet method and modified through the TagsEditor.OGG_UserFrameSet method.

 

Identifiers of frames available inside the OGG tag can be enumerated using the combination of the TagsEditor.OGG_UniqueFramesCountGet and TagsEditor.OGG_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.OGG_SaveChanges method.

The OGG Vorbis tag can be removed through the TagsEditor.OGG_RemoveTag method: in this case the tag removal is performed directly on the original sound file.

 

 

MP4

 

There is no official MPEG standard on how to embed metadata tags in MP4 files. Apple iTunes therefore started to use their own solution in order to be able to store metadata tags. Those iTunes tags quickly became the de-facto standard for metadata tags within MP4 files. Metadata tags within MP4 files are stored within so-called "boxes" (also known as "atoms").

 

You can know if the MP4 tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_MP4 this would mean that the MP4 tag is available.

 

The list of supported MP4 frames, with related identifiers and methods to access stored information, can be found on the table below:

 

Supported frame types

Frame identifiers

Multiple

Related methods

Text-based frames

©alb, ©ART, ©aut, aART, tmpo, catg, dsk, disk, ©cmt, ©wrt, cpil, ©day, ©cpy, ©day, ©des, ©inf, ©dir, ©dis, ©too, ©grp, keyw, ©lyr, ©nam, ©url, ©ope, ©fmt, ©src, ©prf, rate, ©prd, ©wrn

No

TagsEditor.MP4_TextFrameGet

TagsEditor.MP4_TextFrameSet

Picture frames

 

Yes

TagsEditor.MP4_PictureFrameAddFromBitmap

TagsEditor.MP4_PictureFrameAddFromFile

TagsEditor.MP4_PictureFrameAddFromMemoryFile

TagsEditor.MP4_PictureFrameBitmapGet

TagsEditor.MP4_PictureFrameCountGet

TagsEditor.MP4_PictureFrameFileGet

TagsEditor.MP4_PictureFrameMemoryFileGet

TagsEditor.MP4_PictureFrameMimeGet

TagsEditor.MP4_PictureFrameRemove

TagsEditor.MP4_PictureFrameSizeGet

 

The "Multiple" column specifies that there may be more than one picture frame available inside the tag; you can know how many picture frames are available through the TagsEditor.MP4_PictureFrameCountGet method.

 

Identifiers of frames available inside the WMA tag can be enumerated using the combination of the TagsEditor.MP4_UniqueFramesCountGet and TagsEditor.MP4_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.MP4_SaveChanges method.

Frames related to metadata can be removed from the MP4 tag through the TagsEditor.MP4_RemoveAllFrames method: in this case the removal is performed directly on the original sound file.

 

 

APE

 

APE tags are closer to Vorbis comments than ID3 tags. Like Vorbis comments, they are unstructured key/value pairs.

 

You can know if the APE tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_APE this would mean that the APE tag is available.

 

Predefined text frames can be read through the TagsEditor.APE_TextFieldGet method and modified through the TagsEditor.APE_TextFieldSet method.

User defined text frames can be read through the TagsEditor.APE_UserFieldGet method and modified through the TagsEditor.APE_UserFieldSet method.

 

Identifiers of frames available inside the APE tag can be enumerated using the combination of the TagsEditor.APE_UniqueFramesCountGet and TagsEditor.APE_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.APE_SaveChanges method.

The APE tag can be removed through the TagsEditor.APE_RemoveTag method: in this case the tag removal is performed directly on the original sound file.

 

 

FLAC

 

FLAC has it's own native tagging system which is mostly identical to that of OGG Vorbis described above, indeed they are sometime called alternately "FLAC tags" and "Vorbis comments". Respect to the Vorbis tagging system, FLAC allows embedding pictures as well as seen for the ID3V2, WMA and MP4 formats.

 

You can know if the FLAC tag is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_FLAC this would mean that the FLAC tag is available.

 

The list of supported FLAC frames can be found on the table below:

 

Supported frame types

Multiple

Related methods

Text-based frames

No

TagsEditor.FLAC_TextFrameGet

TagsEditor.FLAC_TextFrameSet

Picture frames

Yes

TagsEditor.FLAC_PictureFrameAddFromBitmap

TagsEditor.FLAC_PictureFrameAddFromFile

TagsEditor.FLAC_PictureFrameAddFromMemoryFile

TagsEditor.FLAC_PictureFrameAddURL

TagsEditor.FLAC_PictureFrameBitmapGet

TagsEditor.FLAC_PictureFrameCountGet

TagsEditor.FLAC_PictureFrameFileGet

TagsEditor.FLAC_PictureFrameInfoGet

TagsEditor.FLAC_PictureFrameMemoryFileGet

TagsEditor.FLAC_PictureFrameRemove

TagsEditor.FLAC_PictureFrameSizeGet

TagsEditor.FLAC_PictureFrameTypeGet

 

The "Multiple" column specifies that there may be more than one picture frame available inside the tag; you can know how many picture frames are available through the TagsEditor.FLAC_PictureFrameCountGet method.

 

Identifiers of frames available inside the FLAC tag can be enumerated using the combination of the TagsEditor.FLAC_UniqueFramesCountGet and TagsEditor.FLAC_UniqueFramesIdGet methods.

 

Modifications performed by modifying an existing frame or by adding a new one only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.FLAC_SaveChanges method.

Frames related to metadata can be removed from the FLAC tag through the TagsEditor.FLAC_RemoveAllFrames method: in this case the removal is performed directly on the original sound file.

 

 

WAV Chunks

 

WAV files are based upon the RIFF format which consists entirely of "chunks"; some of these chunks allows storing metadata; Active Sound Editor supports the reading and writing of the following type of chunks:

 

CART
BEXT
DISP
LIST INFO

 

You can know if any of the chunks above are available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the combination of any of the following flags, this would mean that the chunks are available: TAG_FLAG_WAV_CART, TAG_FLAG_WAV_BEXT, TAG_FLAG_WAV_DISP and TAG_FLAG_WAV_LIST_INFO.

 

 

CART Chunk

 

The CART chunk contains fields and attributes that a large number of broadcast systems use to describe an audio file. Its full specifications can be found inside the CartChunk.org web site.

 

You can know if the CART chunk is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_WAV_CART this would mean that the CART chunk is available.

 

Text fields can be read through the TagsEditor.WAV_CartChunkTextFieldGet method and modified through the TagsEditor.WAV_CartChunkTextFieldSet method.

Time markers can be read through the TagsEditor.WAV_CartChunkTimeMarkerFieldGet method and modified through the TagsEditor.WAV_CartChunkTimeMarkerFieldSet method.

 

Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.WAV_SaveChanges method.

The CART chunk can be removed through the TagsEditor.WAV_CartChunkRemove method: in this case the chunk removal is performed directly on the original sound file.

 

 

 

BEXT Chunk

 

The BEXT chunk (“Broadcast Audio Extension”) adds to the RIFF format extra parameters needed for the exchange of material between broadcasters.

 

You can know if the BEXT chunk is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_WAV_BEXT this would mean that the BEXT chunk is available.

 

Text fields can be read through the TagsEditor.WAV_BextChunkTextFieldGet method and modified through the TagsEditor.WAV_BextChunkTextFieldSet method.

Binary fields can be read through the TagsEditor.WAV_BextChunkBinaryFieldGet method and modified through the TagsEditor.WAV_BextChunkBinaryFieldSet method.

 

Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.WAV_SaveChanges method.

The BEXT chunk can be removed through the TagsEditor.WAV_BextChunkRemove method: in this case the chunk removal is performed directly on the original sound file.

 

 

 

DISP Chunk

 

The DISP chunk allows entering a text string to display on the user interface when the WAV file is loaded.

 

You can know if the DISP chunk is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_WAV_DISP this would mean that the DISP chunk is available.

 

The text field can be read through the TagsEditor.WAV_DisplayChunkTextGet method and modified through the TagsEditor.WAV_DisplayChunkTextSet method.

The DISP chunk can be removed by passing an empty string to the TagsEditor.WAV_DisplayChunkTextSet method.

 

Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.WAV_SaveChanges method.

 

 

 

LIST INFO Chunk

 

The LIST chunk can contain a list of frames (sub-chunks) of type INFO, each of them containing a different text string. As for other kinds of chunks, each INFO frame is defined by a four characters identifier (FOURCC). Some identifier has already been standardized by the EXIF 2.3 specification (for esample 'IART' for 'Artist', 'ICMT' for 'Comments' or 'ICOP' for 'Copyright'), but the user may create new custom ones.

 

You can know if the LIST INFO chunk is available by checking the value returned by the TagsEditor.ALL_AnalyzeSoundOnEditor or TagsEditor.ALL_AnalyzeSoundFile methods: if it should contain the flag TAG_FLAG_WAV_LIST_INFO this would mean that the LIST INFO chunk is available.

 

Identifiers of INFO frames available inside the LIST chunk can be enumerated using the combination of the TagsEditor.WAV_ListInfoChunkUniqueFramesCountGet and TagsEditor.WAV_ListInfoChunkUniqueFramesIdGet methods.

 

Single INFO frames can be read through the TagsEditor.WAV_ListInfoChunkFrameGet method and modified through the TagsEditor.WAV_ListInfoChunkFrameSet method.

Single INFO frames can be removed by passing an empty string to the TagsEditor.WAV_ListInfoChunkFrameSet method.

 

Modifications only happen in memory so, in order to store them inside the original sound file, there is the need to call the TagsEditor.WAV_SaveChanges method.

The LIST INFO chunk can be removed through the TagsEditor.WAV_ListInfoChunkRemove method: in this case the chunk removal is performed directly on the original sound file.

 

 

 

 

Samples of usage of tags editing through the TagsEditor object in Visual C++ and Visual Basic 6 can be found inside the following samples installed with the product's setup package:

- TagsEditor

- WavChunkEditor