Skip to content

Commit

Permalink
Changed _D macro to DBGSND.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Sep 24, 2001
1 parent 0a8fce0 commit 362024e
Show file tree
Hide file tree
Showing 9 changed files with 37 additions and 37 deletions.
22 changes: 11 additions & 11 deletions SDL_sound.c
Expand Up @@ -218,7 +218,7 @@ void Sound_SetError(const char *err)
{
if (err != NULL)
{
_D(("Sound_SetError(\"%s\");\n", err));
SNDDBG(("Sound_SetError(\"%s\");\n", err));
SDL_SetError(err);
} /* if */
} /* Sound_SetError */
Expand Down Expand Up @@ -395,18 +395,18 @@ static int init_sample(const Sound_DecoderFunctions *funcs,
} /* if */
samplesList = sample;

_D(("New sample DESIRED format: %s format, %d rate, %d channels.\n",
fmt_to_str(sample->desired.format),
sample->desired.rate,
sample->desired.channels));
SNDDBG(("New sample DESIRED format: %s format, %d rate, %d channels.\n",
fmt_to_str(sample->desired.format),
sample->desired.rate,
sample->desired.channels));

_D(("New sample ACTUAL format: %s format, %d rate, %d channels.\n",
fmt_to_str(sample->actual.format),
sample->actual.rate,
sample->actual.channels));
SNDDBG(("New sample ACTUAL format: %s format, %d rate, %d channels.\n",
fmt_to_str(sample->actual.format),
sample->actual.rate,
sample->actual.channels));

_D(("On-the-fly conversion: %s.\n",
internal->sdlcvt.needed ? "ENABLED" : "DISABLED"));
SNDDBG(("On-the-fly conversion: %s.\n",
internal->sdlcvt.needed ? "ENABLED" : "DISABLED"));

return(1);
} /* init_sample */
Expand Down
4 changes: 2 additions & 2 deletions SDL_sound_internal.h
Expand Up @@ -36,9 +36,9 @@
#include "SDL.h"

#if (defined DEBUG_CHATTER)
#define _D(x) printf x
#define SNDDBG(x) printf x
#else
#define _D(x)
#define SNDDBG(x)
#endif

typedef struct __SOUND_DECODERFUNCTIONS__
Expand Down
4 changes: 2 additions & 2 deletions decoders/aiff.c
Expand Up @@ -151,7 +151,7 @@ static void AIFF_quit(void)
} /* AIFF_quit */


/*
/*
* Sample rate is encoded as an "80 bit IEEE Standard 754 floating point
* number (Standard Apple Numeric Environment [SANE] data type Extended)".
* Whose bright idea was that?
Expand Down Expand Up @@ -344,7 +344,7 @@ static int AIFF_open(Sound_Sample *sample, const char *ext)

sample->flags = SOUND_SAMPLEFLAG_NONE;

_D(("AIFF: Accepting data stream.\n"));
SNDDBG(("AIFF: Accepting data stream.\n"));
return(1); /* we'll handle this data. */
} /* AIFF_open */

Expand Down
2 changes: 1 addition & 1 deletion decoders/mod.c
Expand Up @@ -237,7 +237,7 @@ static int MOD_open(Sound_Sample *sample, const char *ext)
/* !!! FIXME: A little late to be giving this information... */
sample->flags = SOUND_SAMPLEFLAG_NEEDSEEK;

_D(("MOD: Accepting data stream\n"));
SNDDBG(("MOD: Accepting data stream\n"));
return(1); /* we'll handle this data. */
} /* MOD_open */

