Poll: Which jingle did you prefer?
You do not have permission to vote in this poll.
vain's 3 33.33%
pranomostro's 4 44.44%
venam's 2 22.22%
Total 9 vote(s) 100%
* You voted for this item. [Show Results]


Users browsing this thread: 1 Guest(s)
jmbi
Long time nixers
(06-06-2016, 03:27 PM)vain Wrote: I used to use aldrin and neil some years ago, but neither of them is currently available as a package for Arch and I'm extremely lazy today.

So ...

I remembered there was a posting about algorithmic music. I gave it a try.

Interpret the data as raw unsigned 8 bit PCM files with a sampling rate of 8kHz or 44kHz, depending on which block you choose. In other words: "./nixers | aplay -q -r 8000 -f U8"

Code:

Code:
#include <stdio.h>

int
main()
{
    int t;

#if 0
    /* Intro (8kHz) */
    for (t = 0; t < 32768; t++)
        putchar((unsigned char)(t | (-t >> 8)) - 128);
    for (t = 0; t < 65536; t++)
        putchar((unsigned char)((t * 4 | t * 2 | t) | (t >> 4) | (t >> 8)) / 2);
#endif

#if 0
    /* Intro (44kHz) */
    for (t = 0; t < 4 * 32768; t++)
        putchar((unsigned char)((t | (-t >> 8)) >> 2) - 128);
    for (t = 0; t < 4 * 65536; t++)
        putchar((unsigned char)(((t * 4 | t * 2 | t) | (t >> 4) | (t >> 8)) >> 2) / 2);
#endif

#if 0
    /* Outro (8kHz) */
    for (t = 0; t < 65536; t++)
        putchar((unsigned char)(t | (-t >> 10)) - 128);

    for (t = 32768; t < 65536; t++)
        putchar((unsigned char)((t * 8) | (t >> 4) | (t >> 8)) / 2);
#endif

#if 0
    /* Outro (44kHz) */
    for (t = 0; t < 4 * 65536; t++)
        putchar((unsigned char)((t | (-t >> 10)) >> 2) - 128);

    for (t = 4 * 32768; t < 4 * 65536; t++)
        putchar((unsigned char)(((t * 8) | (t >> 4) | (t >> 8)) >> 2) / 2);
#endif

    return 0;
}

No idea if you'd really consider using this, but I had a hell lot of fun. :)

Whoa, I really like that. Great work!


Messages In This Thread
Podcast Song Contest - by venam - 05-06-2016, 12:17 PM
RE: Podcast Song Contest - by z3bra - 05-06-2016, 01:18 PM
RE: Podcast Song Contest - by Adrift - 05-06-2016, 05:56 PM
RE: Podcast Song Contest - by venam - 06-06-2016, 04:01 AM
RE: Podcast Song Contest - by movq - 06-06-2016, 03:27 PM
RE: Podcast Song Contest - by jmbi - 06-06-2016, 03:32 PM
RE: Podcast Song Contest - by venam - 07-06-2016, 12:23 AM
RE: Podcast Song Contest - by acg - 07-06-2016, 01:38 AM
RE: Podcast Song Contest - by jmbi - 07-06-2016, 02:52 AM
RE: Podcast Song Contest - by venam - 07-06-2016, 02:59 AM
RE: Podcast Song Contest - by venam - 07-06-2016, 04:08 AM
RE: Podcast Song Contest - by tudurom - 07-06-2016, 08:39 AM
RE: Podcast Song Contest - by pranomostro - 07-06-2016, 01:08 PM
RE: Podcast Song Contest - by venam - 07-06-2016, 01:25 PM
RE: Podcast Song Contest - by pranomostro - 07-06-2016, 03:30 PM
RE: Podcast Song Contest - by movq - 08-06-2016, 12:55 PM
RE: Podcast Song Contest - by xero - 08-06-2016, 02:25 PM
RE: Podcast Song Contest - by stanislavjo - 08-06-2016, 02:42 PM
RE: Podcast Song Contest - by xero - 08-06-2016, 03:10 PM
RE: Podcast Song Contest - by venam - 09-06-2016, 12:47 AM
RE: Podcast Song Contest - by pranomostro - 09-06-2016, 01:56 PM
RE: Podcast Song Contest - by venam - 12-06-2016, 05:57 AM
RE: Podcast Song Contest - by pranomostro - 12-06-2016, 11:06 AM
RE: Podcast Song Contest - by venam - 12-06-2016, 11:38 AM
RE: Podcast Song Contest - by venam - 13-06-2016, 01:45 PM
RE: Podcast Song Contest - by venam - 16-06-2016, 11:39 AM
RE: Podcast Song Contest - by pranomostro - 16-06-2016, 03:55 PM
RE: Podcast Song Contest - by Adrift - 17-06-2016, 02:41 AM
RE: Podcast Song Contest - by venam - 19-06-2016, 04:05 AM
RE: Podcast Song Contest - by movq - 19-06-2016, 06:15 AM
RE: Podcast Song Contest - by pranomostro - 19-06-2016, 08:23 AM
RE: Podcast Song Contest - by xero - 20-06-2016, 02:44 PM