Language…
3 users online: ClaireChan, Firstnamebutt, tOaO - Guests: 86 - Bots: 323
Users: 64,795 (2,381 active)
Latest user: mathew

IT2AMK (Alpha 1.0) Release -- Port Music Using a Tracker!

Hello all! This is a little thing I've been working on during the first few rounds of Idol 9 and I decided that I'd release what I have so far for C3. Essentially, it is a tool that can take IT module files and turn them into MML ready to be inserted with AddMusicK! Currently, IT2AMK already supports a range of features, including but not limited to:
- Sample to BRR converstion, compelete with preserved tuning for all the samples.
- Notes, volumes, panning, vibrato, instrument changes.
- Multi-sample instruments.
- Volume envelope to ADSR conversion.
- Flexible tempo scale adjusting to reduce lag or note breaks.
- Optional downsampling for all samples to reduce insert size.
- Compatibility with Codec's Beta version.
- And more...

It still has many limitations though, for example:
- It cannot convert pitch bends.
- It cannot do portamento.
- The MML it produces is pretty unoptimal in terms of size.

Additionally, as a bit of a disclaimer, it's still an alpha, so expect some (or maybe a lot) of bugs. Known bugs so far:
- Modules using sample mode instead of instrument mode are completely untested and likely buggy.
- Notes using noise may cut off prematurely in some cases.
- Song does not reinitialize everything properly at the loop point. (Can be fixed by duplicating the loop pattern/rows and initializing the offending effects manually).
- Note Fades do not function properly at longer Fade Out values due to the volume fade command ($E8) having a length longer than $FF.
- Automatic Note Fades don't kick in when the volume envelope ends like they should in IT.
- If a Note Off occurs on an instrument wihout a sustain loop in its volume envelope, it acts like a Note Cut, instead of continuing like it should.
- Cancelling out of vibrato mid-note causes the note to be detuned.
- Songs that use only noise and no instruments will not insert with AMK due to them using @30, while not having any instruments defined. Instruments must have at least one note using them placed in the module to be considered "used".
- Initial tempo and global volume are defined more than once in the MML, causing a small waste of insert size.
- Note ties within the same measure are sometimes broken up unnecessarily. (Does not affect insert size though, as AMK optimizes it.)

Planned features:
- More sample conversion options.
- Support for nearly all of the IT effects, including pitch bends.
- Support for New-Note-Actions.
- Support for notes past channel 8.
- Automatic MML optimization and loop placement.

But anyway, without further ado...
DOWNLOAD LINK

You'll need the following to run it:
- Python 3.4 (or newer)
- .NET Framework 4.5.1 4.0 (or newer)

Make sure to read the readme files and check out the examples before doing anything. And yell at me if things don't work.

Note: Does not work in Windows XP (probably not any other 32-bit os either). I may release an updated version soon that fixes this. Should work in Windows XP now.
oh wow this sounds useful for those who use this

good work!
My requirements are Python 3.4 and .NET Framework 4.0.5 support for Windows XP for testing.
Wow, nice! I know people who would really like this. I only wish I was a tracker person, sadly I'm in midi land. I've played with Open MPT and other trackers a few times but can't really make much headway with them for various reasons, main one being visual impairment and poor accessibility among trackers. Open MPT is getting better about that though, so it's becoming more a matter of me sitting down and just getting used to tracking I guess, though whether I'll get comfy enough with tracking to actually use it casually/productively is anyone's guess lol.

As a side note, would be interesting to compare this to Snesmod. I know, it's comparing apples to oranges, but both take .it as input, and both do automatic sample conversion. The engines and target uses are very different though. From what I understand Snesmod does have considerable support for common .it effects, probably in part due to the engine being different. In any case, if/when I eventually become competent enough at tracking, I should give these tools a spin.
Make more of less, that way you won't make less of more!
Well, this is kinda amazing! It's like A MAD SCHEME reborn, with even more features and up-to-date! As a complete music-iliterate, I'm quite excited for this!
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!
tfw I'm too into AMK and PetiteMM now to go to tracker territory again #smw{T_T}

Seriously tho, this could be pretty useful; I don't have much experience with OpenMPT, but if this gets complete then it could easily replace SNESMOD IMO, and I bet a lot of people would start using AMK after this too
Layout by Mathos
@YuzuMSX There is a good chance this works on Python 3.4 as well, as I don't recall using any features specific to 3.6. I've just been testing with Python 3.6 and I haven't tried 3.4 myself. It definitely won't work on .NET 4.0.5 but you can (hopefully) expect support for it soon!

@musicalman Yeah, I've always been more of a DAW/MIDI person myself lol. But lately I've realized that DAWs probably aren't the best tools for doing chiptune-related music. Mainly due to just about no MIDI converter supporting multiple notes on a single channel, and channel switching in most DAWs is a bit of a pain. With a tracker, all of the channels are there in front of you at once and there's no need for window switching (in OpenMPT I can switch channels just by pressing Tab/Shift+Tab.) Plus this way, I have a lot more control over channel management. The great thing about MPT though is that it's very user friendly for a tracker. Aside from the difference in user interface, I've always felt that IT is a more suitable format for SPC in general than MIDI is. Largely due to the fact that all of the samples and instrument envelopes are stored internally within the file itself, while MIDI is more or less just pure note data (plus some other stuff like volume events but you get the idea).

