Subject:Using FourCC
Posted by: PC AT
Date:12/16/2008 10:12:11 AM
Hi there, I'm trying to maximize the use of the FourCC implementation; however, after dissecting the SfSummaryInfo Class from the API help file and carefully combing the “Dump Summary Info.cs” sample code I cant read/write to the file. I’m successful using (the very limited) IsfFileSummaryInfo by modifying the sample code “Modify Summary Information.cs” For example:
Works well. I can read and write the info to the file. I would like to know how to convert the previous sample to FourCC. I attempted this:
I know I’m not structuring the call correctly. I’m proficient in VB and new to C#. The reason for me to use FourCC is to get the IPRD property, which is not exposed on the IsfFileSummaryInfo. Any help is greatly appreciated. Thanks, PC AT |
Subject:RE: Using FourCC
Reply by: _TJ
Date:12/16/2008 2:02:33 PM
I"m not certain I Understand the question. But here is some C# sample code that might be helpful.
|
Subject:RE: Using FourCC
Reply by: PC AT
Date:12/16/2008 2:59:55 PM
Thanks TJ I'm half way there. I used the code you suggested (minor typo) and it helped me to generate the FourCC. Where is the documention for MakeFourCC?
I verified the IPRD by dumping it to the OutputText window. Unfortunately I’m not getting the new value for IPRD with the last line of code. |
Subject:RE: Using FourCC
Reply by: _TJ
Date:12/16/2008 4:58:34 PM
Once again, I don't understand the question, the last line sets the value, it doesn't get it. sorry about the typo. tj |
Subject:RE: Using FourCC
Reply by: PC AT
Date:12/16/2008 5:18:27 PM
Sorrry Tj for the cryptic question. I’m generating the information to “stuff” in a wav file, artist, album, etc. by properly filling the wav riff header of the file, and the FourCC codes seem to do the trick. Unfortunately only the 13 that are available via the ISfFileSummaryInfo Properties are not enough. I needed to populate other wave riff codes like IPRD and IARL to name a couple. Now that I took the time to learn more about the “trick” you shared with me of MakeFourCC I was able to create what I needed. After playing with both the SfSummaryInfo and ISfFileSummaryInfo, this section of code will do the trick. Thanks TJ for giving me the push I needed!
Thanks, PC AT |
Subject:RE: Using FourCC
Reply by: _TJ
Date:12/16/2008 5:58:45 PM
You seem to have it figured out. just FYI, the SfSummaryInfo class contains an enum with a pre-defined set of FourCC codes, and a separate enum with English friendly names for them. Here's the list.
and here's how you use them
Thanks for the kind words. tj |
Subject:RE: Using FourCC
Reply by: PC AT
Date:12/16/2008 6:20:43 PM
Great! That will simplify my code. Thanks, PC AT |