Forum > Audio and Video
Trim audio file
FelizKatus:
Hi to all :D
I need to create a simple program for cutting an audio file from one specific moment to another without losses.
It is desirable that the program could work not with one, but with several of the most common formats.
With what library can I do this?
I would be very grateful for:
- a link to the relevant documentation page
- a link to a code example
- a link to some tutorial describing a similar application
- a link to a source code of similar application
If anyone knows a similar application or tutorial for Embarcadero Delphi or CBuilder, that would also work for me.
Thanks :)
cdbc:
Hi
Hmmm, for fpc/lazarus there's UOS, you can have a 'LookSee' for yourself...
Regards Benny
eta: Ohh, and welcome to the forum :D
Zvoni:
general overview:
https://wiki.freepascal.org/Audio_libraries
IIRC, Thaddy has used the BASS-lib extensively (?)
All said: Probably the most simple one would be to pass the chosen parameters to a TProcess calling ffmpeg CLI
something like
ffmpeg -ss StartSecond -i MyInputFile.mp3 -to EndSecond MyOutputfile.mp3
cdbc:
Hi
If need be, @Metis has the bindings for libffmpeg...
Regards Benny
eta: I think the attached are the latest bindings...
FelizKatus:
Hi Benny :-)
Thanks for your reply, I will study the documentation. But on this page:
https://wiki.freepascal.org/Multimedia_Programming
it is written that UOS is used for playing audio files, not for editing (if I am not mistaken, the wiki is down for three days, I can not check).
I see similar applications written using the FFmpeg library, for example:
https://github.com/mifi/lossless-cut?tab=readme-ov-file
I have little experience in programming. Maybe you know some tutorial or open source application to start working with this library?
--
Thanks for your reply, Zvoni :-)
I can not find an application called Teddy, can you give me a link?
I know how to trim a file from the command line, but I need an application with a graphic interface.
Thanks for the recommendation bass library, I will read the documentation. I would be very grateful if you give me a link to a specific documentation page or examples. As I said, I don't have much experience in programming :-)
Navigation
[0] Message Index
[#] Next page