Mercurial > SDL_sound_CoreAudio
comparison SDL_sound.c @ 223:249186e31431
Sound_Rewind() support code.
author | Ryan C. Gordon <icculus@icculus.org> |
---|---|
date | Thu, 17 Jan 2002 20:55:46 +0000 |
parents | ca3483f4cfec |
children | 57e16a6d244f |
comparison
equal
deleted
inserted
replaced
222:d6b24586822a | 223:249186e31431 |
---|---|
780 internal->sdlcvt.len = internal->buffer_size; | 780 internal->sdlcvt.len = internal->buffer_size; |
781 | 781 |
782 return(newBufSize); | 782 return(newBufSize); |
783 } /* Sound_DecodeAll */ | 783 } /* Sound_DecodeAll */ |
784 | 784 |
785 | |
786 int Sound_Rewind(Sound_Sample *sample) | |
787 { | |
788 Sound_SampleInternal *internal; | |
789 BAIL_IF_MACRO(!initialized, ERR_NOT_INITIALIZED, 0); | |
790 | |
791 internal = (Sound_SampleInternal *) sample->opaque; | |
792 if (!internal->funcs->rewind(sample)) | |
793 { | |
794 sample->flags |= SOUND_SAMPLEFLAG_ERROR; | |
795 return(0); | |
796 } /* if */ | |
797 | |
798 sample->flags &= !SOUND_SAMPLEFLAG_EAGAIN; | |
799 sample->flags &= !SOUND_SAMPLEFLAG_ERROR; | |
800 sample->flags &= !SOUND_SAMPLEFLAG_EOF; | |
801 return(1); | |
802 } /* Sound_Rewind */ | |
803 | |
804 | |
785 /* end of SDL_sound.c ... */ | 805 /* end of SDL_sound.c ... */ |
786 | 806 |