GithubHelp home page GithubHelp logo

valleybell / midiconverters Goto Github PK

View Code? Open in Web Editor NEW
98.0 98.0 13.0 827 KB

various tools that convert game data into MIDI files

License: GNU General Public License v2.0

C 91.26% Shell 0.04% Visual Basic 6.0 8.54% Python 0.16%

midiconverters's People

Contributors

superctr avatar valleybell avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

midiconverters's Issues

Pitch bend doesn't work properly in IT2MID

I have recently been using your IT2MID program, and I must say it's been working well. The MIDI files it outputs are "more optimized" than those generated from OpenMPT's export function. However, one thing is incorrect that even OpenMPT sort of gets right: the pitch bend function when converting Exx and Fxx commands, which some of my songs that I made have a lot of. It seems that it's mapped to the "modulation" command rather than pitch bend when I open it in a MIDI editor, and doesn't seem to change pitch very much at all. All of your other MIDI converters don't have this issue. What is happening here? Is it a bug or is there a way to get these pitch slides right?

How to extract the necessary .m files for Planet's Edge?

Thanks for sharing!
I am looking forward to giving nwc12mid.c a go, however I'm not sure how you extracted the .m from the planet's edge executable?
If I read it correctly this conversion expects the .m file as an input?

I am using the version of Planet's Edge downloaded after purchasing with steam, it seems all game assets must be loaded within the exe files.
I am doing my best to explore them with Ghidra, and saw references to .m files which I am assuming are the sound files, however I don't know how to locate them within the exe.
If you have any advice in particular for Planet's edge I would appreciate it.

Soundfont is corrupt (M2MidiDec, Sonic the Fighters)

Operating System: Windows 10 using the MinGW-w64 toolchain

Input file(s): Sonic the Fighters Model 2 ROM

Expected behavior: I expect the soundfont (out.sf2) generated by M2MidiDec.exe to be a valid soundfont that can be used in *.SF2 compatible programs.

Actual behavior: Various errors pertaining to the soundfont depending on which program is used to open them. For example, the Polyphone soundfont editor states that the file is corrupt and the error originates in the pdta region of the generated soundfont. LMMS, a popular music sequencer, cannot find any patches nor banks in the soundfont file.

Steps to reproduce:

  • Download the GitHub repo and extract it to a folder.
  • Open a command prompt and cd into the folder.
  • Enter the following commands in the command prompt:
gcc -c Soundfont.c
gcc -shared -o Soundfont.dll Soundfont.o
gcc -o M2MidiDec M2MidiDec.c -L./ -lSoundfont
  • Drag the generated Soundfont.dll and M2MidiDec.exe into the folder containing the ROM files for Sonic the Fighters.
  • Execute M2MidiDec.exe.
  • Attempt to use the generated out.sf2 in any program which supports *.SF2 files. Failure.

Extract MIDI from Virtua On

Hello,

I'm fairly new to Midi extraction so i'm having a little bit of trouble.
I generated the exe file with:
gcc Soundfont.c M2MidiDec.c -o M2MidiDec
But now, what file do i have to drag in to the .exe? The txt mentions, for Virtua on,
Sound Program: v2 epr-18670.31, but i tried with it and nothing happened.

Thank you for your time!

tsd2mid fails to convert "VT_04_MD.M_"

tsd2mid fails to convert only "VT_04_MD.M_" of Brandish VT. (I have confirmed that all ED4 files can be converted correctly.)
I tried to give some options but no luck.
Are there any ideas I am missing?

Error messages are as follows

Falcom TotalSoundDriver -> Midi Converter
-----------------------------------------
Error Track 0: Unhandled command 0xE2 at position 0x544F!
Warning Track 1: Invalid channel mode 0x02X
Error Track 1: Unhandled command 0xE3 at position 0x6468!
Warning Track 3: Invalid channel mode 0x02X
Error Track 3: Unhandled command 0xE0 at position 0x0602!
Error Track 4: Unhandled command 0xB0 at position 0x0272!
Error Track 5: Unhandled command 0xB0 at position 0x10B8!
Error Track 6: Unhandled command 0xC2 at position 0x342A!
Error Track 7: Unhandled command 0xE2 at position 0x544F!
Error Track 8: Unhandled command 0xC3 at position 0x76E2!
Error Track 10: Unhandled command 0xE1 at position 0x2C2D!
Early EOF when trying to read track 12!
Done.

ngp2mid - Failure to convert (sonic)

Using ngp2mid gives me errors when using it with the sonic pocket rom found on archive.org.
I have confirmed that the following is set correctly for this rom:
static UINT8 DrvVer = DRV_VER_09F5;

g++ ngp2mid.c -o ngp2mid
./ngp2mid Sonic_the_Hedgehog_Pocket_Adventure_1999_Sega.bin sonicmidi.mid

Converting Sonic_the_Hedgehog_Pocket_Adventure_1999_Sega.bin ...
Track 0 (Channel 1) ...
Track 1 (Channel 1) ...
*** stack smashing detected ***: <unknown> terminated
Aborted (core dumped)

If I use the -fno-stack-protector flag...

g++ -fno-stack-protector ngp2mid.c -o ngp2mid
./ngp2mid Sonic_the_Hedgehog_Pocket_Adventure_1999_Sega.bin sonicmidi.mid

Converting Sonic_the_Hedgehog_Pocket_Adventure_1999_Sega.bin ...
Track 0 (Channel 1) ...
Segmentation fault (core dumped)

SONG_18 - Sonic the Fighters issue (M2MidiDec)

Greetings,

All the songs extracted from Sonic the Fighters appear to be correct except for "SONG_18", which in the OST is labeled as "MISSION COMPLETE - Egg Fanfare" and labeled internally in the game as "0xAE1018".

I'm not sure what's going on with it, but it should sound more like it's OST counterpart than it currently does as extracted by the current build: https://www.youtube.com/watch?v=XNQZFSxCXhI

The extracted MIDI with Sonic the Fighters soundfont converted to WAV is attached for reference.
SONG_18.zip

Build docs / makefile?

I'm trying to figure out how to build these tools but it would be good to know the parameters for the gcc / g++ command or have a makefile available.

Feature Request: M2MidiDec Sample Extraction Labels?

Greetings,

I'm not 100% familiar yet with how audio is called in the Model2 games, but as I understand it a "sound code" relates to the sample? For example the first playable sound in the sound test of the game is named "sd_jump_1" with a sound code of "0xAE1100" and your program names this file "Ins50_d00_Smpl90".

A list of sound codes followed by names can be found within the game's program data starting at offset 0x9A12C.

Perhaps there could be some way to properly label non-instrumental sound files by referencing the data in the program roms?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.