-
I was hoping there was a straightforward way of playing files on top of each other. And even after putting the playback processors into a plugin processor, the only sound being rendered is the first argument. What I had imagined: bass = engine.make_playback_processor("bass", load_audio_file("Projects/_/_/inputs/SL_LC_Synth_Bass_85_G_03.wav"))
synth = engine.make_playback_processor("synth", load_audio_file("Projects/_/_/inputs/SL_LC_Synth_Melody_90_G_17.wav"))
tempo = engine.make_playback_processor("drums", load_audio_file("Projects/_/_/inputs/SL_LoFi_Drum_Tops_80_01.wav"))
bass.record = True
synth.record = True
tempo.record = True
graph = [
(bass, []), # Playback has no inputs.
(synth, []), # Playback has no inputs.
(tempo, []), # Playback has no inputs
]
engine.load_graph(graph)
engine.render(30)
audio = engine.get_audio()
wavfile.write('Projects/__/__/outputs/samples.wav', SAMPLE_RATE, audio.transpose())
show_audio(audio) and using a plugin only renders the first argument in the [] graph = [
(bass, []), # Playback has no inputs.
(synth, []), # Playback has no inputs.
(tempo, []), # Playback has no inputs
(reverb_processor, ["synth", "drums", "bass"])
] In this example, only synth is rendered. In this setup, like the documentation says, the audio that's played and written to the wavfile is the last one. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
I think in this case you want to use the Add Processor. You also don't need to set add_processor = engine.make_add_processor("added", [1., 1., 1.])
# you can optionally do the following line whenever you want
add_processor.gain_levels = [1., 1., 1.]
graph = [
(bass, []), # Playback has no inputs.
(synth, []), # Playback has no inputs.
(tempo, []), # Playback has no inputs
(add_processor, ["synth", "drums", "bass"]),
(reverb_processor, ["added"])
] |
Beta Was this translation helpful? Give feedback.
-
That worked! Thank you! |
Beta Was this translation helpful? Give feedback.
I think in this case you want to use the Add Processor. You also don't need to set
.record
to True, unless you care about the intermediate signals. So I think this snippet will help.