How to cut audio file in Go?

Is there any way to cut audio from timestamp to timestamp in Go?

How is the audio stored and what does timestamp here mean?

If you know the frame positions of uncompressed audio, it’s more or less copying an array, or writing it to a file. If compressed, you need to be aware that this probably also involves blocks/chunks of audio and is not as trivial. If timestamps means you have put meta data into a wave file, like loop points, that would again need different code.

It’s maybe a good idea to describe what the goal of your project is, and/or be very specific when asking how things can work. Also, if you dig further into audio, try to ask it for C/C++ in the DSP forum on KVR. https://www.kvraudio.com/forum/viewforum.php?f=33

For audio stuff, Go offers not really a substantial amount of included libraries, so the best way - I would say - is to get the audio knowledge in C/C++ and convert it to Go later. The difference is mainly the language and that you probably will end up using syscall for dynamic linking to some libraries.

Doing from scratch is quite cumbersome and difficult (e.g analyzing the sound file header, parsing, etc) . You can always resort to bindings. I did use sox and ffmpeg commands directly to treat sounds a long time ago and I’m pretty sure there are bindings in Go, but you could always resort to a simple bash script for that kind of stuff. Is there any requirements for programmatically doing that? And this might be of help https://github.com/avelino/awesome-go#audio-and-music.