SNESMod was definitely a large part of my inspiration for making this. It's certainly true that it currently has more support for the native IT effects (likely due in part to how the pattern data in the SPC is more or less identical to the IT, while IT2AMK has to convert it), but it also has its limitations. SNESMOD crashes if you give it a module with pattern data on channels after the first 8, and it also doesn't support instrument note tables containing multiple samples. It also can't utilize most of the hardware features of the SPC700, like noise, adsr, or pitch modulation (I think it can do echo though). I've also heard that its BRR conversion isn't the best and it creates a lot of clicking sounds every time there's a volume change, due to it using direct gain for everything.

On the other hand, IT2AMK's main limitations are that it doesn't support a lot of effects, and it doesn't have as much support for volume/pan/pitch envelopes, and still has more bugs. I think SNESMOD is also more space efficient than AMK's engine (and also has less slowdown) but I'm not 100% sure on that.

For future versions though, I definitely plan to narrow the gap between IT2AMK and SNESMOD!
Yep, I totally agree with you there about tracker formats being better for this sort of thing. There's no midi equivalent really without jumping through hoops.

BTW if you are interested... I could possibly help with perhaps bouncing ideas off of, or for testing specific things, or the like. I'm not much of a programmer so couldn't help code, but would like to contribute somehow. It'd give me an excuse to sit down with Open MPT and get comfortable with it too.

Finally I remember reading that you planned to support more than 8 channels. I guess you'd have to intelligently decide how to clump channels together or something. IF that's the case, then it'd also be interesting, though perhaps less useful, to expand less channels to more. IIRC the .it format has an instrument mode that will allow notes to continue releasing even if a new note one overlaps it on the same channel. To do this on most soundchips you'd have to manually use two channels for this since most engines didn't support that natively. There are only a few games that I can remember doing this, two that come to mind are Super Turrican II and super Back to the Future. MMLing those would be a mess, but I do like how the music sounds, it doesn't have the classic stacato Snes sound lol.
Make more of less, that way you won't make less of more!
@musicalman That sounds good! I definitely encourage anyone here to suggest ideas or test for bugs.

Regarding the more than 8 channels thing, my idea is essentially to make it so any notes playing outside of the first 8 channels will search for any empty parts in the first 8 channels and fill those up with the extra notes, I plan to do a similar thing for new note releases. One potential drawback though is that all the instrument/volume parameter changing on a single channel could increase the insert size a lot, so I might have to think of some ways to optimize it as much as possible.
Yeah that would indeed get interesting. And with auto-optimization, you'd have to take naive mistakes into account that would increase the insert size rather than decrease it. I mean it probably wouldn't be that hard to avoid that, but it would definitely be something to consider. And there's also room for getting kinda pedantic so I'm not sure how far you'd want to delve into that lol. I'd say just let optimization up to the user, but depending on the circumstances, that could be a huge pain.
Make more of less, that way you won't make less of more!
I'm kinda bored now. I have not tested yet!
I need fix the sampconv.exe or/and adding --nosampconv flags
Being very much a tracker person(So much of a tracker person, in fact, that I hate using MML and personally find it harder to use), here are my questions:

- Does it support pattern looping?
- Is pattern delay supported?
- Can I use CXX to jump to a specific row?
- Are panning envelopes supported?
- On an instrument with a sample tuned to C-5, what's the highest note supported?
- Are channel volumes and the Mxx command supported?
- I can safely assume filters are not supported, right?

Sorry if it's a lot of questions, but I really am curious since trackers are the main program I use to make music in.
YouTube
@Nikku4211 Check out the list_of_supported_features.html file in the it2amk_readme_files folder, it briefly outlines which effects and features are supported. (To answer your question though, all of those you listed are supported except for panning envelopes and filters.)

I forgot to mention though, that the supported note range is from C-2 to A-7 (IT2AMK transposes all notes an octave down, and any notes outside of that range get turned into rests). This takes the instrument's note table into consideration, though. For example, if your instrument has note B-7 mapped to a note that's in range, say C-5 for example, then any B-7 placed in the pattern editor will still be properly converted because IT2AMK treats it as C-5. The same for the reverse is true as well; if C-5 is mapped to an out of range note such as B-7, it will not play. (The only exception for this is instruments marked as Noise, as it completely ignores the note table and always converts to o4c in the MML)

@Ultima I forgot to mention this, but even if you prefer MIDI, I still recommend giving this a try. OpenMPT can actually import MIDI and you can convert it to IT, so you can prepare your port entirely in MIDI and then simply replace the samples and instrument envelopes to what you want after importing it.
Do you know what IT effects you don't plan to support?
YouTube
Good news! I updated the code for sampconv.exe so it should (in theory) be compatible with .NET Framework 4.0 and 32-bit OSes (I had Sinc-X test it on his WinXP VM).

IT2AMK (Alpha 1.0.1) Download

Additionally, I put the source code on Github: https://github.com/jyosh1/it2amk

I also uploaded direct links to each of the readme files, for easier accessibility:

Setup and Basic Usage
Advanced Usage
List of Supported Features

@Nikku4211 I definitely won't be adding support for Oxx/SAx, since there is just about no way to implement sample offset on the SNES (except for duplicating the sample for every Oxx value used, but for obvious reasons that would be...bad). Zxx will never get full support either, but I may be able to add limited support to it by having it control echo/master volume to create filter-like effects on the SNES when combined with a custom FIR. Unfortunately it would have to be a global effect though.
Works on WinXP!
Thank you Jimmy!

I tested and converted 4 example files!