Expand Down
30 changes: 15 additions & 15 deletions decoders/mp3.c
Expand Up @@ -89,7 +89,7 @@ static __inline__ void output_version(void)
{
SMPEG_version v;
SMPEG_VERSION(&v);
_D(("MP3: Compiled against SMPEG v%d.%d.%d.\n",
SNDDBG(("MP3: Compiled against SMPEG v%d.%d.%d.\n",
v.major, v.minor, v.patch));
first_time = 0;
} /* if */
Expand Down Expand Up @@ -126,7 +126,7 @@ static int MP3_open(Sound_Sample *sample, const char *ext)
refCounter = RWops_RWRefCounter_new(internal->rw);
if (refCounter == NULL)
{
_D(("MP3: Failed to create reference counting RWops.\n"));
SNDDBG(("MP3: Failed to create reference counting RWops.\n"));
return(0);
} /* if */

Expand Down Expand Up @@ -154,19 +154,19 @@ static int MP3_open(Sound_Sample *sample, const char *ext)
return(0);
} /* if */

_D(("MP3: Accepting data stream.\n"));
_D(("MP3: has_audio == {%s}.\n", smpeg_info.has_audio ? "TRUE" : "FALSE"));
_D(("MP3: has_video == {%s}.\n", smpeg_info.has_video ? "TRUE" : "FALSE"));
_D(("MP3: width == (%d).\n", smpeg_info.width));
_D(("MP3: height == (%d).\n", smpeg_info.height));
_D(("MP3: current_frame == (%d).\n", smpeg_info.current_frame));
_D(("MP3: current_fps == (%f).\n", smpeg_info.current_fps));
_D(("MP3: audio_string == [%s].\n", smpeg_info.audio_string));
_D(("MP3: audio_current_frame == (%d).\n", smpeg_info.audio_current_frame));
_D(("MP3: current_offset == (%d).\n", smpeg_info.current_offset));
_D(("MP3: total_size == (%d).\n", smpeg_info.total_size));
_D(("MP3: current_time == (%f).\n", smpeg_info.current_time));
_D(("MP3: total_time == (%f).\n", smpeg_info.total_time));
SNDDBG(("MP3: Accepting data stream.\n"));
SNDDBG(("MP3: has_audio == {%s}.\n", smpeg_info.has_audio ? "TRUE" : "FALSE"));
SNDDBG(("MP3: has_video == {%s}.\n", smpeg_info.has_video ? "TRUE" : "FALSE"));
SNDDBG(("MP3: width == (%d).\n", smpeg_info.width));
SNDDBG(("MP3: height == (%d).\n", smpeg_info.height));
SNDDBG(("MP3: current_frame == (%d).\n", smpeg_info.current_frame));
SNDDBG(("MP3: current_fps == (%f).\n", smpeg_info.current_fps));
SNDDBG(("MP3: audio_string == [%s].\n", smpeg_info.audio_string));
SNDDBG(("MP3: audio_current_frame == (%d).\n", smpeg_info.audio_current_frame));
SNDDBG(("MP3: current_offset == (%d).\n", smpeg_info.current_offset));
SNDDBG(("MP3: total_size == (%d).\n", smpeg_info.total_size));
SNDDBG(("MP3: current_time == (%f).\n", smpeg_info.current_time));
SNDDBG(("MP3: total_time == (%f).\n", smpeg_info.total_time));

SMPEG_enablevideo(smpeg, 0);
SMPEG_enableaudio(smpeg, 1);
Expand Down
2 changes: 1 addition & 1 deletion decoders/raw.c
Expand Up @@ -112,7 +112,7 @@ static int RAW_open(Sound_Sample *sample, const char *ext)
return(0);
} /* if */

_D(("RAW: Accepting data stream.\n"));
SNDDBG(("RAW: Accepting data stream.\n"));

/*
* We never convert raw samples; what you ask for is what you get.
Expand Down
2 changes: 1 addition & 1 deletion decoders/skeleton.c
Expand Up @@ -91,7 +91,7 @@ static int FMT_open(Sound_Sample *sample, const char *ext)
return(0);
} /* if */

_D(("FMT: Accepting data stream.\n"));
SNDDBG(("FMT: Accepting data stream.\n"));
set up sample->actual;
sample->flags = SOUND_SAMPLEFLAG_NONE;
return(1); /* we'll handle this data. */
Expand Down
6 changes: 3 additions & 3 deletions decoders/voc.c
Expand Up @@ -88,7 +88,7 @@ typedef struct vocstuff {
Uint32 bufpos; /* byte position in internal->buffer. */
} vs_t;

/* Size field */
/* Size field */
/* SJB: note that the 1st 3 are sometimes used as sizeof(type) */
#define ST_SIZE_BYTE 1
#define ST_SIZE_8BIT 1
Expand Down Expand Up @@ -187,7 +187,7 @@ static int voc_get_block(Sound_Sample *sample)

if (SDL_RWread(src, bits24, sizeof (bits24), 1) != 1)
return 1; /* assume that's the end of the file. */

/* Size is an 24-bit value. Ugh. */
sblen = ( (bits24[0]) | (bits24[1] << 8) | (bits24[2] << 16) );

Expand Down Expand Up @@ -444,7 +444,7 @@ static int VOC_open(Sound_Sample *sample, const char *ext)
return(0);
} /* if */

_D(("VOC: Accepting data stream.\n"));
SNDDBG(("VOC: Accepting data stream.\n"));
sample->actual.format = (v->size == ST_SIZE_WORD) ? AUDIO_S16LSB:AUDIO_U8;
sample->actual.channels = v->channels;
sample->flags = SOUND_SAMPLEFLAG_NONE;
Expand Down
2 changes: 1 addition & 1 deletion decoders/wav.c
Expand Up @@ -235,7 +235,7 @@ static int WAV_open(Sound_Sample *sample, const char *ext)

sample->flags = SOUND_SAMPLEFLAG_NONE;

_D(("WAV: Accepting data stream.\n"));
SNDDBG(("WAV: Accepting data stream.\n"));
return(1); /* we'll handle this data. */
} /* WAV_open */

Expand Down

0 comments on commit 362024e

Please sign in to comment.