summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/common/driverfuncs.c
diff options
context:
space:
mode:
authorAndres Rodriguez <[email protected]>2017-07-12 18:45:07 -0400
committerTimothy Arceri <[email protected]>2017-08-06 12:42:06 +1000
commit8b7c5744791fe403375dd1d61c4a99b882044415 (patch)
treeec5728914a1f98d8d55c9919d304f479e225481e /src/mesa/drivers/common/driverfuncs.c
parent322ee1b3636a38c22bc65009f13667a9d5f438cf (diff)
mesa: add support for memory object creation/import/delete
Used by EXT_external_objects and EXT_external_objects_fd V2 (Timothy Arceri): - Throw GL_OUT_OF_MEMORY error if CreateMemoryObjectsEXT() fails. - C99 tidy ups - remove void cast (Constantine Kharlamov) V3 (Timothy Arceri): - rename mo -> memObj - check that the object is not NULL before initializing - add missing "EXT" in function error message V4 (Timothy Arceri): - remove checks for (memory objecy id == 0) and catch in _mesa_lookup_memory_object() instead. Signed-off-by: Andres Rodriguez <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
Diffstat (limited to 'src/mesa/drivers/common/driverfuncs.c')
-rw-r--r--src/mesa/drivers/common/driverfuncs.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/drivers/common/driverfuncs.c b/src/mesa/drivers/common/driverfuncs.c
index 5008ae8feaf..ddb4bb6d6a1 100644
--- a/src/mesa/drivers/common/driverfuncs.c
+++ b/src/mesa/drivers/common/driverfuncs.c
@@ -49,6 +49,7 @@
#include "main/syncobj.h"
#include "main/barrier.h"
#include "main/transformfeedback.h"
+#include "main/externalobjects.h"
#include "program/program.h"
#include "tnl/tnl.h"
@@ -166,6 +167,9 @@ _mesa_init_driver_functions(struct dd_function_table *driver)
_mesa_init_sync_object_functions(driver);
+ /* memory objects */
+ _mesa_init_memory_object_functions(driver);
+
driver->NewFramebuffer = _mesa_new_framebuffer;
driver->NewRenderbuffer = _swrast_new_soft_renderbuffer;
driver->MapRenderbuffer = _swrast_map_soft_renderbuffer;