summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)AuthorFilesLines
2012-05-17include: Rename waffle_dlsym_gl -> waffle_dl_symChad Versace5-10/+52
Rename waffle_dlsym_gl to waffle_dl_sym, and place it into a new module waffle_dl. A future commit will add a new function to this module: waffle_dl_can_open. Rename all analogous internal functions PLATFORM_dlsym_gl to PLATFORM_dl_sym, and place it into a new module PLATFORM_dl. I'm trying to maintain a consistent naming scheme where functions are prefixed according to module and where the public api closely matches the internal api, at least until the public api freezes at 1.0. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17include: Add param 'dl' to waffle_dlsym_glChad Versace1-1/+8
The 'dl' param selects which GL library on which to call dlsym. This is a prerequisite for allowing the creation multiple contexts with different GL API's simultaneously. To achieve that goal, we must eliminate the WAFFLE_GL_API attribute from waffle_init. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17include: Add enums for dynamic librariesChad Versace1-0/+8
Add the following enums: WAFFLE_DL_OPENGL WAFFLE_DL_OPENGL_ES1 WAFFLE_DL_OPENGL_ES2 A future commit will unbind waffle_dlsym_gl from the API given to waffle_init. Then, these enums will be passed to waffle_dlsym_gl to speciy the GL library. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17include: Rename waffle_get_error -> waffle_error_get_code()Chad Versace1-1/+1
This makes the name consistent with other functions in the waffle_error module. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17api,include: Simplify the getting of error messagesChad Versace1-17/+10
Change the signature of waffle_get_error_m to simply return a `const char*` that points to the error message. Before this patch, the function required a string buffer argument and had tricky calling conventions. While we're touching the function, rename it to waffle_error_get_info. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17include, api: Reset error state at each when api entry pointChad Versace2-6/+19
Of course, we don't reset the error state at api entry points that *retrieve* the error state. Update the doxygen in waffle_error.h to reflect this change. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-17Ensure each file ends with a newlineChad Versace5-5/+5
This whitespace inconsitency was causing spurious merge conflicts. This patch was created with for f in $(find $WAFFLE_TOP -type f | grep -E "\.(c|h|txt)$") do if ! diff <(tail -c1 "$f") <(echo) >&/dev/null then echo >> "$f" fi done Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11doxygen: Place everything into a moduleChad Versace11-3/+82
To ensure this, each file is enclosed in one of two blocks: @defgroup or @addtogroup. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11core: Convert wcore_error to use thread-local storageChad Versace1-1/+1
Now, all functions in the wcore_error use thread-local storage. In public doxygen, document that waffle_get_error() now returns the error code of the most recent failure of *the current thread*. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11include: Add new error codesChad Versace1-0/+8
WAFFLE_UNSUPPORTED_ON_PLATFORM This error is for requested actions that are unsupported on the current platform. WAFFLE_NOT_IMPLEMENTED The error is for features whoe implementation is not yet complete. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11include: Improve doxygen for waffle_init()Chad Versace1-49/+72
* Describe attributes in a table. * Fix incorrect Doxygen syntax. Doxygen interprets indented blocks as code, and waffle_init() had all paragraphs wrongly indented. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11include: Improve doxygen for waffle_config_chooseChad Versace1-2/+46
* Describe attributes in a table. * Give a code example. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11include: Rename WAFFLE_LIST_END -> WAFFLE_NONEChad Versace1-1/+1
This name is more consistent with GLX and EGL, where the enum name is None and EGL_NONE, respectively. Also, switch positions of WAFFLE_NONE(0) and WAFFLE_DONT_CARE(-1), because -1 < 0. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-11include: Remove @defgroup directives from waffle_enum's doxygenChad Versace1-11/+10
The @defgroup directives never worked here. Future commits will document these enums in the doxygen for the function that uses them. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-10include: Change value WAFFLE_DONT_CARE to -1Chad Versace1-2/+2
This matches the value of EGL_DONT_CARE and GLX_DONT_CARE. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-09waffle: Change some default values to WAFFLE_DONT_CAREChad Versace1-2/+3
Change the default value of WAFFE_{RED,GREEN,BLUE,ALPHA}_SIZE to WAFFLE_DONT_CARE. The egl module translates WAFFLE_DONT_CARE to EGL_DONT_CARE. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-09include: Add enum WAFFLE_DONT_CAREChad Versace1-0/+1
Nothing uses the enum yet. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08waffle: Rename WAFFLE_GL* -> WAFFLE_OPENGL*Chad Versace2-8/+8
WAFFLE_GL_API -> WAFFLE_OPENGL_API WAFFLE_GL -> WAFFLE_OPENGL WAFFLE_GLES1 -> WAFFLE_OPENGL_ES1 WAFFLE_GLES2 -> WAFFLE_OPENGL_ES2 Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08waffle: Remove default values for platform and gl_apiChad Versace1-1/+7
The default values were chosen during CMake configuration time. This was a recipe for disaster. libwaffle built by different people would have significant behavioral differences. - Remove the CMake options waffle_default_{platform,gl_api}. - Remove the macros WAFFLE_{PLATFORM,GL_API}_DEFAULT. - Require the user provide attributes WAFFLE_{PLATFORM,GL_API} to waffle_init(). Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08cmake: Install libwaffle.so and headersChad Versace1-0/+12
Install libwaffle.so to ${waffle_install_libdir}. Install headers to ${waffle_install_includedir}/waffle. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08waffle: Change signature of waffle_make_currentChad Versace1-0/+2
Add a `display` parameter to waffle_make_current in order to allow users to release the current context. To release the current context, the user calls it like this: waffle_make_current(dpy, window=0, ctx=0). Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08api: Add unit tests for waffle_attrib_listChad Versace1-0/+5
All tests pass. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-04-08include: Add public api headersChad Versace11-0/+620
The API is mostly complete. As far as my future-looking eye can tell, it only lacks: - a way to choose the GL version and profile - a way to handle key and mouse input The API likely lacks much more. My future-looking eye is quite blind. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>