Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: fLaC tag question (Read 4108 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

fLaC tag question

does it always appear as firsth field after flac id ? if not, should it be definetly reported as error or should i search for it through the rest of blocks ?

[EDIT]
end, how about the other blocks ? is VORBIS_COMMENT always after STREAMINFO ? SEEKTABLE ?
another thing i would love to know is, if blocks APPLICATION and CUESHEET are editable.
thanks in advance for reply

fLaC tag question

Reply #1
Quote
does it always appear as firsth field after flac id ? if not, should it be definetly reported as error or should i search for it through the rest of blocks ?

[EDIT]
end, how about the other blocks ? is VORBIS_COMMENT always after STREAMINFO ? SEEKTABLE ?
another thing i would love to know is, if blocks APPLICATION and CUESHEET are editable.
thanks in advance for reply
[a href="index.php?act=findpost&pid=324892"][{POST_SNAPBACK}][/a]


The STREAMINFO block is the (mandatory) first block after the flac id, so yes it would be an error if it wasn't the first.
I think after the STREAMINFO block the other blocks could appear in any order.

fLaC tag question

Reply #2
i have just checked it with foobar, and it plays the track as well, no errors, no problem. but is that just foobar 'protection', or this comes from the top - fLaC developers ?

fLaC tag question

Reply #3
for file storage, each native FLAC stream must contain exactly one STREAMINFO block and it must be the first.  the rest can come in any order.

in Ogg FLAC the VORBIS_COMMENT is also required and must be second.  see http://flac.sourceforge.net/ogg_mapping.html

all metadata blocks are editable via the metadata API.  metaflac currently can remove/add whole blocks and also edit STREAMINFO, SEEKTABLE, and VORBIS_COMMENT contents.

Josh

p.s. your app can be as lenient as it wants for reading FLAC files, but to be compliant it should write only legal files.

fLaC tag question

Reply #4
thanks for the details about the blocks order. however, i meant something different when i asked about editing some of them. i need to divide the metadata blocks into two groups. one of them can be edited without any loss and damage to the file (something that can be compared to the tags), and the second that is crucial, unmovable and/or uneditable. at the moment i see this as following:

uneditable:
STREAMINFO
(SEEKTABLE - only if file can be played without it, and more, if it can be recomputed (restored) after deleting, which makes such deletion lossless, still dunno that)
VORBIS_COMMENT vendor string (can be removed only with whole block)

editable:
PADDING (after each VORBIS_COMMENT change, changes)
APPLICATION (?)
VORBIS_COMMENT
CUESHEET (?)
(SEEKTABLE  ?)

(of course, i am talking about corect editing, full block removing or changing its content and declared size)

can you help me, jcoalson, and say if the lists above are corect ?

fLaC tag question

Reply #5
correct except SEEKTABLE.  files can be played/seeked without it, and it can be regenerated later, e.g. with metaflac --add-seekpoint

Josh

fLaC tag question

Reply #6
Quote
correct except SEEKTABLE.  files can be played/seeked without it, and it can be regenerated later, e.g. with metaflac --add-seekpoint

Josh
[a href="index.php?act=findpost&pid=325412"][{POST_SNAPBACK}][/a]


great, thank you  !