mutter/clutter/cogl
Robert Bragg 33400c0aae [cogl] Improve ability to break out into raw OpenGL via begin/end mechanism
Although we wouldn't recommend developers try and interleve OpenGL drawing
with Cogl drawing - we would prefer patches that improve Cogl to avoid this
if possible - we are providing a simple mechanism that will at least give
developers a fighting chance if they find it necissary.

Note: we aren't helping developers change OpenGL state to modify the
behaviour of Cogl drawing functions - it's unlikley that can ever be
reliably supported - but if they are trying to do something like:

   - setup some OpenGL state.
   - draw using OpenGL (e.g. glDrawArrays() )
   - reset modified OpenGL state.
   - continue using Cogl to draw

They should surround their blocks of raw OpenGL with cogl_begin_gl() and
cogl_end_gl():

   cogl_begin_gl ();
   - setup some OpenGL state.
   - draw using OpenGL (e.g. glDrawArrays() )
   - reset modified OpenGL state.
   cogl_end_gl ();
   - continue using Cogl to draw

Again; we aren't supporting code like this:
   - setup some OpenGL state.
   - use Cogl to draw
   - reset modified OpenGL state.
When the internals of Cogl evolves, this is very liable to break.

cogl_begin_gl() will flush all internally batched Cogl primitives, and emit
all internal Cogl state to OpenGL as if it were going to draw something
itself.

The result is that the OpenGL modelview matrix will be setup; the state
corresponding to the current source material will be setup and other world
state such as backface culling, depth and fogging enabledness will be also
be sent to OpenGL.

Note: no special material state is flushed, so if developers want Cogl to setup
a simplified material state it is the their responsibility to set a simple
source material before calling cogl_begin_gl. E.g. by calling
cogl_set_source_color4ub().

Note: It is the developers responsibility to restore any OpenGL state that they
modify to how it was after calling cogl_begin_gl() if they don't do this then
the result of further Cogl calls is undefined.
2009-06-30 17:13:38 +01:00
..
common [cogl] Improve ability to break out into raw OpenGL via begin/end mechanism 2009-06-30 17:13:38 +01:00
gl [cogl] Improve ability to break out into raw OpenGL via begin/end mechanism 2009-06-30 17:13:38 +01:00
gles [cogl material] optimize logging of material colors in the journal 2009-06-30 17:13:35 +01:00
cogl-bitmap.h [docs] Various gtk-doc fixes for COGL 2009-06-10 12:57:36 +01:00
cogl-color.h [cogl-color] Adds a cogl_color_equal() function 2009-06-30 17:13:35 +01:00
cogl-debug.h [cogl journal] Perform software modelview transform on logged quads. 2009-06-30 17:13:36 +01:00
cogl-deprecated.h [cogl deprecated] Add backface culling deprecation 2009-05-28 14:14:50 +01:00
cogl-fixed.h [cogl] Updates all file headers and removes lots of trailing white space 2009-05-02 04:12:25 +01:00
cogl-material.h [cogl] Improving Cogl journal to minimize driver overheads + GPU state changes 2009-06-30 17:13:34 +01:00
cogl-matrix.h [docs] Various gtk-doc fixes for COGL 2009-06-10 12:57:36 +01:00
cogl-offscreen.h [docs] Various gtk-doc fixes for COGL 2009-06-10 12:57:36 +01:00
cogl-path.h [cogl] Updates all file headers and removes lots of trailing white space 2009-05-02 04:12:25 +01:00
cogl-shader.h [cogl-shader] Make get_info_log() slightly nicer 2009-06-01 17:40:23 +01:00
cogl-texture.h [cogl-texture docs] Improves the documentation of the internal_format args 2009-06-11 14:31:01 +01:00
cogl-types.h [cogl] Move the texture filters to be a property of the material layer 2009-06-04 19:03:40 +01:00
cogl-vertex-buffer.h [vertex-buffer] Add cogl_vertex_buffer_indices_get_type API 2009-06-29 23:49:05 +01:00
cogl.h.in [cogl] Improve ability to break out into raw OpenGL via begin/end mechanism 2009-06-30 17:13:38 +01:00
cogl.pc.in [cogl] Fix hardcoded paths in the pc file 2009-03-10 12:38:04 +00:00
Makefile.am [introspection] Add --c-include to g-ir-scanner 2009-06-09 12:45:23 +01:00
TODO Merged clutter-ivan branch into trunk. 2008-04-25 13:37:36 +00:00