diff options
author | Volker Grabsch <vog@notjusthosting.com> | 2012-03-29 10:10:58 (GMT) |
---|---|---|
committer | Volker Grabsch <vog@notjusthosting.com> | 2012-03-29 10:10:58 (GMT) |
commit | 686c9ee25d23b5c57aa9ccdf549480caa1804c63 (patch) | |
tree | a34a13ad03f33824af6d78012d27b04e91aa5e00 /src | |
parent | a04d4ca72829098ce0b46176b0578543d85a8f9a (diff) | |
download | mxe-686c9ee25d23b5c57aa9ccdf549480caa1804c63.zip mxe-686c9ee25d23b5c57aa9ccdf549480caa1804c63.tar.gz mxe-686c9ee25d23b5c57aa9ccdf549480caa1804c63.tar.bz2 |
Fix line ending style (DOS -> Unix) for some test programs
Diffstat (limited to 'src')
-rw-r--r-- | src/gtkglextmm-test.cpp | 30 | ||||
-rw-r--r-- | src/sdl_sound-test.c | 108 |
2 files changed, 69 insertions, 69 deletions
diff --git a/src/gtkglextmm-test.cpp b/src/gtkglextmm-test.cpp index 2a10220..e6adbb6 100644 --- a/src/gtkglextmm-test.cpp +++ b/src/gtkglextmm-test.cpp @@ -1,15 +1,15 @@ -/*
- * This file is part of MXE.
- * See doc/index.html for further information.
- */
-
-#include <gtkmm/main.h>
-#include <gtkmm/gl/init.h>
-
-int main(int argc, char *argv[])
-{
- Gtk::Main g(argc, argv);
- Gtk::GL::init(argc, argv);
- g.run();
- return 0;
-}
+/* + * This file is part of MXE. + * See doc/index.html for further information. + */ + +#include <gtkmm/main.h> +#include <gtkmm/gl/init.h> + +int main(int argc, char *argv[]) +{ + Gtk::Main g(argc, argv); + Gtk::GL::init(argc, argv); + g.run(); + return 0; +} diff --git a/src/sdl_sound-test.c b/src/sdl_sound-test.c index 00d0418..cdea49c 100644 --- a/src/sdl_sound-test.c +++ b/src/sdl_sound-test.c @@ -1,54 +1,54 @@ -/*
- * This file is part of MXE.
- * See doc/index.html for further information.
- *
- * This is a simple test program for SDL_sound that tries to
- * decode the file specified as the only command-line argument.
- *
- * This file is in the Public Domain.
- */
-
-#include <stdio.h>
-#include <SDL_sound.h>
-
-int main(int argc, char *argv[])
-{
- if (argc != 2) {
- fprintf(stderr, "usage: %s <filename>\n", argv[0]);
- return 1;
- }
-
- if (SDL_Init(SDL_INIT_AUDIO) != 0) {
- fprintf(stderr, "Error: %s\n", SDL_GetError());
- return 1;
- }
-
- if (Sound_Init() == 0) {
- fprintf(stderr, "Error: %s\n", Sound_GetError());
- return 1;
- }
-
- SDL_RWops* rw = SDL_RWFromFile(argv[1], "r");
- if (rw == NULL) {
- fprintf(stderr, "Error: %s\n", SDL_GetError());
- return 1;
- }
-
- Sound_AudioInfo wantedFormat;
- wantedFormat.channels = 2;
- wantedFormat.rate = 44100;
- wantedFormat.format = AUDIO_S16LSB;
-
- Sound_Sample* sample = Sound_NewSample(rw, 0, &wantedFormat, 8192);
- if (sample == 0) {
- fprintf(stderr, "Error: %s\n", Sound_GetError());
- return 1;
- }
-
- Sound_DecodeAll(sample);
- printf("Format: %s\n", sample->decoder->description);
- printf("Decoded %d bytes of data.\n", sample->buffer_size);
- Sound_FreeSample(sample);
-
- return 0;
-}
+/* + * This file is part of MXE. + * See doc/index.html for further information. + * + * This is a simple test program for SDL_sound that tries to + * decode the file specified as the only command-line argument. + * + * This file is in the Public Domain. + */ + +#include <stdio.h> +#include <SDL_sound.h> + +int main(int argc, char *argv[]) +{ + if (argc != 2) { + fprintf(stderr, "usage: %s <filename>\n", argv[0]); + return 1; + } + + if (SDL_Init(SDL_INIT_AUDIO) != 0) { + fprintf(stderr, "Error: %s\n", SDL_GetError()); + return 1; + } + + if (Sound_Init() == 0) { + fprintf(stderr, "Error: %s\n", Sound_GetError()); + return 1; + } + + SDL_RWops* rw = SDL_RWFromFile(argv[1], "r"); + if (rw == NULL) { + fprintf(stderr, "Error: %s\n", SDL_GetError()); + return 1; + } + + Sound_AudioInfo wantedFormat; + wantedFormat.channels = 2; + wantedFormat.rate = 44100; + wantedFormat.format = AUDIO_S16LSB; + + Sound_Sample* sample = Sound_NewSample(rw, 0, &wantedFormat, 8192); + if (sample == 0) { + fprintf(stderr, "Error: %s\n", Sound_GetError()); + return 1; + } + + Sound_DecodeAll(sample); + printf("Format: %s\n", sample->decoder->description); + printf("Decoded %d bytes of data.\n", sample->buffer_size); + Sound_FreeSample(sample); + + return 0; +} |