> Also, how about an 'Electric Duet' player which could allow us to play > the tweedy two-voice music we've collectected and composed over the > years on other platforms? Perhaps extract to .WAV format and finally > hear them in 16-bit glory?
I have done this circa year 2000 - small program that converts "Electric Duet" files into stereo WAV by synthesizing harpsichord-like sound. They sound rather nice.
On Tue, 19 Jun 2012, Vladimir Ivanov wrote:
> There was a recent post on csa2:
>> Also, how about an 'Electric Duet' player which could allow us to play the >> tweedy two-voice music we've collectected and composed over the years on >> other platforms? Perhaps extract to .WAV format and finally hear them in >> 16-bit glory?
> I have done this circa year 2000 - small program that converts "Electric > Duet" files into stereo WAV by synthesizing harpsichord-like sound. They > sound rather nice.
> What is the best ELD collection to try it on?
Replying to myself. Grabbed some images off Asimov and here's the result:
1. The funny names are because I used CiderPress to extract the data files, then batch convert to WAV to MP3.
2. Voice commands are not supported.
3. Due to hardware limits Electric Duet player has bounds on pitch accuracy. I have tried to increase it wherever possible, but there are still few places that sound slightly out of tune.
Antoine Vignau wrote:
> On 19 juin, 22:06, Vladimir Ivanov <vlad...@XXXyahooXXX.com> wrote:
>> On Tue, 19 Jun 2012, Antoine Vignau wrote:
>> > Why don't you try it with Drift by Krüe ?
The player is ANSI C, single small file, converting from stdin to stdout. Example:
eldplay < electric_duet_file > file.wav
Two versions are provided.
"eldplay-oot.c" - the Out of Tune version, which uses same limited pitches as in Electric Duet. Keen observers may have noticed that some high notes are actually the same pitch because of insufficient accuracy.
"eldplay.c" - notes are translated to more precise equal-tempered scale, sounds nicer.
Some history on this - I originally made it to be eventually included as an Easter egg into a commercial product. In the end, I put a full featured MOD player.
Last but not least - my personal respect to Paul Lutus. Electric Duet and GraFORTH were part of my inspiration while growing as a kid.
Yes, because I dealt with MIDI parsing at a time and there is no problem outputting MIDI stream. What do you have in mind? Time is my real limiting factor for some time now.
BTW, you could probably do it in less than an hour with that said library. Electric Duet format is simple:
1) three byte records
2) byte0 is duration, except if equal to 0 or 1
3) byte1 is note1 and byte2 is note2
4) byte0=0 is end of tune
5) byte0=1 is "voice" command, which changes timbre (by changing duty ratio)
6) tables for duration and note periods are included in Electric Duet itself
I downloaded the source to play a bit, but didn't managed to build a functional binary. My binary generated waves that looks like a bar graph or the Manhattan Skyline : a long series of single phased rectangular waves (I checked it out with Audacity).
I think it's something on my compiling environment, I'm using WinXP, mingw and gcc 4.6.2.
Could you inform, please, the environment you used to successfully build your binaries?
> The player is ANSI C, single small file, converting from stdin to
> stdout. Example:
> eldplay < electric_duet_file > file.wav
> Two versions are provided.
> "eldplay-oot.c" - the Out of Tune version, which uses same limited
> pitches as in Electric Duet. Keen observers may have noticed that some
> high notes are actually the same pitch because of insufficient accuracy.
> "eldplay.c" - notes are translated to more precise equal-tempered scale,
> sounds nicer.
> Some history on this - I originally made it to be eventually included as
> an Easter egg into a commercial product. In the end, I put a full
> featured MOD player.
> Last but not least - my personal respect to Paul Lutus. Electric Duet
> and GraFORTH were part of my inspiration while growing as a kid.
Just a quick hack done in the dark ages, recently revived.
> I downloaded the source to play a bit, but didn't managed to build a > functional binary. My binary generated waves that looks like a bar graph > or the Manhattan Skyline : a long series of single phased rectangular > waves (I checked it out with Audacity).
> I think it's something on my compiling environment, I'm using WinXP, mingw > and gcc 4.6.2.
Is it 32 or 64-bit? I am not sure it is 64-bit safe, mostly the excite() function.
> Could you inform, please, the environment you used to successfully build > your binaries?
Linux 32-bit, gcc 4.4.5 on this particular machine, but that shouldn't matter.
It has been reworked a bit. There was a bug where the table of the notes (periods) was transposed from A to E, and the tempo was faster by about 14%. Also added option to dump the tune in text format and option to play with rectangular waveforms, both very similar to Electric Duet.
I will soon release the updated version, just a matter of spare time.
> Well, my one uses 24 Megabytes, while yours, just 2M. It's funny, but I just > though on doing this now. =]
Perfectly normal, since the website has MP3 files for bandwidth reasons. They have misleading ".wav" in the middle of the name, but that's because of batch conversion of:
M.xxx -> M.xxx.wav -> M.xxx.wav.mp3
Things done in a hurry.
> Perhaps we're dealing with some endianess problem? Your machine is i386?
Yes, i386. Talking about portability, I think:
- at least excite() is not 64-bit safe (the shift constant)
- it won't work on big-endian, because PCM data in WAV needs to be LE
- it should be alignment safe (no misaligned data accesses)
It is just a small toy program. I cheated shamelessly even on the WAV header. :-)