Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8122 in orxonox.OLD for branches/osx/src/lib/sound/ogg_player.cc


Ignore:
Timestamp:
Jun 2, 2006, 5:46:11 PM (19 years ago)
Author:
ponder
Message:

Md2loader seems to work

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/osx/src/lib/sound/ogg_player.cc

    r7737 r8122  
    3131
    3232#include "debug.h"
     33
     34#ifdef HAVE_SDL_SDL_H
     35
     36#include <SDL/SDL.h>
     37#include <SDL/SDL_endian.h>
     38
     39#else
     40
     41#include <SDL.h>
     42#include <SDL_endian.h>
     43
     44#endif
    3345
    3446namespace OrxSound
     
    151163  bool OggPlayer::play()
    152164  {
    153     if (!(this->state & OggPlayer::FileOpened))
     165    /*if (!(this->state & OggPlayer::FileOpened))
    154166      return false;
    155167
     
    161173    if (this->musicThreadID == NULL)
    162174      return ((this->musicThreadID = SDL_CreateThread(OggPlayer::musicThread, (void*)this)) != NULL);
    163     return true;
     175    return true;*/
    164176  }
    165177
     
    374386    if(size == 0)
    375387      return false;
    376 
     388/*#ifdef SDL_BIG_ENDIAN
     389                        int cnt = wavLength/2;
     390                        Uint16* wavBufferAsShorts = ( Uint16* )wavBuffer;
     391                        for ( int i = 0; i < cnt; ++i, ++wavBufferAsShorts )
     392                                *wavBufferAsShorts = SDL_Swap16( *wavBufferAsShorts );
     393#endif*/
    377394    alBufferData(buffer, format, pcm, size, vorbisInfo->rate);
    378395    if (DEBUG_LEVEL >= 3)
Note: See TracChangeset for help on using the changeset viewer.