diff options
| author | David 'Digit' Turner <digit@google.com> | 2014-03-10 15:16:30 +0100 |
|---|---|---|
| committer | David 'Digit' Turner <digit@google.com> | 2014-03-11 10:24:51 +0100 |
| commit | aac93f1585bc9bdf8a57b6ed3c47c24f56a3990a (patch) | |
| tree | 27409568ac69f1efca05cbe75bc10883088db5c2 /emulator/opengl/host/libs/Translator/GLES_V2 | |
| parent | fd8752eb6a438832e0ba9a19db896614403f8945 (diff) | |
| download | sdk-aac93f1585bc9bdf8a57b6ed3c47c24f56a3990a.zip sdk-aac93f1585bc9bdf8a57b6ed3c47c24f56a3990a.tar.gz sdk-aac93f1585bc9bdf8a57b6ed3c47c24f56a3990a.tar.bz2 | |
emulator/opengl: Remove android::Mutex.
This patch removes the dependency on android::Mutex from
<cutils/threads.h> by providing a custom implementation, which
is a simple wrapper around pthread_mutex_t / CriticalSection,
under shared/emugl/common/mutex.h
+ Provide unit tests.
Change-Id: I379ef0c480c478ab9ba5f2faaf8274267eff37ba
Diffstat (limited to 'emulator/opengl/host/libs/Translator/GLES_V2')
4 files changed, 4 insertions, 4 deletions
diff --git a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.cpp b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.cpp index 1457cec..f8f674b 100644 --- a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.cpp +++ b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.cpp @@ -15,11 +15,10 @@ */ #include "GLESv2Context.h" - - +#include <string.h> void GLESv2Context::init() { - android::Mutex::Autolock mutex(s_lock); + emugl::Mutex::AutoLock mutex(s_lock); if(!m_initialized) { s_glDispatch.dispatchFuncs(GLES_2_0); GLEScontext::init(); diff --git a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.h b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.h index 75af864..7e71177 100644 --- a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.h +++ b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Context.h @@ -20,7 +20,6 @@ #include <GLcommon/GLDispatch.h> #include <GLcommon/GLEScontext.h> #include <GLcommon/objectNameManager.h> -#include <utils/threads.h> diff --git a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Validate.cpp b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Validate.cpp index 53d1314..3f00428 100644 --- a/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Validate.cpp +++ b/emulator/opengl/host/libs/Translator/GLES_V2/GLESv2Validate.cpp @@ -14,6 +14,7 @@ * limitations under the License. */ #include "GLESv2Validate.h" +#include <string.h> bool GLESv2Validate::blendEquationMode(GLenum mode){ return mode == GL_FUNC_ADD || diff --git a/emulator/opengl/host/libs/Translator/GLES_V2/ShaderParser.cpp b/emulator/opengl/host/libs/Translator/GLES_V2/ShaderParser.cpp index a80326d..311a9ed 100644 --- a/emulator/opengl/host/libs/Translator/GLES_V2/ShaderParser.cpp +++ b/emulator/opengl/host/libs/Translator/GLES_V2/ShaderParser.cpp @@ -15,6 +15,7 @@ */ #include "ShaderParser.h" +#include <stdlib.h> #include <string.h> ShaderParser::ShaderParser():ObjectData(SHADER_DATA), |
