src/shl_hook.h \
src/shl_misc.h \
src/shl_register.h \
- src/shl_flagset.h
+ src/shl_flagset.h \
+ src/shl_gl.h \
+ src/shl_gl_math.c
libshl_la_CPPFLAGS = \
$(AM_CPPFLAGS) \
$(XKBCOMMON_CFLAGS) \
$(AM_LIBADD) \
$(XKBCOMMON_LIBS)
+if BUILD_HAVE_GLES2
+libshl_la_SOURCES += src/shl_gl_shader.c
+libshl_la_CPPFLAGS += $(GLES2_CFLAGS)
+libshl_la_LIBADD += $(GLES2_LIBS)
+endif
+
#
# libeloop
# This library contains the whole event-loop implementation of kmscon. It is
libuterm_la_SOURCES += \
src/uterm_drm3d_internal.h \
src/uterm_drm3d_video.c \
- src/uterm_drm3d_render.c \
- src/static_gl.h \
- src/static_gl_math.c \
- src/static_gl_shader.c
+ src/uterm_drm3d_render.c
nodist_libuterm_la_SOURCES += src/static_shaders.c
libuterm_la_CPPFLAGS += \
$(DRM_CFLAGS) \
mod_gltex_la_SOURCES = \
src/kmscon_module_interface.h \
src/text_gltex.c \
- src/static_gl.h \
- src/static_gl_math.c \
- src/static_gl_shader.c \
src/kmscon_mod_gltex.c
nodist_mod_gltex_la_SOURCES = \
src/static_shaders.c
AC_MSG_RESULT([no])
fi
+# gles2 helpers
+AM_CONDITIONAL([BUILD_HAVE_GLES2], [test "x$have_gles2" = "xyes"])
+
#
# Makefile vars
# After everything is configured, we correctly substitute the values for the
/*
- * kmscon - OpenGL Helpers
+ * shl - OpenGL Helpers
*
- * Copyright (c) 2011-2012 David Herrmann <dh.herrmann@googlemail.com>
- * Copyright (c) 2011 University of Tuebingen
+ * Copyright (c) 2011-2013 David Herrmann <dh.herrmann@gmail.com>
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files
* OpenGL Helpers
* This file provides several helper functions that are commonly used when
* working with OpenGL.
+ * TODO: Rename to shl_gl_* prefix.
*/
-#ifndef GL_H_INCLUDED
-#define GL_H_INCLUDED
+#ifndef SHL_GL_H
+#define SHL_GL_H
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
bool gl_has_error(struct gl_shader *shader);
const char *gl_err_to_str(GLenum err);
-#endif /* GL_H_INCLUDED */
+#endif /* SHL_GL_H */
/*
- * kmscon - GL Math Helpers
+ * shl - OpenGL Helpers
*
- * Copyright (c) 2011 David Herrmann <dh.herrmann@googlemail.com>
- * Copyright (c) 2011 University of Tuebingen
+ * Copyright (c) 2011-2013 David Herrmann <dh.herrmann@gmail.com>
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files
#include <errno.h>
#include <stdlib.h>
#include <string.h>
-#include "static_gl.h"
+#include "shl_gl.h"
struct gl_m4_entry {
struct gl_m4_entry *next;
/*
- * GL - Graphics Layer
+ * shl - OpenGL Helpers
*
- * Copyright (c) 2011-2012 David Herrmann <dh.herrmann@googlemail.com>
- * Copyright (c) 2011 University of Tuebingen
+ * Copyright (c) 2011-2013 David Herrmann <dh.herrmann@gmail.com>
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
+#include "shl_gl.h"
#include "shl_llog.h"
-#include "static_gl.h"
#define LLOG_SUBSYSTEM "gl_shader"
#include <stdlib.h>
#include <string.h>
#include "shl_dlist.h"
+#include "shl_gl.h"
#include "shl_hashtable.h"
#include "shl_log.h"
#include "shl_misc.h"
-#include "static_gl.h"
#include "text.h"
#include "uterm_video.h"
#include <xf86drm.h>
#include <xf86drmMode.h>
#include "eloop.h"
+#include "shl_gl.h"
#include "shl_log.h"
-#include "static_gl.h"
#include "uterm_drm_shared_internal.h"
#include "uterm_drm3d_internal.h"
#include "uterm_video.h"
#include "eloop.h"
#include "shl_log.h"
#include "shl_misc.h"
-#include "static_gl.h"
#include "uterm_drm_shared_internal.h"
#include "uterm_drm3d_internal.h"
#include "uterm_video.h"