diff --git a/f7.c b/f7.c new file mode 100644 index 0000000..f9ba2f1 --- /dev/null +++ b/f7.c @@ -0,0 +1,5 @@ +#include "sounds.h" +int main() { + sound_loop_1(sound_7,0); +} +// vim:set sw=2 sts=2 et ai: diff --git a/main.c b/main.c index 9d2a09c..52212dd 100644 --- a/main.c +++ b/main.c @@ -7,7 +7,7 @@ #include "sounds.h" void usage(char* name, int exit_stat) { - fprintf(stderr, "Usage: %s [-f filename] < -s 1-6 >\n", name); + fprintf(stderr, "Usage: %s [-f filename] < -s 1-7 >\n", name); exit(exit_stat); } @@ -37,7 +37,7 @@ int main(int ac, char* av[]) { } if (sound_choice == 0) { - fprintf(stderr, "ERROR: pleaese choice a sound (currently 1-6)\n"); + fprintf(stderr, "ERROR: pleaese choice a sound (currently 1-7)\n"); usage(av[0], EXIT_FAILURE); } @@ -62,6 +62,9 @@ int main(int ac, char* av[]) { case 6: sound_loop_1(sound_6, 0); break; + case 7: + sound_loop_1(sound_7, 0); + break; } exit(EXIT_SUCCESS); diff --git a/sounds.c b/sounds.c index aea0962..e45097f 100644 --- a/sounds.c +++ b/sounds.c @@ -48,4 +48,10 @@ int sound_6(int t) { return ((30000000000/(y)&1)*35+(x)*y/400000000+((t>>8^t>>10|1>>14|x)&63)); } +int sound_7(int t) { + int i; + i=t<<2*(t^t*2); + return (((t&(t>>i)))^(t*("salve munde"[t>>13&7]&15))/12&32); +} + // vim:set sw=2 sts=2 et ai: diff --git a/sounds.h b/sounds.h index 79189ed..c5405fc 100644 --- a/sounds.h +++ b/sounds.h @@ -9,6 +9,7 @@ int sound_3(int t); int sound_4(int t); int sound_5(int t); int sound_6(int t); +int sound_7(int t); #endif