Skip to Content

Problems with MIDI export!!

51 replies [Last post]
ildrugo
Offline
Joined: 04/17/2010

When i try to export hydrogen songs in midi file and next i open this file with another editor like cubase or similar, the song play different because the drummap is completely different.
The Key for Kikc, snare and other does not match.
Then, the midi file result of exporting contains a lot of note with 0 velocity.
how I can export a compatible format (for cubase or similar)?

thanks,
carlo

Artemio
Offline
Joined: 04/17/2010

If you use the GM kit, the keys should be mapped correctly (I tested this). But if you use a custom kit whose sound order is different, of course it will not map to correct sounds.

ildrugo
Offline
Joined: 04/17/2010

thanks for your replies.
I use the GMKit but the key don't match if i open this midi in cubase or simply play in windows media player. why?

carlo

trey85stang
Offline
Joined: 04/17/2010

I have the same problem as well and would like to know if there is a workaround? I like using hydrogen to create my drum tracks because I have been using it for a while and am familier with it... but I would like to be able to export to a midi and then reprocess with EZDrummer...

Anyone have any ideas why it is not working?

2Late
Offline
Joined: 04/17/2010

I've had same problems. And I think I found the problem. And created patch for it. And it works only when sound order matches GM drum map. Diff is attached. Please test it. It would be great if instrument (sound) could have a user settable midinote property.

Edit: couldn't attach the diff-file, so here it is: (watch formatting)
Index: SMF.cpp
===================================================================
--- SMF.cpp (revision 288)
+++ SMF.cpp (working copy)
@@ -24,7 +24,7 @@

#include
#include
-
+#include
#include

using std::vector;
@@ -230,7 +230,7 @@
SMFTrack *pTrack1 = new SMFTrack( "Hydrogen song!!" );
smf.addTrack( pTrack1 );

