On 8/24/2010 12:20 PM, Bill Cunningham wrote:
> I want to cut a large part out of an AVI that is called the "JUNK"
> section which is basically padding. As a learning experience. I must find
> offset 340 or so in the particular AVI I amd interested in. I think I
> understand using f*pos and fseek function how to get to the offset but how
> would I code where to stop? When all's said and done I guess I could
> rewind() and fclose() the stream.
>
> Bill
Each section ("chunk"? FOURCC....? Been a while...) should have the
section length stored somewhere. Parsing an AVI is a bit more complex
than just jumping to a specific offset. Removing a section is also a
bit more complex than just cutting it out. All the offsets in the AVI
will likely need to be updated. The task is not as simple as it seems
despite AVI being one of the simplest and most widely documented video
container formats. I'm assuming, of course, you still want the AVI to
still function properly in a video player after you are done massacring it.
--
Thomas Hruska
CubicleSoft President
Barebones CMS is a high-performance, open source content management
system for web developers operating in a team environment.
An open source CubicleSoft initiative.
Your choice of a MIT or LGPL license.
http://barebonescms.com/