cAudio
2.3.0
3d Audio Engine
cAudio
src
cAudioSleep.cpp
1
// Copyright (c) 2008-2011 Raynaldo (Wildicv) Rivera, Joshua (Dark_Kilauea) Jones, Murat (wolfmanfx) Sari
2
// This file is part of the "cAudio Engine"
3
// For conditions of distribution and use, see copyright notice in cAudio.h
4
5
#include "cAudioPlatform.h"
6
7
#ifndef CAUDIO_PLATFORM_WIN
8
#include <unistd.h>
//Assumed linux system, include for usleep()
9
#include <time.h>
10
#endif //If you need to support another platform, simply add a define for it
11
12
#include "cAudioSleep.h"
13
14
namespace
cAudio
15
{
16
17
void
cAudioSleep
(
unsigned
int
ms)
18
{
19
#ifdef CAUDIO_PLATFORM_WIN
20
Sleep(ms);
21
#else
22
usleep(ms*1000);
//convert from milliseconds to microseconds
23
#endif
24
}
25
26
};
cAudio::cAudioSleep
CAUDIO_API void cAudioSleep(unsigned int ms)
Causes the current thread to give up control for a certain duration.
Definition:
cAudioSleep.cpp:17
cAudio
Main namespace for the entire cAudio library.
Definition:
cAudioCapture.h:15
Generated on Fri Feb 10 2017 07:35:18 for cAudio by
1.8.13