Commit Graph

24 Commits

Author SHA1 Message Date
Yochai Shefi Simchon
889d928f29 Fix a bug where eglMakeCurrent(NULL) did not work
This happened because the VALIDATE macros terminated the function prematurally.
Also clear the surface bindings from the previous context.

Change-Id: I33d587f5e877caa6ec651a04ff887e0c77a9d5f3
2011-05-31 15:01:59 +03:00
Yochai Shefi Simchon
88ec3acc83 Fix a mess in contexts/surfaces reference count
The main issue was that SmartPtr had an implicit cast to void*, returning its
internal pointer. This allowed writing unsafe code, since the internal pointer
could be handled without increasing its ref count.
So, removed this cast and fixed the various places which relied on it.
Also, fix two calls to "destroy" ahich should have been "markForDestruction".
The naming is not good, should probably change it in a later patch.

Change-Id: Idabc800e97649b2e2404fb7387d25deac70af62e
2011-05-31 15:01:59 +03:00
Yochai Shefi Simchon
eada5b81de ThreadInfo- use explicit rather than void pointers
Replace the void* pointers with explicit pointers for EglContext, EglDisplay
and GLEScontext. Use forward declarations. This is to improve finding errors
in compile time rather than on run time.

Change-Id: Iaec3c36c1e12f36b37d34f68e9d8aa58ff1b30c0
2011-05-31 14:59:20 +03:00
Yochai Shefi Simchon
094026698e Fix version returned by eglInitialize from 4.1 to 1.4.
Change-Id: I43f3512374f546a81b7cfbba8959ce9f0ed7fe53
2011-05-31 14:15:02 +03:00
Yochai Shefi Simchon
aac7fe282c EglChooseConfig should handle the case where "configs" is NULL.
Change-Id: I236afdfc73eb5dd5a3ab19e2b388772ea297bdb4
2011-05-31 14:13:26 +03:00
Amit Feller
624176d51a Emulators's GLES 2.0 translator implementation
This is the GLESv2 on top of openGL implementation on the host
most of this change is moving code which is necessary by both
GLES 1.0 and GLES 2.0 implementations from GLES_CM folder into
GLcommon folder.

GLESv2Imp - includes GLES 2.0 entry points implementation

Change-Id: I934fb963478a7f596d824612f847a5aa77d2ed9d
2011-05-30 11:06:24 +03:00
David Turner
fd6ed4dd31 Merge "adding functionality to get the local name of an object from it's local name" 2011-05-18 06:52:22 -07:00
Amit Feller
f0b7c2e4f9 this checkin supports windows OS in all Translator libs
Note: this is a re-submit of Ie5111d9c435b64d205b140a79863c0273742ee7f,
fixed to avoid breaking the Mac build.

Change-Id: Ib534063d3f403d33d162956bf510baf9689a246a
2011-05-17 21:28:17 +02:00
David 'Digit' Turner
2840185690 Fix mac build
Change-Id: I1fc8c5043160dbe2508324655fb506bc31cc50ac
2011-05-17 21:00:52 +02:00
Raphael Moll
603b37abac Revert "this checkin supports windows OS in all Translator libs"
This reverts commit 0bf6848571.

This commit breaks Mca builds:
  development/tools/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp: In function 'EGLBoolean eglChooseConfig(void*, const EGLint*, void**, EGLint, EGLint*)':
  development/tools/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp:412: error: 'PIXEL_FORMAT_INITIALIZER' was not declared in this scope
  make: *** [out/host/darwin-x86/obj/SHARED_LIBRARIES/libEGL_translator_intermediates/EglImp.o] Error 1
