Thursday 27 August 2020

How to convert stream consumer to stream pass through?

Hi, I’m trying to read the metadata of a audio file while it’s moving through my stream pipeline.I’m using the music-metadata library, fortunately it works with streams. But unfortunately I can pipe data into a function but I am unable to pipe that same data out when the metadata is read.Here is the example snippet the library owner provided.https://github.com/Borewit/music-metadata/blob/master/example/javascript/stream.jsI’m just wondering how I would go about turning this stream consumer into something I can implement into my pipeline then use a callback function to get the audio metadata?I’m considering duplicating the stream using .data but I’m imagining that would cause massive memory bloat.Thanks.

Submitted August 27, 2020 at 01:24PM by haulwhore

No comments:

Post a Comment