summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* kms: defer setting crtc modes until first swap buffersfosdem-2012Robert Bragg2012-01-304-45/+103
| | | | | | | | | | | | Instead of creating a dummy framebuffer allocation just so we can setup crtc modes during display_setup we now wait until the first swap_buffers request before setting up the crtc modes. This patch also adds a cogl_kms_display_queue_modes_reset() function that allows developers to explicitly queue a reset of the crtc modes. The idea is that applications that handle VT switching can use this for VT enter events to explicitly ensure their mode is restored since modes are often not automatically restored correctly.
* kms: Add mirror support and env var configurabilityRobert Bragg2012-01-273-83/+397
| | | | | | | | | | | | | | | | | | | | | | This adds support for mirroring the display output on two KMS connectors. This patch also checks for a number of environment variables that can influence how KMS is configured. The following variables can be set: COGL_KMS_MIRROR: If this is set to anything then Cogl will try and setup two connectors with the same resolution so that onscreen frame buffers can be mirrored. COGL_KMS_CONNECTOR0: This can be set to an integer identifier for a specific KMS connector id to use for the first output. COGL_KMS_CONNECTOR0_MODE: Can be set to a mode name like "1024x768" explicitly select what mode should be used for the first output. If COGL_KMS_MIRROR is set then COGL_KMS_CONNECTOR1 and COGL_KMS_CONNECTOR1_MODE can optionally be set to specify a connector id and mode name for the second output.
* kms: gracefully handle NULL save_state at cleanupRobert Bragg2012-01-231-11/+14
| | | | | If we failed to save any crtc state then we skip trying to restore the old state at cleanup.
* kms: Adds api to get at the drm file descriptorRobert Bragg2012-01-234-0/+71
| | | | | | This adds a cogl_kms_renderer_get_drm_fd() function that lets developers access the drm file descriptor being used for controlling the kernel mode setting.
* renderer: fix s/contraint/constraint/ typoRobert Bragg2012-01-172-4/+4
| | | | | The recent patch to add an api for explicitly constraining how a renderer backend is chosen had a typo which this patch fixes.
* texture-2d/wayland: destroy transient EGLImagesRobert Bragg2012-01-171-6/+9
| | | | | | | | When creating a texture from a wayland buffer we create an intermediate EGLImage that we then create a GL texture from, but we were never destroying that EGLImage. This patch ensures we destroy the image right after we've created the texture so we don't leak a reference to the underlying buffer.
* stash: assume RGB buffers for wayland buffersRobert Bragg2012-01-171-1/+1
| | | | | | until we have a mechanism to determine if a buffer has an alpha component we consider all buffers to be RGB otherwise RGBX buffers with a junk X component can cause blending artefacts.
* kms: Implement the swap buffers notify featureNeil Roberts2012-01-171-10/+89
| | | | | | | | The KMS EGL platform now notifies when a swap is complete. The notification is delayed until the application calls cogl_context_dispatch. The GLX backend doesn't currently do this but I think that is how it should behave to make it easier for the application to handle locks and such.
* Move the add_swap_buffers_callback functions out of the winsysNeil Roberts2012-01-174-83/+50
| | | | | | | | | | Instead of having each winsys implement its own list of callbacks the list is now just attached directly to the CoglOnscreen using code in cogl-onscreen.c. The winsys's can invoke this list of callbacks by calling _cogl_onscreen_notify_swap_buffers(). All of the winsys's would probably have a very similar implementation for this anyway and I don't think it makes much sense to try and save the cost of a list pointer in the CoglOnscreen struct.
* egl-kms: Use drmModePageFlipNeil Roberts2012-01-171-16/+110
| | | | | | | | The KMS platform now uses drmModePageFlip to present the buffer. The main loop mechanism is used to poll for events on the DRM file descriptor so that we notice when the page flip is complete. The swap_buffers is throttled so that if there is a pending flip it will block until it is complete before starting another flip.
* kms: Use GBM surfacesNeil Roberts2012-01-173-171/+72
| | | | | | | | Instead of creating FBOs on the GL side, the KMS EGL platform uses the latest changes to Mesa to create an EGL surface using a GBM surface as the native surface type. This removes some of the special vtable hooks that the KMS platform needed because it is now much more similar to the other platforms.
* Makefile.am.release: Include NEWS in release messageRobert Bragg2012-01-171-1/+11
| | | | | | | | | | | | This updates the make release-message rule to include the latest NEWS section at the top of the release message. The release messages currently contain a lot of boring boilerplate that I imagine very few people are really be interested in. For someone idly following Cogl development though it's quite possible they'd like to see a digestible summary of what has changed in this release which is what the NEWS section provides. Reviewed-by: Neil Roberts <neil@linux.intel.com>
* Bump development version to 1.9.5Robert Bragg2012-01-171-2/+2
|
* Release 1.9.4 (snapshot)1.9.4Robert Bragg2012-01-161-3/+3
|
* Updates NEWS for the 1.9.4 releaseRobert Bragg2012-01-161-0/+82
|
* configure: Updates listed glib dependency to 2.28Robert Bragg2012-01-161-1/+1
| | | | | Cogl depends on glib 2.28 for g_source_get_time() so this updates the glib dependency listed in configure.ac
* mingw: update glib dependency to 2.28Robert Bragg2012-01-161-1/+1
| | | | | | Cogl depends on glib 2.28 for g_source_get_time() so this patch updates the mingw-fetch-dependencies.sh helper script to fetch the 2.28.8-1 win32 glib binaries.
* docs: Updates cogl_primitive_new_xyz symbols listingRobert Bragg2012-01-161-8/+9
| | | | | | | | | Previously we had functions named like cogl_primitive_new_with_xyz_attributes() but at some point we renamed them all to functions named like cogl_primitive_new_xyz() instead. This updates the -sections.txt symbol listing to list the new names. Reviewed-by: Neil Roberts <neil@linux.intel.com>
* profile: use atexit not g_atexitRobert Bragg2012-01-161-1/+1
| | | | | | g_atexit has been deprecated so we simply use atexit instead now. Reviewed-by: Neil Roberts <neil@linux.intel.com>
* wayland: perform buffer resizes lazily at swap buffersRobert Bragg2012-01-162-8/+70
| | | | | | | | | | | | Resizing a wayland client framebuffer should not affect the viewport of additional primitives drawn to that framebuffer before the next swap buffers request nor should querying the framebuffer's width and height be affected until the next swap buffers request completes. This patch changes cogl_wayland_onscreen_resize() so it only saves the new geometry as "pending" state internal to the given CoglOnscreen. Only when cogl_framebuffer_swap_buffers() is next called will the pending size be flushed to the wayland egl api.
* Swaps a few uses of gint for intRobert Bragg2012-01-162-8/+8
| | | | | | We've avoiding using the redundant glib typedefs such as guint, gint gpointer etc and prefer to use the equivalent C types so this patch removes a few uses of gint that slipped past review.
* template: Allow configuration of swap throttleRobert Bragg2012-01-167-12/+38
| | | | | | | | | | This adds cogl_onscreen_template_set_swap_throttled() api that allows developers to specify their preference for swap buffer throttling up-front as part of the onscreen template that is used to create a CoglDisplay when initializing Cogl. This is desirable because some platforms may not support configuring swap throttling on a per framebuffer basis and also since applications often want to apply the same policy to all onscreen framebuffers anyway.
* matrix: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-12/+9
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the matrix api symbols.
* snippets: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-11/+0
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the snippet api symbols.
* framebuffer: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-61/+161
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the cogl framebuffer symbols.
* cogl.h: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-4/+0
| | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the cogl.h symbols.
* onscreen: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-16/+106
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the onscreen framebuffer api symbols.
* renderer: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-163-76/+21
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the cogl-pipeline symbols.
* Remove CoglVector3 type and use float * insteadRobert Bragg2012-01-165-214/+183
| | | | | | | | It proved to be inconvenient that we had a special CoglVector3 typedef for vectors instead of just accepting pointers to float arrays because you'd so often end up having to make awkward casts from another vector type into a CoglVector3 and then cast back again. We're hoping that taking float pointers instead will lead to less unnecessary casting.
* renderer: Remove _EXP symbol mangling and add gtk-docRobert Bragg2012-01-161-11/+111
| | | | | | | | We are in the process of removing all _EXP suffix mangling for experimental APIs (Ref: c6528c4b6c3c34) and adding missing gtk-doc comments so that we can instead rely on the "Stability: unstable" markers in the gtk-doc comments. This patch tackles the symbols in cogl-renderer.h.
* renderer: Adds api to add/remove selection constraintsRobert Bragg2012-01-168-23/+109
| | | | | | | This allows applications to specify certain constraints that feed into the process of selecting a CoglRenderer backend. For example applications might depend on x11 for handling input and so they require a backend that's also based on x11.
* cogl-info: print out the chosen renderer nameRobert Bragg2012-01-161-10/+51
| | | | | This updates cogl-info to use cogl_renderer_get_winsys_id() so it can print out the name of the chosen renderer winsys.
* Updates in line with latest wayland protocolRobert Bragg2012-01-162-15/+7
| | | | | | The shm buffer format enum values were renamed and the explicitly premultiplied format was dropped since it's now assumed if the buffer has an alpha component then it's premultiplied.
* Updated Galician translationsFran Diéguez2012-01-151-92/+59
|
* Updated Galician translationsFran Diéguez2012-01-151-3/+41
|
* Updated Lithuanian translationAurimas Černius2012-01-131-6/+319
|
* docs: Add list of api introduced in 1.8 versionJavier Jardón2012-01-131-0/+5
|
* wayland: Add a cogl_wayland_onscreen_resize functionRob Bradford2012-01-132-0/+31
| | | | | | | | This function will call into the Wayland EGL platform API and resize the surface that the window is using and update the internal dimensions for framebuffer and viewport to reflect the change. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* cogl-crate: Optionally use the swap buffers notify mechanismNeil Roberts2012-01-091-3/+39
| | | | | | | | | If the swap buffers notify mechanism is advertised then the crate example will now register a callback for it and call g_poll with the proper timeout from cogl_context_begin_idle instead of trying to repaint continuously. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* Add a feature ID for the swap event notificationNeil Roberts2012-01-092-1/+9
| | | | | | | | | Previously the swap event notification feature was only accessible as a winsys feature using the semi-internal cogl_clutter_winsys_has_feature. This just adds a feature ID for it so it can also be accessed via cogl_has_feature. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* Update VS property sheetsChun-wei Fan2012-01-062-0/+6
| | | | "Install" the "new" cogl-glib-source.h and cogl-poll.h.
* Start removing _EXP defines and improves some docsRobert Bragg2012-01-054-40/+80
| | | | | | | | | | | | | | | | | | | | | | Originally we decided to use #define tricks to rename all experimental symbols so that they had an _EXP suffix so it would be a bit clearer for those wanting to check for ABI changes that they shouldn't worry about these experimental symbols. We feel now though that the defines are a bit more hassle than they are really worth, since they are one extra thing to remember when coding, they make using gdb slightly more awkward since you have to use the real symbol name to set breakpoints and we already have a mechanism for declaring symbols as experimental via gtk-doc that can be used by anyone wanting to check for ABI changes. Instead of just using a script to remove all the #defines we are going to go through them manually because we need to make sure the symbols are marked as unstable via gtk-doc. This patch does a first batch of define removals and in fact some of the symbols didn't have any documentation at all so that needed to be added too. Reviewed-by: Neil Roberts <neil@linux.intel.com>
* sub-texture: Exposes a getter for parent textureRobert Bragg2012-01-052-0/+22
| | | | | | | This adds a cogl_sub_texture_get_parent getter for the parent of a CoglSubTexture. Reviewed-by: Neil Roberts <neil@linux.intel.com>
* Remove old fallback for vblank wait via manual drm ioctlRobert Bragg2012-01-051-50/+0
| | | | | | | | | | | | | | | | This workaround code has just been incrementally carried forward since Cogl was integrated with Clutter but really we have no idea when this code path was ever tested. Since the work around is from before the time of the current Cogl developers we don't know anything about the circumstances which led to this extreme workaround instead of pushing to fix a driver. It seems pretty likely we can push to fix any drm based drivers so we're removing the workaround. https://bugzilla.gnome.org/show_bug.cgi?id=667009 Reviewed-by: Neil Roberts <neil@linux.intel.com>
* build: Fix building clutter on armv4t devicesJoshua Lock2012-01-051-1/+1
| | | | | | | | | | | | GCC will define __ARM_ARCH_4T__ when building with "-march=armv4t" so we can check this to turn off the use of 'clz' instructions, which otherwise would cause compile errors like "selected processor does not support ARM mode `clz r3,r0'". Signed-off-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Joshua Lock <josh@linux.intel.com> Reviewed-by: Robert Bragg <robert@linux.intel.com> Reviewed-by: Emmanuele Bassi <ebassi@linux.intel.com>
* Update all of the examples to use cogl_poll_get_infoNeil Roberts2012-01-056-28/+139
| | | | | | | | | | | | | | | | | | The aim is that it should be a requirement that all Cogl applications hook their mainloops into Cogl so we should lead by examples. Most of the examples now just call cogl_poll_get_info and then g_poll with a zero timeout so that they can continue to constantly redraw. The SDL example is a bit special because SDL makes it very difficult to wait on either a timeout or any file descriptors. The SDL winsys is documented not to require blocking on any file descriptors so we can ignore that. It implements the timeout by adding an SDL timer which pushes an event to the queue to wake up SDL_GetEvent. The Cogland example was already using the glib main loop so that one has been updated to add the CoglGLibSource to it. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* Add a utility to make a GSource out of a CoglContextNeil Roberts2012-01-055-0/+264
| | | | | | | | | | | | | The GSource is created using cogl_glib_source_new which takes a pointer to a CoglContext. The source calls cogl_poll_get_info() in its prepare function and cogl_poll_dispatch() in its dispatch function. The poll FDs on the source are updated according to what Cogl reports. The header is only included and the source only compiled if Cogl is configured with GLib support. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* xlib: Internally retrieve XEventsNeil Roberts2012-01-057-0/+156
| | | | | | | | | | | | | | | | | Previously we relied on the application to send all X events through Cogl using cogl_xlib_renderer_handle_event. This breaks the abstraction that an application shouldn't need to know what winsys Cogl is using. Now that we have main loop integreation in Cogl, the Xlib-based winsys's can report that Cogl needs to block on the file descriptor of the X connection and it can manually handle the events. The event retrieval can be disabled by an application if it calls the new cogl_xlib_renderer_set_event_retrieval_enabled() function. The event retrieval will also automatically be disabled if the application sets a foreign display. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* Add support for main loop integrationNeil Roberts2012-01-058-1/+305
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds two new functions: void cogl_poll_get_info (CoglContext *context, CoglPollFD **poll_fds, int *n_poll_fds, gint64 *timeout); void cogl_poll_dispatch (CoglContext *context, const CoglPollFD *poll_fds, int n_poll_fds); The application is expected to call the first function whenever it is about to block to go idle, and the second function whenever it comes out of idle. This gives Cogl winsys's the ability poll file descriptors for events. For example when handing swap complete notifications, it can report that it needs to block on a file descriptor. The two functions are backed by winsys virtual functions. There are currently no implementations. The default handler for get_info just reports no file descriptors and an infinite timeout. Reviewed-by: Robert Bragg <robert@linux.intel.com>
* Add the missing cogl_is_context() functionNeil Roberts2012-01-052-0/+16
| | | | | | This was missing from the CoglContext header. Reviewed-by: Robert Bragg <robert@linux.intel.com>