summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* renderer: split win32 api out into separate headerwip/example-crateRobert Bragg2011-06-283-62/+100
| | | | | This adds a cogl-win32-renderer.h for the win32 specific cogl-renderer API instead of having #ifdef guards in cogl-renderer.h
* Updates wayland symbol names to be consistentRobert Bragg2011-06-286-36/+76
| | | | | This updates the public wayland symbols to follow the pattern cogl_wayland_blah instead of cogl_blah_wayland.
* work towards consistent platform file/symbol nameingRobert Bragg2011-06-2816-241/+277
| | | | | | | | | | | we've got into a bit of a mess with how we name platform specific symbols and files, so this is a first pass at trying to tidy that up. All platform specific symbols should be named like cogl_<platform>_symbol_name and similarly files should be named like cogl-<platform>-filename.c This patch tackles the X11 specific renderer/display APIs as a start.
* replace public native_event APIs with typesafe APIsRobert Bragg2011-06-2814-88/+242
| | | | | | | This adds Xlib and Win32 typesafe replacements for cogl_renderer_handle_native_event, cogl_renderer_add_native_filter, cogl_renderer_remove_native_filter. The old functions are kept as an implementation detail so we can share code.
* attribute: some some sentinal array left over logicRobert Bragg2011-06-281-5/+3
| | | | | | | | | It used to be that we passed around NULL terminated arrays of attributes, but since 3c1e83c7f we now explicitly pass an n_attributes count instead. There were some leftovers of the old approach in the cogl_vdraw_[indexed]_attributes functions and also there was an off-by-one error with the n_attributes values passed on which was causing crashes.
* pipeline: Avoid reseting texture target for NULL texturesRobert Bragg2011-06-271-6/+10
| | | | | | | | | When setting a NULL texture on a CoglPipeline we would also reset the texture target to a dummy value of 0. Reseting the target also had the effect of making fragends discard any associated program. In cases where the NULL texture was only transient until a replacement texture could be set we were re-running lots of redundant codegen and shader compilations.
* pipeline: don't prune user pipelinesRobert Bragg2011-06-272-5/+48
| | | | | | | | | | | | | | | | | | | | | We encourage developers to create template pipelines that we can associated re-usable state such as shaders with, but our logic for pruning redundant ancestry was actually pruning those templates! We now keep track of which pipelines are created for internal purposes (e.g. copy-on-write pipelines created when modifying an immutable pipeline referenced in the journal) and we only ever prune those. We no longer prune user created pipelines. We are careful to consider that pipelines that are initially created explicitly by the user, might eventually become internal only. This is true if the ref_count of a pipeline is equal to the number of children it has, since we know the application no longer owns a reference to the pipeline. In this situation we will allow pruning. NB: The main reason we need to do pruning is to consider cases where the user toggles back and fourth between the same states and we need to avoid creating an endlessly growing chain
* pipeline: fix layer change notify mutex ruleRobert Bragg2011-06-271-94/+65
| | | | | | | | | | | | | | | There is a documented rule that layer changes should only be notified to the fragend once; either as a pipeline change or as a layer change. When the number of layers associated with a material changes then that should get notified against the pipeline. All other layer changes get notified against the layer. There was a mistake in the _cogl_pipeline_add/remove_layer_difference functions, in that we weren't using the 'inc/dec_n_layers' boolean to determine if the fragend should be notified of the change. It was also noticed that the logic of _cogl_pipeline_prune_to_n_layers would also break this rule, by failing to notify some changes at all.
* 2.0 reference: make various fixups in cogl-sections.txtRobert Bragg2011-06-272-40/+20
| | | | | This does some minor gardening in cogl-sections.txt, tweaking some of the section titles and removing some stale api references.
* buffer: Improve the CoglBuffer API descriptionRobert Bragg2011-06-271-3/+16
| | | | This improves the gtk-doc overview for the CoglBuffer interface.
* docs: Adds cogl-index/attribute-buffer syms to 2.0 referenceRobert Bragg2011-06-271-0/+16
|
* docs: fix stale include linksRobert Bragg2011-06-271-2/+2
|
* docs: Fix typo to avoid duplicate section nameRobert Bragg2011-06-271-1/+1
|
* docs: Add swap-chain/onscreen-template to 2.0 referenceRobert Bragg2011-06-271-0/+14
| | | | | This adds the cogl_swap_chain and cogl_onscreen_template symbols to the experimental 2.0 reference manual.
* docs: Adds CoglDisplay symbols to 2.0 referenceRobert Bragg2011-06-271-0/+13
| | | | Adds the cogl_display symbols to the experimental 2.0 reference manual.
* docs: Add CoglRenderer documentation to 2.0 referenceRobert Bragg2011-06-271-0/+22
| | | | | This lists the cogl_renderer symbols in the cogl-sections.txt for the experimental 2.0 reference manual.
* renderer: Expose winsys ID setter/gettersRobert Bragg2011-06-278-3/+92
| | | | | | | | | This adds API to let you override the choice of Cogl's winsys backend. Previously it was only possible to override the winsys using the COGL_RENDERER environment variable, but it's useful for something like Clutter to be able to control the winsys via API without needing environment variable tricks. This also adds API to query back the winsys chosen by Cogl, in case you don't set an explicit override.
* framebuffer: expose viewport getters/settersRobert Bragg2011-06-276-42/+48
| | | | | | | | | | | | | This exposes experimental cogl_framebuffer APIs for getting and setting a viewport without having to refer to the implicit CoglContext. It adds the following experimental API: cogl_framebuffer_set_viewport cogl_framebuffer_get_viewport4fv cogl_framebuffer_get_viewport_x cogl_framebuffer_get_viewport_y cogl_framebuffer_get_viewport_width cogl_framebuffer_get_viewport_height
* Adds another example that draws a 3D crateRobert Bragg2011-06-273-1/+284
| | | | | Based on the Cogl example we had on wiki.clutter-project.org this shows how to use the primitive API to draw a simple spinning crate.
* Add internal _cogl_init() functionRobert Bragg2011-06-278-9/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a _cogl_init function for Cogl that we expect to be the first thing called before anything else is done with Cogl. It's not a public API so it's expected that all entry points for Cogl that might be the first function used should call _cogl_init(). We currently call _cogl_init() in these functions: cogl_renderer_new cogl_display_new cogl_context_new cogl_android_set_native_window _cogl_init() can be called multiple times, and only the first call has any affect. For example _cogl_init() gives us a place check and parse the COGL_DEBUG environment variable. Since we don't have any need to parse command line arguments (we can always get user configuration options from the environment) our init function doesn't require argc/argv pointers. By saying up front that we aren't interested in command line arguments that means we can avoid the mess that is GOption based library initialization which is extremely fragile due to its lack of dependency tracking between modules.
* Typo fix in cogl-framebufferAdam Jackson2011-06-161-1/+1
| | | | | | Signed-off-by: Adam Jackson <ajax@redhat.com> https://bugzilla.gnome.org/show_bug.cgi?id=652672
* examples: pass COGL_DEP_LIBS as ldflags when linkingRobert Bragg2011-06-151-1/+2
| | | | | To be sure our examples link with all the libraries required, we now simply pass the $(COGL_DEP_LIBS) as ldflags when linking them.
* Post-release version bump to 1.7.1Robert Bragg2011-06-141-2/+2
|
* Release 1.7.0 (snapshot)1.7.0Robert Bragg2011-06-141-3/+3
|
* README: Updates in preparation for 1.7.0 releaseRobert Bragg2011-06-141-47/+57
|
* Adds NEWS in preparation for 1.7.0 releaseRobert Bragg2011-06-141-0/+57
|
* configure: pass tar-ustar as automake init optionRobert Bragg2011-06-141-1/+1
| | | | | | | So that our released tarballs can contain filenames longer than 99 characters we tell automake to create tarballs using the ustar format. This is newer than the default v7 format but still old enough to be considered widely portable.
* Ensure we use --enable-profile during make distcheckRobert Bragg2011-06-141-0/+2
|
* doc: Fix EXTRA_DIST variable setupRobert Bragg2011-06-142-14/+6
| | | | | | | | | Since gtk-doc is an optional dependency for Cogl then we need to special case how EXTRA_DIST is initialized. It shouldn't be set when using gtk-doc since gtk-doc.make expects to initialize EXTRA_DIST. If we aren't using gtk-doc then it should be initialized to an empty value instead of including gtk-doc.make so that the later lines that append various extra png files to EXTRA_DIST won't fail.
* Fixes for make distcheckRobert Bragg2011-06-143-3/+5
|
* include required cogl-context.h in cogl-texture-2d.hRobert Bragg2011-06-141-0/+2
|
* Fix some gtk-doc annotations in cogl-depth-state.hRobert Bragg2011-06-141-2/+1
|
* doc: Adds doc/RELEASINGRobert Bragg2011-06-141-0/+86
| | | | This adds some notes for maintainers about how to make a Cogl release.
* profile: Adds a --enable-profile optionRobert Bragg2011-06-143-2/+26
| | | | | | | | | | | | This adds a --enable-profile option which enables uprof based profiling. It was also necessary to fixup a CLUTTER_ENABLE_PROFILING #ifdef in cogl-context.c to renamed COGL_ENABLE_PROFILING instead. By default Cogl doesn't output uprof reports directly, instead it assumes a higher level toolkit will output a report. If you want a report from Cogl you can export COGL_PROFILE_OUTPUT_REPORT=1 before running your app. The latest version of uprof can be fetched from: git://github.com/rib/UProf.git
* x11-foreign: Updates to forward X Events to CoglRobert Bragg2011-06-141-3/+34
| | | | | | This update the x11-foreign test so that it checks for events on its X display and forwards them on to Cogl. It will now also quit if any key of button is pressed.
* Make it clearer that the 2.0 API is experimentalRobert Bragg2011-06-1417-23/+38
| | | | | | | This explicitly renames the cogl-2.0 reference manual to cogl-2.0-experimental and renames the cogl-2.0 pkg-config file to cogl-2.0-experimental.pc. Hopefully this should avoid miss-understandings.
* Adds build/autotools/Makefile.am.changelog/releaseRobert Bragg2011-06-143-0/+242
| | | | This adds some convenience rules to help manage releases
* x11-foreign: explicitly pass -lX11 ldflagRobert Bragg2011-06-141-1/+1
| | | | | | The x11-foreign example directly uses the X11 API at it seems that more recent versions of binutils complain if we don't directly link the test with libX11 as opposed to relying on indirect linkage via cogl.
* Revert "Do not use "near" and "far" variables"Neil Roberts2011-06-141-4/+4
| | | | | | | This reverts commit 3d2564df8f71d6030d9496b7f8e57a27905a4b5a. Since 01e1260aa the 'near' and 'far' defines are now undef'd on Windows so we no longer have to remember not to use them in Cogl code.
* configure: Force #undef of 'near' and 'far' on WindowsNeil Roberts2011-06-143-1/+39
| | | | | | | This adds an extra header that gets included from config.h where we can add configuration defines. This is used to #undef 'near' and 'far' when building for Windows so that we don't have to avoid using them as variable names in the Cogl code.
* cogl-debug: add instrumentation to track the number of objectsLionel Landwerlin2011-06-145-45/+185
| | | | | | | | | | This allows to track the number of objects allocated by Cogl. The results are displayed on the standard output by calling : cogl_debug_print_instances (); Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com> Signed-off-by: Neil Roberts <neil@linux.intel.com>
* cogl-vertex-buffer: make sure to unref weak pipelinesRobert Bragg2011-06-131-0/+3
| | | | | | | | | | | | | | | | When validating a user pipeline before drawing with a CoglVertexBuffer we sometimes find we have to make some overrides and we handle that by creating a pipeline which is a weak copy of the user pipeline. The weak pipeline gets associated with the original pipeline so if that pipeline is used multiple times then we can re-use the same override pipeline and skip validation. Because it's a weak pipeline we get notified when the original material is destroyed or changed so we know our weak pipeline is now invalid. When we get notified that the weak material is invalid we should unref it, but instead we were just discarding our reference to it. This was resulting in leaking weak materials and in some cases those materials referenced textures which would then also be leaked.
* Do not use "near" and "far" variablesEmmanuele Bassi2011-06-131-4/+4
| | | | | | They collide with existing symbols when compiling on Windows. http://bugzilla.clutter-project.org/show_bug.cgi?id=2667
* cogl-texture-pixmap-x11: Fix the can_hardware_repeat wrapperNeil Roberts2011-06-101-1/+1
| | | | | | | The wrapper for the can_hardware_repeat had a cut and paste error so it would call the wrong function on the child texture. Many thanks to Owen Taylor for finding this bug.
* cogl-pango-render: Use the glyph size for unknown glyphsNeil Roberts2011-06-101-11/+10
| | | | | | | | | | | | When rendering a box for an unknown glyph it would previously just use the average glyph size for the font. This causes problems because the size calculations for the layout assume a different size so it can end up rendering outside of the expected ink rectangle. This patch changes it to query the size of the glyph in the font. Pango should end up reporting the size of what would be the hex box which should be the same as the sized used for the extents calculation. http://bugzilla.clutter-project.org/show_bug.cgi?id=2599
* po: Fix up pl.poEmmanuele Bassi2011-06-091-5/+5
|
* Remove G_CONST_RETURNEmmanuele Bassi2011-06-094-4/+4
| | | | | | It is going to be deprecated by GLib, see bug: https://bugzilla.gnome.org/show_bug.cgi?id=644611
* Fix introspection annotations for CoglPangoEmmanuele Bassi2011-06-091-3/+3
|
* Implement COGL_DEBUG=disable-texturing for ARBFp and GLSL fragendsNeil Roberts2011-06-082-9/+25
| | | | | | | | | | The COGL_DEBUG=disable-texturing debug variable disables texturing in the fixed function fragend by not bothering to enable the texture targets. This wasn't working for the programmable fragends because the texture targets don't need to be enabled to use them. This patch modifies the two programmable backends to generate a constant value for the texture lookups in the shader when the debug variable is given.
* gir: pass dep cflags to gobject introspection scannerRobert Bragg2011-06-011-1/+1
| | | | | The gobject introspection scanner was failing to find EGL headers so we now pass the COGL_DEP_CFLAGS to Cogl_1_0_gir_CFLAGS.