Hydrogen Question - Replacing instruments in a song?

Support & discussion regarding DAWs and MIDI sequencers.

Moderators: MattKingUSA, khz

Post Reply
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Hydrogen Question - Replacing instruments in a song?

Post by SR »

I posted this over on the Hydrogen forums, but figured I'd post it here to see if anyone can help:

I am curious if this is possible either through the GUI or by editing the h2song file:

I have a song I've finished using a particular kit, but once it's recorded along with other instruments I've decided that I really hate the snare sound. Is it possible to replace the old snare instrument with another without having to re-write the pattern for that instrument?
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

Hi, SR.
Hydrogen keeps its installed drumkit samples in /home/yourhomedir/.hydrogen/data/drumkits/kitname

you should be able to replace the samples there.
BUT - WARNING! - you should give the new samples the Exactly The Same Name as the old ones so that they appear in the same order when loaded in Hydrogen or you will get in a right mess.

I would Strongly Recommend making a renamed copy of the drumkit folder to a new one in ...../data/drumkits/
work on the new one and load that it into your project, then you will be able to reload the old kit if you make a mistake.

If you need to update your h2drumkit file, the process is a bit more fiddly -
let me know if you want to do this and i'll post the details.
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Re: Hydrogen Question - Replacing instruments in a song?

Post by SR »

Hi Gary,

I was hoping to avoid that approach. I'd like to keep the drumkit intact, but just substitute a different snare for a particular song. I guess there's no silver bullet for this type of thing...
User avatar
Yeri
Established Member
Posts: 158
Joined: Tue Dec 09, 2008 6:33 pm
Location: Spain

Re: Hydrogen Question - Replacing instruments in a song?

Post by Yeri »

Hi SR,

this can be done easily from the hydrogen gui.
You only have to select the instrument (i.e. the snare) from the hydrogen gui and reload other sample(s).
You can do it from the 'Layers' section of the instrument, where you can see the sample(s) played at each hit-strength.
Finally you save your drumkit, et voilà.
studio32

Re: Hydrogen Question - Replacing instruments in a song?

Post by studio32 »

In the latest beta release, that's pretty simple afaik. Just drag the right snare to the right place. If the snare is not in the drumkit, you have to edit the drumkit.
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Re: Hydrogen Question - Replacing instruments in a song?

Post by SR »

Yeri wrote: You only have to select the instrument (i.e. the snare) from the hydrogen gui and reload other sample(s).
You can do it from the 'Layers' section of the instrument, where you can see the sample(s) played at each hit-strength.
Hi Yeri,

I'm using the RockStock kit purchased from Analogue Drums. It's 4 snare instruments (2 RH + 2 LH) each with 16 layers. Replacing the layers is one option, but there are 64 layers to replace. It would actually just be easier to delete the instrument out of the song, add a new one and then recreate the patterns from scratch.

I'm assuming what Studio32 suggested is that I could just drag a snare from one of the kits in my library, but on the version I'm running (the April RC) it just inserts the snare into the list and doesn't replace the one I don't like. Is there a newer version that has the behavior I'm looking for?

On another note, the Rockstock kit from Analogue Drums is pretty nice (except for the snare...which is probably why all of their demos use the snares from "Snare City"). If anyone decides to purchase it, I've create a drumkit.xml file that might save you some time adding it to your Hydrogen library. Just let me know.

--SR
User avatar
Yeri
Established Member
Posts: 158
Joined: Tue Dec 09, 2008 6:33 pm
Location: Spain

Re: Hydrogen Question - Replacing instruments in a song?

Post by Yeri »

I'm using the RockStock kit purchased from Analogue Drums
I use it as well ! :D
Replacing the layers is one option, but there are 64 layers to replace
I use this useful script to automatically create layered hydrogen drumkits that GarryO generously shared with us :)
You must create a directory for the drumkit and one subdirectory containing all the layers from each instrument.
In the final drumkit the layers will be ordered according to the order which they are listed with an 'ls'.. but that's not a problem because usually different layers are named exactly the same with a number in ascending order according with its hit-strength.
For the Analogue Drums rockstock you'll only need to separate the samples of each instrument into subdirectories and put them all into a directory
When everything is done just run: " ./makeit drumkit_dir " and the .h2drumkit file will be created in $HOME (everything in layers and so)

Hope it helps.. don't hesitate to ask if you have any problems.

Gerard.
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

Yeri: I completely missed the fact that you could do this through the layers
tab. I looked but did not see: what a twerp i am!

SR: if you copy the drumkit folder and rename it, the original will remain intact, and the new one will also appear in Hydrogen's sound library.
Load the the new kit into your project, then save it.

However I missed one (another? ) thing: If you don't name the new replacement samples exactly the same as the old ones, not only do you risk them appearing in the wrong order in your patterns, but you will also have to edit the kit's drumkit.xml file to match.
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

After further thought ( I'm starting to get the hang of this thinking lark :D )
I can see you that if you followed my suggestion you would then have the problem of renaming a large number of samples, yes?
Batch renaming progs are available, but i've not used any of them, so can't make a recommendation.
It looks like you can either - as Yeri suggests - build a new kit from scratch mostly replicating the original except for the snare, or add the new snare as in Studio32's suggestion and reprogram the patterns.
No silver bullet, I'm afraid. Sorry I couldn't be of more help.
Do let us know what you decide and how you get on, though.
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

Hey, Sr, what about this:

Copy the drumkit folder you want to change to a new one in $HOME/.hydrogen/data/drumkits
Open the drumkit.xml file from the new folder in a text editor.
Use find_and_replace to change the names of the snare samples
but make sure the instrument name stays the same.
If this might affect the names of other samples, cut and paste the snare instrument entries to another copy of the text editor first. find and replace, then paste the altered text back.
Replace the actual samples in the new kit folder.
Fire up hydrogen and load the new kit into your project.
Save the project and the new kit.
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Re: Hydrogen Question - Replacing instruments in a song?

Post by SR »

Hi GarryO,

i think I've found a similar approach that seem to work. The h2song file has an "<instrumentlist>" section at the beginning which is similar (but not identical) to that in the drumkit.xml file. I found that I could copy/paste/replace the instruments I wanted from another h2song file. The gotcha for me was ensuring that the instrument id's were correct in the instruments I copied over.

Thanks for the tips, and I can't wait to tryout that script for building kits.

--SR
User avatar
Yeri
Established Member
Posts: 158
Joined: Tue Dec 09, 2008 6:33 pm
Location: Spain

Re: Hydrogen Question - Replacing instruments in a song?

Post by Yeri »

GarryO wrote:Yeri: I completely missed the fact that you could do this through the layers
if you mean the layers' loader of hydrogen, effectively you can do it. However, if you do this way, you have to manually load sample by sample (i.e. layer by layer) and your script does it automatically for all the samples (layers) for all the instruments.
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

Yeah, sure, I knew you could load samples into an instrument like that,
but I didn't click that Sr could replace his instrument samples that way.

I wrote the script because of the sheer tedium of loading lots of layers for many instruments that way, but also because of a bug where the layer volumes were not saved properly to drumkit.xml.
a quick test seems to suggest that this has been fixed in 0.9.4rc1.
User avatar
GarryO
Established Member
Posts: 167
Joined: Mon Apr 06, 2009 7:30 pm
Location: UK
Contact:

Re: Hydrogen Question - Replacing instruments in a song?

Post by GarryO »

Further testing shows that this is still a buggy area of Hydrogen.
Unfortunately - although I haven't checked out the latest svn code yet - it seems that my script is probably the easiest and safest way of building big multi-layer kits.
Post Reply