-
+ InstrumentList *iList = pSong->getInstrumentList();
// ogni pattern sara' una diversa traccia
int nTick = 1;
for ( unsigned nPatternList = 0; nPatternList < pSong->getPatternGroupVector()->size(); nPatternList++ ) {
@@ -251,8 +251,11 @@
for ( pos = pPattern->m_noteMap.lower_bound( nNote ); pos != pPattern->m_noteMap.upper_bound( nNote ); ++pos ) {
Note *pNote = pos->second;
if ( pNote ) {
+ pNote->dumpInfo();
int nVelocity = (int)( 127.0 * pNote->m_fVelocity );
- int nPitch = 36 + nNote;
+ int nInstr = iList->getPos(pNote->getInstrument());
+ int nPitch = 36 + nInstr;
+ //int nPitch = 36 + nNote;
eventList.push_back( new SMFNoteOnEvent( nStartTicks + nNote, DRUM_CHANNEL, nPitch, nVelocity ) );

int nLength = 12;

colligpip
Offline
Joined: 04/17/2010

hello i am new to this and would really like for midi export to work. PLease where do i put this information. is there a config file or some thing?

AndreVonWeimar
Offline
Joined: 04/17/2010

Yeah. Te same is happening to me. The MIDI mappng is all wrong.

conrax
Offline
Joined: 04/17/2010

It's a very good and intuitive program, but it's almost useless if I can't export in MIDI format and use it with a sequencer.
The MIDI mapping is wrong, I use a GM kit but it doesn't work.
Is there any hope for the solution or is better to try other drum machines ?
Thanks

weixlbaum
Offline
Joined: 04/17/2010

Hello

I am using Samplitude SE under windows. Because I have no drum editor I use Hydrogen on windows and I like this program very much.

The MIDI problem seems not to be solved so I am looking for a MIDI File conversion.
I tried to do it myself but I failed. So I found the MIDI Disassembler (http://www.borg.com/~jglatt/progs/software.htm) which converts MIDI files to readable text.

So I looked to the patch from 2Late but I don't understand it.

What parameters in the MIDI-file do I have to change?

I think this would be a nice workarround to use hydrogen with GM under windows.!

Thanks in advance,
weix

Blaubaer
Offline
Joined: 04/17/2010

Hello

I've got the same problem.
The MIDI Export function doesn't work, although I'm using the GMKit.

So I wrote a little program to solve this problem.
It's called "h2midi" and it converts a h2song file to a midi file.
Just open a command box and type "h2midi ".
The midi file will be created in the same directory.
h2midi is under GPL, because I used source code from Hydrogen to read the h2song format.

You should be able to compile it under linux and windows ( using mingw or cygwin ) with "make".

I hope I could help you.
If you find bugs, please report them to me.

h2midi can be downloaded here:
http://www.file-upload.net/download-363270/h2midi.tar.gz.html

suchyzsusza
Offline
Joined: 11/13/2011

HI. I have the same problem as you! I've found a hydrogen2midi but i don't know how use this. I made file exucutable, run it and... what now? You're my last hope, please tell me, what i have to do to create midi file sounds like wave?

stepanovicd
Offline
Joined: 04/28/2015

hey guys,

 

I know this is a very old thread, but does anybody still have H2midi program and would be willing to send it to me?

 

Thanks

weixlbaum
Offline
Joined: 04/17/2010

Great work!!!!

I recompiled it with "Codeblocks". This is a free IDE which uses MinGW.
I recompiled it because your compiled version needs the cygwin1.dll.
It works straight forward. Add all files to project, add include directory and compile -> ready. In this way it works nativ under windows.

I tested only with one song yet, but it works great for it.

I tryed to attach the compiled file but I only get it to 121KB (rar)

I will look for bugs and improvements.

Thank you very much!

Weix

jax
Offline
Joined: 04/17/2010

weixlbaum could you please publish that file on http://www.sendspace.com/ or somewhere?

I'd like to test this converter :-)

Blaubaer
Offline
Joined: 04/17/2010

Here is the new download link to h2midi recompiled with Codeblocks:
http://www.sendspace.com/file/eowwyx

You will also find the files h2midi.reg and h2midi.bat in the zip file.
They can be used to associate .h2song files with hydrogen and h2midi.
For further information, please read readme.txt.

Blaubaer

imn-angel
Offline
Joined: 04/17/2010

Excuse me Weixlbaum, Hi there. I came across your name on this site and I had to contact you because that is my last name. It is a unique name and I've not known anyone else with it besides family. I was curious.....Is that part of your name? or is it a nick? Could I know you?
Would you mind comparing? Thank you!

Sincerely, Curious Weixlbaum

jax
Offline
Joined: 04/17/2010

The converter works.
Snaredrum was lost somewhere during the conversion, but I think that it was not GM compatible.
More tests to come soon :-)

Thank you!

noah
Offline
Joined: 04/17/2010

It's not on sendspace anymore. If you could upload there again I'd be really grateful.

Blaubaer
Offline
Joined: 04/17/2010
musicman
Offline
Joined: 04/17/2010

hello,

i have got the same problem with the midi export funktion! And i use a mac so i can't open the file h2midi! what can I do?

thanks

Blaubaer
Offline
Joined: 04/17/2010

i've never worked mit a mac I must say.
But with MacOS X you should be able to compile h2midi.
Unzip the archive, open a command prompt and
change to the src folder.
Then compile the source with the "make" command.
Just type "make" and enter.
Now you should get the h2midi executable.
Then "h2midi " converts into a Midifile.

derdomi
Offline
Joined: 04/17/2010

hi, thanks for supporting this feature (midi export),
but i didnt become this feature to run, if i convert an h2song to midi i become an midi file with sameless name, but the midi file takes no information about the part, that means the midi files has no trigger information includes.....

thats very silly, i think if the export function works fine then hydrogen is a very perfekt tool .....

has anybody a diffrent idea as h2midi or can give some help...
thanks derdomi

Blaubaer
Offline
Joined: 04/17/2010

Your problem could be, that your h2song file doesn't use the GMKit.

But it would be useful, if you upload your file,
so I can see what's wrong with it.

derdomi
Offline
Joined: 04/17/2010

hi, i create a simple pattern,
save it as projekt and convert to midi,

i put this into rar file

http://download.yousendit.com/750528EA4123FAAF

I have a second PC and i will test it again, but i want redownload the files and i need a step by step instruction which describes the 100% way to use this tool....

byebye

Blaubaer
Offline
Joined: 04/17/2010

thank you very much, I'am working on it

Blaubaer
Offline
Joined: 04/17/2010

I found out what's wrong with your file.

You created a pattern, but you didn't add your pattern to
the song. Add the pattern to the song and h2midi should work.

derdomi
Offline
Joined: 04/17/2010

i dont know which is the right way to bring a pattern into song,
if i use the demo song i become no possible files,

this is the txt from the midi file which was created with demo song... "GM kit demo #1.h2song.mid"

MThd   ?MTrk  ? ?Q? ?$e ?$e ?*- ?*-?`?* ?*?0?*5 ?*5?0?%e ?%e ?* ?*?0?*7 ?*7?0?$e ?$e ?* ?*?0?*2 ?*2?0?$e ?$e?0?*5 ?*5?0?*+ ?*+?0?%e ?%e?`?*( ?*(?0?$e ?$e ?* ?*?0?*G ?*G?0?$e ?$e ?*- ?*-?`?* ?*?0?*5 ?*5?0?%e ?%e ?* ?*?0?*7 ?*7?0?$e ?$e ?* ?*?0?*2 ?*2?0?$e ?$e?0?*5 ?*5?`?2e ?2e?0?(X ?(X?0?/e ?/e?0?+e ?+e?0?( ?(?0?$e ?$e ?* ?* ?1e ?1e?`?*# ?*# ?;0 ?;0?0?*2 ?*2?0?(e ?(e ?* ?*?`?* ?* ?;- ?;-?0?$e ?$e?0?$e ?$e ?*& ?*&?`?$e ?$e ?*
?*
?;2 ?;2?0?*- ?*-?0?(e ?(e ?*L ?*L?`?* ?* ?;V ?;V?0?*G ?*G?0?$e ?$e ?* ?*?`?*# ?*# ?;0 ?;0?0?*2 ?*2?0?(e ?(e ?* ?*?`?* ?* ?;- ?;-?0?$e ?$e?0?$e ?$e ?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&e ?&e ?.e ?.e ?8e ?8e ?3e ?3e?`?$5 ?$5 ?,! ?,! ?3 ?3?`?$e ?$e ?,( ?,( ?8e ?8e ?3e ?3e?`?,: ?,:?`?&e ?&e ?.e ?.e ?8e ?8e ?3e ?3e?`?,! ?,! ?3 ?3?0?$ ?$ ?3+ ?3+?0?$e ?$e ?, ?, ?8e ?8e ?3e ?3e?0?& ?&?0?,+ ?,+?0?$e ?$e?0?&e ?&e ?.e ?.e ?8e ?8e ?3( ?3(?`?$5 ?$5 ?,! ?,!?0?& ?&?0?$e ?$e ?, ?,?0?& ?&?0?&B ?&B?0?2e ?2e?0?&e ?&e?0?/e ?/e?0?+e ?+e?0?& ?&?X?&- ?&-?X?9e ?9e?? ?$ ?/

if i load it into my seuqenzer i become no possible reason....
i think i have a installation bug, (mybrainbug1.0 grrrrrr), i think i have wrong installation paths or something else.....

i thing its the best way, when i test this feature at one other system, but for this i need a 100% instruction, this mean an instruction for idiots please....

thank you

Blaubaer
Offline
Joined: 04/17/2010

I think this picture helps you:
http://i11.tinypic.com/8apswmd.jpg

You must click on the field, which is marked on the picture with the red circle.
Save the file and then h2midi works.

derdomi
Offline
Joined: 04/17/2010

hey thanks for your help, but i didnt become this to run, i give up (grrr) i wait for a version update and hope that this destroy this bug thank you

Blaubaer
Offline
Joined: 04/17/2010

what???

Your problem isn't caused by a bug........so waiting for a new version doesn't help you.
To proof this, here I would upload the midi created with h2midi,
if you reupload your h2song file.

derdomi
Offline
Joined: 04/17/2010

so i have a new pc and i had a new windows, in the next time i will install hydrogen for the 1. time, but i dont will become same as last, so i has one question, is anybody here which can give a step by step one by one faq.... which describes the complete way to install the programm + the special prgramms ....

thank you...

PS:
What is a bug... for me... bug is a feature that is listed but dosnt work... in my hydrogen i had the option midi export... but this funktion dosnt work... inst a bug... lol

eveq
Offline
Joined: 04/17/2010

Hello
Can somebody may send me h2midi program to mu e-mail?
my e-mail: batton23@o2.pl
please!!!!!

lookche
Offline
Joined: 04/17/2010

hi, does anyone still have h2midi or a program of the same caibre?

if they do, can they please email it to me, lookche@hotmail.com?

thanks!

mauser
Offline
Joined: 03/30/2010

It would be no problem to distribute it with hydrogen if someone could publish it somewhere....

uro
Offline
Joined: 04/17/2010

There seems to be an odd bug in this release: when I export a midi file, the note values increase by a fixed amount for each note on/off.
I tested with a small file, consisting of 8 notes, with pitch=0 key=C0 length=-1 instrument=5 and positions 0,48,96,120,168,216,264,336.
here is the mf2t list of the exported midi file:

MFile 1 1 192
MTrk
0 Meta SeqName "Hydrogen song!!"
0 On ch=10 n=36 v=101
48 Off ch=10 n=36 v=101
192 On ch=10 n=84 v=101
240 Off ch=10 n=84 v=101
384 On ch=10 n=132 v=101
432 Off ch=10 n=132 v=101
480 On ch=10 n=156 v=101
528 Off ch=10 n=156 v=101
672 On ch=10 n=204 v=101
720 Off ch=10 n=204 v=101
864 On ch=10 n=252 v=101
912 Off ch=10 n=252 v=101
1056 On ch=10 n=44 v=101
1104 Off ch=10 n=44 v=101
1344 On ch=10 n=116 v=101
1392 Off ch=10 n=116 v=101
1392 Meta TrkEnd
TrkEnd

each note value gets 48 added to prev note, the hex note values are
24 54 84 9C CC FC 2C 74
and since half the note values are invalid,

Cakewalk interprets this as :
3 notes in measure 1 (C3, C7, C4),
one in measure 2 (C4),
one in measure 7 (C4),
and one in measure 80 (G#9).

after manually changing all note values to hex 24, the file plays correctly.

anyone else having this problem?

daffy
Offline
Joined: 04/17/2010

Any chance of someone putting up the h2midi program again please? None of the previous links are active any more.

Many thanks!

midnightautomatic
Offline
Joined: 04/17/2010

Hello,

I am also very disappointed about the faulty midi export.
If anyone has a compiled version of this converter please publish or send it to my email address:
midnightautomatic@web.de

Kind regards

daffy
Offline
Joined: 04/17/2010

OK, so since there was no response to my previous email about a MIDI converter, I went away and wrote one myself.

At the moment, the converter will take a hydrogen file and convert it to a Type 1 MIDI file. This type of file works best for pattern libraries and for importing into a MIDI sequencer. Each pattern is assigned to its own track, and the patterns are arranged in the same order as they are in Hydrogen. I have also added space before each one so that if you load the file into a MIDI player it will play through each pattern in order.

At this time I have ignored the song information. Since I just use Hydrogen for creating drum loops to jam with, this is fine for me, but it may not be fine for someone who has actually created a song. However, I would imagine song writers would import the song into a sequencer and then simply arrange the patterns into their song again.

I have also provided the ability to create/use drum maps. If you run the program with -c then it will create an XML drum map file from the Hydrogen file. You can then edit this to map the drums to the right MIDI note numbers, and then tell the program to use the map when it writes the file.

To use, unzip the file (I have included a sample file and some maps) and run 'java -jar Hydrogen2MIDI.jar' for help

Have fun!

gabriel
Offline
Joined: 04/17/2010

Hello,

This bug is being worked on. Here's a link to the bug tracker site:

http://hydrogen-music.org/devel/ticket/26

Thanks,
Gabriel

gabriel
Offline
Joined: 04/17/2010

I applied the patch submitted by 2Late at the top of
this forum, and I believe it resolves the issue. If anyone who was have the issue could test, I would appreciate it. (I know it's been... what? 2 years!)

Blaubaer
Offline
Joined: 04/17/2010

I didn't use hydrogen anymore, and so I didn't follow its development and forgot about my h2midi project. I'm sorry for this.
I haven't tested daffy's converter yet, but its description sounds nice and it's written in java (which a great advantage in my eyes).
Anyway, I've uploaded the original h2midi program once again, perhaps some still needs it for any purpose.

If someone knows a good filehoster, please tell me. I just choose this one, because I uploaded the program there as I published it the first time.

http://www.file-upload.net/download-1088665/h2midi.zip.html

mastercob
Offline
Joined: 04/17/2010

Blaubaer, in the off chance that you read this, I'd like to try out your converter.

I can't get daffy's to work. It's just making a blank midi file (I could go into detail on my experience using it).

It would still be awesome if Hydrogen could fix this bug. I'd love to be able to make beats in Hydrogen, and them open up the midis in Reaper or something, so that I could finish the song. Hydrogen is kind of useless with this feature not working.

I guess for now I could open up the songs on my linux box and convert them to midi there!

Edit: I should note that this is currently a mac osx issue.

wolke
wolke's picture
Offline
Joined: 03/30/2010

hi blaubaer,
i follow your link, but there is no file.
greetings wolke

Blaubaer
Offline
Joined: 04/17/2010

hi guys,

i've just uploaded h2midi again and here's the link:
http://www.file-upload.net/download-1844251/h2midi.zip.html

If you got any questions or if there's a problem, just ask me....

Greetings Blaubaer

mastercob
Offline
Joined: 04/17/2010

Thanks for uploading it again!

paddy
Offline
Joined: 04/17/2010

Struggling to understand how to get the h2midi to work. If i double click on a song file it comes up with a export to midi if i click that a command box comes up. but it just sits there with a flashing _

I did read the read me file.

all the best

paddy

Blaubaer
Offline
Joined: 04/17/2010

hi paddy,

i'll try to fix your problem when I found out about it.
Could be helpful if I know which Windows you're working with.

Till then just use h2midi via command box.
Open a command box, change to the directory where your song file
is located, and then type 'h2midi '.
Now a midi file should appear.

Greetings Blaubaer

paddy
Offline
Joined: 04/17/2010

Thanks a lot for your help. But I think It works okay now. Sorry about that. Useful software tho.

206devil
Offline
Joined: 04/17/2010

does somebody have the h2midi?

Blaubaer
Offline
Joined: 04/17/2010
alereche
Offline
Joined: 04/17/2010

Sorry if I missed something but why this h2mid was not included in the official release of hydrogen?

Regards,
a r s