summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorStanislav Vorobiov <s.vorobiov@samsung.com>2014-01-24 18:19:11 +0400
committerStanislav Vorobiov <s.vorobiov@samsung.com>2014-01-30 15:40:56 +0400
commit7628db082fdca2550f9ebc92e84aa116953d18bf (patch)
tree3b2ac9a31904bbb5cd2252a946c4e847f8754a14 /include
parentdd225442f103ed3b0f2b6a084f677e443a9598b7 (diff)
downloademulator-yagl-7628db082fdca2550f9ebc92e84aa116953d18bf.tar.gz
emulator-yagl-7628db082fdca2550f9ebc92e84aa116953d18bf.tar.bz2
emulator-yagl-7628db082fdca2550f9ebc92e84aa116953d18bf.zip
YaGL: EGL_KHR_fence_sync and GLESv3 sync objects implemented
Change-Id: I99eb93e66f2614306e9e91de20b46a46dff727cb
Diffstat (limited to 'include')
-rw-r--r--include/yagl_egl_fence.h31
-rw-r--r--include/yagl_sharegroup.h2
-rw-r--r--include/yagl_transport.h8
3 files changed, 36 insertions, 5 deletions
diff --git a/include/yagl_egl_fence.h b/include/yagl_egl_fence.h
new file mode 100644
index 0000000..91e20da
--- /dev/null
+++ b/include/yagl_egl_fence.h
@@ -0,0 +1,31 @@
+#ifndef _YAGL_EGL_FENCE_H_
+#define _YAGL_EGL_FENCE_H_
+
+#include "yagl_export.h"
+#include "yagl_types.h"
+#include "yagl_resource.h"
+
+struct yagl_egl_fence
+{
+ struct yagl_resource res;
+
+ int (*wait)(struct yagl_egl_fence */*egl_fence*/);
+
+ int (*signaled)(struct yagl_egl_fence */*egl_fence*/);
+};
+
+YAGL_API int yagl_egl_fence_supported(void);
+
+/*
+ * Passing NULL won't hurt, this is for convenience.
+ */
+YAGL_API void yagl_egl_fence_acquire(struct yagl_egl_fence *egl_fence);
+
+/*
+ * Passing NULL won't hurt, this is for convenience.
+ */
+YAGL_API void yagl_egl_fence_release(struct yagl_egl_fence *egl_fence);
+
+YAGL_API struct yagl_egl_fence *yagl_create_egl_fence(void);
+
+#endif
diff --git a/include/yagl_sharegroup.h b/include/yagl_sharegroup.h
index 04f5192..f8a8a2a 100644
--- a/include/yagl_sharegroup.h
+++ b/include/yagl_sharegroup.h
@@ -6,7 +6,7 @@
#include "yagl_ref.h"
#include "yagl_namespace.h"
-#define YAGL_NUM_NAMESPACES 5
+#define YAGL_NUM_NAMESPACES 6
struct yagl_sharegroup
{
diff --git a/include/yagl_transport.h b/include/yagl_transport.h
index 02d967f..3c6b926 100644
--- a/include/yagl_transport.h
+++ b/include/yagl_transport.h
@@ -12,15 +12,15 @@
#define YAGL_TRANSPORT_MAX_IN_DA 8
#define YAGL_TRANSPORT_MAX_OUT_DA 8
+struct yagl_egl_fence;
+
struct yagl_transport_ops
{
void *(*resize)(void */*ops_data*/, uint32_t /*size*/);
void (*commit)(void */*ops_data*/, int /*sync*/);
- uint32_t (*flush)(void */*ops_data*/, void **/*fence*/);
-
- void (*fence_wait)(void */*ops_data*/, void */*fence*/);
+ uint32_t (*flush)(void */*ops_data*/, struct yagl_egl_fence **/*fence*/);
};
struct yagl_transport_in_arg
@@ -108,7 +108,7 @@ YAGL_API void yagl_transport_begin(struct yagl_transport *t,
YAGL_API void yagl_transport_end(struct yagl_transport *t);
YAGL_API void yagl_transport_flush(struct yagl_transport *t,
- void *fence);
+ struct yagl_egl_fence *fence);
/*
* Waits until all commands for this transport