Writing wave forms in notepad

Started by carbonthief, December 17, 2012, 08:33:03

Previous topic - Next topic

carbonthief

Ok so I'm just browsing random videos on youtube under keyword search "open mpt tutorial" to see what new things I can learn, and I find one that catches my eye.  And then I see this guy do something that just blows my mind.

http://www.youtube.com/watch?v=4Ib6gpSTqDM

He's typing letters and spaces into notepad, dragging the text file into mpt, and as far as I can tell it's witchcraft.  Seriously though, this is something that intrigues me and I want to understand how it works.  Is there any kind of documentation or information I can read about this, about how exactly it works, what different letters "mean," etc.

He types 24 spaces followed by 24 Z's and that makes a specific kind of wave, well, why does it do that exactly?  What does space mean?  What does Z mean?

edit: Also do you have a recommendation for an Ace of WAV replacement?  It seems to no longer be available for download, and apparently does not work past Windows XP if it was.

LPChip

this is not whichcraft. Openmpt can recognize and create a waveform out of ascii data. I've created a program to create textfiles in the past to make a pulse waveform. basically, the higher the ascii number, the higher the point. it was something like that.

A space is ascii 32 while the Z is ascii 90.
"Heh, maybe I should've joined the compo only because it would've meant I wouldn't have had to worry about a damn EQ or compressor for a change. " - Atlantis
"yes.. I think in this case it was wishful thinking: MPT is makng my life hard so it must be wrong" - Rewbs

carbonthief

#2
Ahhh ok that makes a little more sense.  Also, this is completely awesome, and I'm saddened that I didn't run across this until almost 3 in the morning.  Going to be playing with this tomorrow after work.

Saga Musix

#3
Quote from: LPChip on December 17, 2012, 08:35:58
Openmpt can recognize and create a waveform out of ascii data.
OpenMPT doesn't "recognize" anything, the truth is just that it doesn't give a single fuck what data it reads. OpenMPT interprets all data as Pulse Code Modulation (PCM), and that's all the magic behind it. If you import an "unsigned" sample, you get the lowest values in the waveform if the byte value is low (like a space character), and the highest values if the byte value is high (like umlauts). The ASCII character "z" is close to the middle line in that case. "Signed" samples interpret the data a little different, as a signed 2-complement integer. In that case, the upper half of the sample data is mirrored, to put it in easy terms.

Note that this video is rather old, though, and you can simply draw your own chip samples in OpenMPT now, instead of writing weird text files.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

carbonthief

#4
Ahhh, that makes way more sense now then.  If you couldn't tell I've never actually worked with samples before.  I've only ever used VSTi's or similar plugins coupled with guitar recordings in programs like Cubase, so I'm totally new past few months to tracking software.

Going to be learning it now though, so I may come back with questions after I try drawing my own chip samples in OpenMPT.

edit: ok I have no idea what I'm doing.

edit2: Ok I've figured out that you can drag in a sample and then the pencil becomes ungreyed out, and then you can draw waves free hand, sorta, and I haven't figured out how to make anything useful.  I HAVE begun collecting samples from various places though.

carbonthief

#5
Ok I'm stumped.  How can I draw my own chip samples?  Like lets say I just wanted a sine wave, how would I make that?

edit: OK my new method is (after finally taking the time to figure out what makes milkytracker tick, also figured out how to make the buttons large enough to not give me eyestrain) to use milky tracker to create samples, and then I can use them in openmpt if I wish.

Saga Musix

It works exactly the same as in MilkyTracker. You need to create a very small waveform first (using the icon next to the pencil) - if you drag an existing sample into the sample editor, it is most likely to be too big to be a chip sample already, unless it was a chip sample from the very beginning. ;) Usually you'd choose a sample lenght of 64 or 128.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

carbonthief

Ohhh ok somehow my brain didn't make the connection yesterday to click the icon next to the pencil first.  I mean I clicked it, and then I was like "oh it just generates silence" and didn't think anything more about it, and was wondering "Gee why is the pencil greyed out."  Thanks for the help.