Hi,
I have a pretty big wav file and want cut off a small bit of the front, or a small bit of the back. To get and idea of size says its 2MB front or back bits from a 1GB file.
So there are tools available, such as sox for this. In fact there's a number of ways .. but most involved creating a new large file (less the bits taken off): transfering to disk and overwriting the original file with the new truncated file. Which is all very slow.
Seeing as the majority of the data is not changing at all, I was wondering if it wasn't possible to leave the majority of the file as is, and recreate the boundaries (front or back) of the file in some way, to make it all much quicker.
I was lookign for suggestions. Right now I'm looking at the possibillities of mmap, and then I'll look at any apis that the ext2 filesystem may offer. It's not so important about it being a wav, even doing it to a text file is fairly interesting.
Many thanks in advance !