Save samples from song

Yoho!

If I name all samples in the sampleslots properly, is there an easy way to export all samples into some folder instead of saving one and one? This would be fantastic :)

Cheers,
Klaus

Just extract the xrns file as it is essentially only a zip file and dont use full paths. That should give you all the samples in one neat folder.

Click the first sample, then shift-click the last sample, rightclick and select “save all samples as”. Select a location in the explorer dialog and everything is saved to disk under its own name.

Well, that would be absolutely brilliant ofcourse, but it does not work. I do not have the option to “Save all samples as” when I right click. I dont even have it as a greyed out option. Am I doing something silly as usual again?

I have it right here:

If it would be a tool, i would have looked it up which one it was, but the shortcut doesn’t indicate this is a tool option.
Which Renoise version do you have? Do you have 2.8.1?

Yes, but these are just the samples layered in one sampleslot, right? I mean being able to save the samples in the list on the upper right. I use render to sample a lot as I work on new sounds, and I would like to be able to save all these when I am done (without doing it manually one and one). Thanks VV for your help! :)

Okay, you mean instrument slots. On the upper right are instrument slots, the slots that you see multi-selected in my image are the sample slots, hence my answer, sorry for the disappointment then :)

scriptable?

Sorry VV, I am bad with the Renoise jargon, really my bad - since you were correct :) And yeah… scriptable? I would find this quite handy when just working with sounddesign and making a bunch of sounds (mostly drums for my part)… and just bounce them down as I go… and in the end just one-click and export to folder. That would be kick ass :D

Even a script to move all samples from instruments into a single instrument, allowing the native Save All Samples from there, might be a workaround…

Do all your Instruments only have a single sample? Or could you safely ignore any multi-sampled Instruments? (For your case specifically.) Do you want the name of the Instrument used? Not the one of the sample inside it…

Heya mate! In my case… only one sample in the instrument slot. To be honest, I never use multisampled instruments. I have never in my life done this :) If the name of the sample could be the name in the instrumentslot - that would be ACE! And yeah… I would have no problem with that workaround at all. How many samples can be stored in a single instrument? (I guess I should know these thigs seeing I spend 2-3 hours in Renoise every single day hehe).

Thanks sir!

Let me see what the required ingredients are for this soup:

– Has sample data?
renoise.song().instruments.samples.sample_buffer.has_sample_data
renoise.song().instruments.samples.sample_buffer:save_as(filename, format)
renoise.song().instruments.samples.name, _observable

Unfortunately, renoise.song().selected_instrument_index only returns the actual cursor of the instrument and not its selected range.
There is also no “.is_selected” property available for multiple selected instruments.

So it could be solved with scripting, but then it would be necessary to set up a start and end instrument number (manually define the range in the tool GUI) and then let the tool save the samples according to if the buffer of that sample slot has data.

original post asks for ALL samples, so no need to set start and end. Sure saving to file would be possible but if work eases off today (or over the weekend) I might have a look at creating my simplified version which I know I have the skills to do, without having to battle with the differences of saving in different operating systems etc.

I think sample per instrument limit was 255, possibly 127… Got a feeling it’s the same as the number of instrument slots so you should be OK there.

I have made an attempt to do a very simplified version… (does incorporate multiple os support, but i can’t test the *nix side, so would be a great help if someone can report back on it)

Faster achieved and more complete than I would have done. Kudos due :)

Holy mother of! I am not able to test it out now, but will on sunday. Thank you VV and kazakore - you both rock! Also, the Beginners Questions is now my new favorite section on these forums :)

This works well so far VV - fantastic! :)

Wishlist for improvements are only two that I can think of right now:

A. Save all to one folder (this one is semi-important since this function is only about one thing: saving time :)
B. Use name of instrumentslot as samplename, and not the imported sample.

For B, if two slots share the same name, just add a 1 or something smart in the end. Is this possible?

I also think I found one bug. Does it save to .flac regardless if you choose .wav of .flac?

Cheers, hugs and free cookies to you VV,
Klaus :)

I will have a look at it when i have the time.
I’m not sure about the wav or flac saving bug, i simply submit the type description for the parameter that the API requires and use the same description to add the extension to the file.

Wishlist consideration:
Save all to one folder should not be too much of a problem, save samples as instrument name will only be possible if the instrument indeed only contains just one sample.
Renaming by adding a figure is already being done, just not smart enough yet.

Yes, I think in this case it should be understood that the instrument only contains one sample. If one wishes to stack samples in a slot, they could easily use the allready existing function of saving samples to a folder :)

Thanks again VV! This is really helpful… at least for me hehe!

Cheers,
Klaus

Tool updated.
It performs quite a few different constructions now.
including saving everything to one folder.