Hey there! Le sam. 17 nov. 2018 à 09:35, Bernhard Schmidt <b...@pluto24.com> a écrit : > I'm trying to use liquidsoap for merging multiple input files into a > single stream, which then goes out to icecast. This raises a couple of > questions: (hope you don't mind I list them here all at once)
Of course not! > 1) So far mixing/merging seems to work with add(), although I'm not sure > if this is the right way. (e.g. what is the difference to mix()?) Are > there any limitations? add() is the basic operator for sources. mix is more evolved, with telnet interface and etc. Unless you plan on using that you should stick with add. > 2) Apparently the more sources I add, the lower the volume gets. > normalize() didn't seem to make a difference, so I added an amplify() > with the volume equals the number of input-sources. Is this the right > way to go? > > -------- > pl0 = single("file1.wav") > pl1 = single("file2.wav") > pl1 = single("file3.wav") > > mixed = amplify(3.,add([pl0,pl1,pl2])) > -------- By default, if you have 3 sources, the volume of each source is divided by 3, and etc. This is to avoid clipping when adding sources. However, if 2 of the added source, for instance, are silent, this will just end up dividing the volume of the last one by 3. I don't think that there's an easy default here that can work for everybody. You can disable the normalization or use custom weights. I believe the amplify above is equivalent to just doing: mixed = add(normalize=false,[pl0,pl1,pl2]) > 3) When I want the sources to have different volumes, is it > better/faster to use the weights in add(), or run each through an > amplify() function? I think it makes more sense to use custom weights just because that processing is already going to happen there. Adding separate amplify() shouldn't be very CPU intensive, though. > 4) Is it possible to add an reverb effect? We support LADSPA plugins. You should be able to find a ladspa reverb plugin and use it with liquidsoap. > 5) What is the best format for the sources to work with? Lossless I > guess, WAV? FLAC? > I'm intending to start multiple liquidsoap instances, so performance is > important.. Internally, liquidsoap decodes everything and manipulates raw PCM audio. Decoding isn't very CPU intensive but if you really want to minimize that part you can use WAV input files. Hope this helps, all the best with your project! Romain
_______________________________________________ Savonet-users mailing list Savonet-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/savonet-users