I followed the dri2 discussion on dri-devel (http://www.mail-archive.com/dri-devel@lists.sourceforge.net/msg35990.html), current dri2 implementation depends on glViewport being called whenever the window/framebuffer is resized, otherwise renderbuffer can't be updated. In i915 dri driver, we first set functions->Viewport to intel_viewport, then this function pointer is overrided by intelViewport, who calls intelCalcViewport and doesn't update renderbuffer.
With this patch, we can resize glxgears as normal. This patch also fix a metacity-clutter/DRI2 issue, that we only have 640x480 preallocated renderbuffer at metacity-clutter start and then the buffers can't be updated anymore. Please review and your comments are welcome. Thanks Peng diff --git a/src/mesa/drivers/dri/i915/intel_state.c b/src/mesa/drivers/dri/i915/intel_state.c index 09aa62d..c99bb16 100644 --- a/src/mesa/drivers/dri/i915/intel_state.c +++ b/src/mesa/drivers/dri/i915/intel_state.c @@ -289,7 +289,6 @@ void intelInitStateFuncs(struct dd_function_table *functions) { functions->RenderMode = intelRenderMode; - functions->Viewport = intelViewport; functions->DepthRange = intelDepthRange; functions->ClearColor = intelClearColor; } ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ -- _______________________________________________ Dri-devel mailing list Dri-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dri-devel