2011-05-17 11:41:30 -07:00
Amit Feller
1f4c692222 adding functionality to get the local name of an object from it's local name
Change-Id: I8c9ccc36a5fb70a38a77fa0f0e7826a6fe886db1
2011-05-17 16:10:27 +03:00
Amit Feller
02c3e538e8 fixing bug in the name of GL function "glClearDepthf" --> "glClearDeapth"
Change-Id: I9700bdb973d2dc01400078c349010a271004dbd9
2011-05-17 15:33:43 +03:00
Amit Feller
0bf6848571 this checkin supports windows OS in all Translator libs
Change-Id: Ie5111d9c435b64d205b140a79863c0273742ee7f
2011-05-17 11:20:25 +03:00
Amit Feller
6203540306 small changes to the code before the commit for supporting windows os
Change-Id: I062add6d6340677a9e2e98ac47d53c87ad2a6535
2011-05-11 17:48:21 +03:00
Amit Feller
e387c21109 changing GLcommon lib to be a sharedlib instead of static
Change-Id: Ic1fdcd1fbf3105a6fbd26c77e58acbe9b09dcacb
2011-05-11 17:31:02 +03:00
David Turner
fdd5607a6d emulator: opengl: Fix Mac and Windows builds.
+ Fix typo in clean step.

Change-Id: I1da8b17a167247d252b5e8519832b042c2db3ccd
2011-05-03 18:29:27 +02:00
David 'Digit' Turner
4707d72787 adding error handling for Xerrors on EGl linux implementation (EglLinuxApi.cpp)
Change-Id: Ib8535e2c25c7de67c8d7830a644643b52742ceaa
2011-05-03 16:42:44 +02:00
Amit Feller
25d29c4778 adding support for getting gles proc address from eglGetProcAdress
Change-Id: Ife1b3be5abd181cce837eebbf993e99759eec8e7
2011-05-03 13:34:13 +02:00
David Turner
2d3b98f87b emulator: opengl: Fix Mac build
This fixes several issues when building the host libraris on Darwin.
Note that there is still not proper implementation of backend functions.

Change-Id: I3ba4120df6545a8c2aa62fdfcaadaf5ff4972456
2011-05-02 14:08:03 +02:00
Amit Feller
0ff6e7917b supporting EGL_KHR_image_base & EGL_KHR_gl_texture_2d_image extentions
Change-Id: I69c3e975c892bcd0872c47e349b427f570d7e82d
2011-04-29 22:10:43 +02:00
Amit Feller
fce7b684b1 integrating objectNameManger into GLES implementation
Change-Id: Icda250f9e9d3af15a2d7c214136b777833d5596d
2011-04-29 22:10:43 +02:00
Amit Feller
a245cb125f Emulator's host translator EGL implementation.
This is the EGL implementation for the host EGL/GLES translator.

EglImp.cpp - includes the EGL entry points implementation.
ThreadInfo.cpp - defines the per-thread info which is shared to EGL and GLES
EglOsApi.h - platform dependant interface functions.
EglLinuxApi.cpp - implements the GLX platform of EglOsApi
EglWindowsApi.cpp - implenents the Windows platform of EglOsApi - This has not been compiled yet!!!

Change-Id: I30a8cf457858ef04febf67005787d8d18e5e7a70
2011-04-29 22:10:43 +02:00
Amit Feller
03dcd431cc Emulator's GLES translator implementation.
This is the GLESv1 on top of OpenGL implementation on the host.
GLDispatch - dispatch table to host OpenGL implementation.
GLESimp - includes GLES entry points implementation.

Change-Id: Ief5eac2253a5a98b75a5d76363a36b7587d17391
2011-04-29 22:10:43 +02:00
Amit Feller
a7ec4c76e2 This is a common library for the EGL/GLES/GLES2 translator libraries.
It includes code that is shared with all three components:

    ThreadInfo.h - defines a structure of information stored in the TLS.
    TranslatorIfaces - defines the interface between EGL and its client APIs (GLES and GLESv2)
    objectrNameManager - manages the set of OpenGL objects in share groups name space.

Change-Id: Idb1bd1e2c3dcbb5dac7ba4ea85f78da856b897d9
2011-04-12 15:28:14 +03:00