Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7286 in orxonox.OLD for trunk/src/lib


Ignore:
Timestamp:
Apr 13, 2006, 10:33:49 PM (19 years ago)
Author:
bensch
Message:

trunk: very stuck at the moment…. segfaults and errors everywhere…. maybe i will sync back soon… :/

Location:
trunk/src/lib/sound
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/sound/ogg_player.cc

    r7221 r7286  
    115115  SoundEngine::getInstance()->pushALSource(source);
    116116  this->source = 0;
    117   check();
     117  SoundEngine::checkError("OggPlayer::release Source", __LINE__);
    118118  alDeleteBuffers(2, buffers);
    119119  this->buffers[0] = 0;
    120120  this->buffers[1] = 0;
    121   check();
     121  SoundEngine::checkError("OggPlayer::release", __LINE__);
    122122
    123123  ov_clear(&oggStream);
     
    184184
    185185    alSourceUnqueueBuffers(source, 1, &buffer);
    186     check();
     186    SoundEngine::checkError("OggPlayer::update() error", __LINE__);
    187187
    188188    active = stream(buffer);
    189189
    190190    alSourceQueueBuffers(source, 1, &buffer);
    191     check();
     191    SoundEngine::checkError("OggPlayer::update()", __LINE__);
    192192  }
    193193
     
    226226
    227227  alBufferData(buffer, format, pcm, size, vorbisInfo->rate);
    228   check();
     228  SoundEngine::checkError("OggPlayer::stream()", __LINE__);
    229229
    230230  return true;
     
    246246
    247247    alSourceUnqueueBuffers(source, 1, &buffer);
    248     check();
     248    SoundEngine::checkError("OggPlayer::empty()", __LINE__);
    249249  }
    250250}
     
    273273}
    274274
    275 /**
    276  * checks for errors
    277  */
    278 void OggPlayer::check()
    279 {
    280   int error = alGetError();
    281   if(error != AL_NO_ERROR)
    282     PRINTF(2)("OpenAL error was raised.");
    283 }
    284275
    285276/**
  • trunk/src/lib/sound/ogg_player.h

    r7221 r7286  
    4141  bool stream(ALuint buffer);
    4242  void empty();
    43   void check();
    4443  const char* errorString(int code);
    4544
  • trunk/src/lib/sound/sound_source.cc

    r7285 r7286  
    6868  if (unlikely(this->sourceID == 0))
    6969    SoundEngine::getInstance()->popALSource(this->sourceID);
    70   assert (this->sourceID != 0);
     70  //assert (this->sourceID != 0);
    7171
    7272  alSourceStop(this->sourceID);
Note: See TracChangeset for help on using the changeset viewer.