Skip to content

Commit

Permalink
Byteorder junk.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Dec 17, 2005
1 parent 1e681aa commit dfcb9f4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions osx/ALut.c
Expand Up @@ -140,6 +140,7 @@ ALUTAPI ALvoid ALUTAPIENTRY alutExit(ALvoid)

void SwapWords(unsigned int *puint)
{
#if __POWERPC__
unsigned int tempint;
char *pChar1, *pChar2;

Expand All @@ -151,10 +152,12 @@ void SwapWords(unsigned int *puint)
pChar1[1]=pChar2[2];
pChar1[2]=pChar2[1];
pChar1[3]=pChar2[0];
#endif
}

void SwapBytes(unsigned short *pshort)
{
#if __POWERPC__
unsigned short tempshort;
char *pChar1, *pChar2;

Expand All @@ -164,6 +167,7 @@ void SwapBytes(unsigned short *pshort)

pChar1[0]=pChar2[1];
pChar1[1]=pChar2[0];
#endif
}

void convert_c2pstr(char *string)
Expand Down
4 changes: 2 additions & 2 deletions osx/test/test.c
Expand Up @@ -8,8 +8,8 @@


#define LOAD_VORBIS 0
#define LOAD_MP3 1
#define LOAD_WAV 0
#define LOAD_MP3 0
#define LOAD_WAV 1
#define TEST_BUFFER_DATA 0
#define DUMP_WAV 0
#define TEST_AL_EXT_BUFFER_OFFSET 0
Expand Down

0 comments on commit dfcb9f4

Please sign in to comment.