Converting 8-bit PCM Stream into FLAC Stream
Hello,
I have an application, that receives an audio stream in the form of a byte[] that is encoded in g.711, which is then decoded into 8-bit PCM.
I want to encode the PCM stream into a FLAC stream, which i can then send to a different application via a socket.
I don't know how to encode it from PCM to FLAC, can somebody with experience help me?
5 Replies
what kind oif answer are you looking for?
generally tho, when working with mediaformats ffmpeg is usually a good pick
ffmpeg is terrible if you want to use it in another app
the native api is horrible
and using it commandline is janky and terrible if you want to do stuff like streaming
you probably want to PInvoke libFLAC here instead
there are wrappers that make your live easier there but i respect your opinion...
tbh i didnt quite think about it.. but yea if your goal is only flac libflac would be a better choice..
from what I've seen, most wrappers just start the commandline tool lol
cause the native api is 1000 LOC for converting audio file to another format levels of bad
Thanks for the answers!