Hi,

I have written an application that uses the FLAC C API to insert an
application metadata block into a FLAC file. Everything appears to be
working, but I have one nagging issue.

I have used all my best google and source code searching skills and I cannot
for the life of me find an API call to set the Application ID value in my
metadata object. I am currently working around the issue by setting the
value manually, but that hurts my good coding sense.

(Note: I have already registered my ID.)

Is there an API call to set the application metadata ID?

Here's what I'm doing:
    myFlacMetadata = FLAC__metadata_object_new
(FLAC__METADATA_TYPE_APPLICATION);
    FLAC__metadata_object_application_set_data (uitsFlacMetadata,
myMetadata, myMetadataSize, FALSE);

    /* this is a BIG FAT NO NO, but I cannot for the life of me find any way
in the FLAC API to set */
    /* the Application block application ID, therefore I am going rogue and
setting it explicitly */

    myFlacMetadata->data.application.id[0] = 'M';
    myFlacMetadata->data.application.id[1] = 'Y';
    myFlacMetadata->data.application.id[2] = 'I';
    myFlacMetadata->data.application.id[3] = 'D';


Thanks for any help.

-chris
_______________________________________________
Flac-dev mailing list
[email protected]
http://lists.xiph.org/mailman/listinfo/flac-dev

Reply via email to