Reputation: 5598
I'd like to write a custom/user defined field in a mp4 file with jaudiotagger
For FLAC files, I can do this with VorbisCommentTagField
.
For MP3 files using ID3v24Tag
I can do this with a ID3v24Frame
as ID3v24Frames.FRAME_ID_USER_DEFINED_INFO
Is there any way to do this in mp4?
Looks like there is a Mp4FreeBox
, but I can't find a public API to use it.
Moreover, does jaudiotagger
expose any public API to set custom tags (key/value) in an unified way? Could not find any, and I need to treat each format independently.
Thank you
Upvotes: 0
Views: 237
Reputation: 13120
For Mp4 you want to use a reverse dns type tag using this constructor but there is not a way to create this as aprt of a unified api. Jaudiotagger does not currently provide a public api for creating custom tags, this is issue https://bitbucket.org/ijabz/jaudiotagger/issues/8/no-facilty-to-create-user-defined-frames
Mp4FieldKey(String issuer, String identifier, Mp4FieldType fieldType, Tagger tagger)
{
this.issuer = issuer;
this.identifier = identifier;
this.fieldName = Mp4TagReverseDnsField.IDENTIFIER + ":" + issuer + ":" + identifier;
this.subclassType = Mp4TagFieldSubType.REVERSE_DNS;
this.fieldType = fieldType;
this.tagger = tagger;
}
Upvotes: 1