aboutsummaryrefslogtreecommitdiff
path: root/generic/tkZinc.c
diff options
context:
space:
mode:
authorlemort2008-01-22 08:33:42 +0000
committerlemort2008-01-22 08:33:42 +0000
commit0e652cdcfd509fdde56afa2ad7b24dafd50af154 (patch)
tree74ffdef663758c9b883d11ea6041ef21948b7037 /generic/tkZinc.c
parentec349c8062d22e28142346efd1e08dd5fe71a85c (diff)
downloadtkzinc-0e652cdcfd509fdde56afa2ad7b24dafd50af154.zip
tkzinc-0e652cdcfd509fdde56afa2ad7b24dafd50af154.tar.gz
tkzinc-0e652cdcfd509fdde56afa2ad7b24dafd50af154.tar.bz2
tkzinc-0e652cdcfd509fdde56afa2ad7b24dafd50af154.tar.xz
Ajout de l'item viewport qui permet de deleguer le rendu dans une zone rectangulaire a une librairie externe. Pour l'instant, seule l'implementation Windows fonctionne: le rendu est deleguea une DLL qui doit contenir certaines fonctions
Diffstat (limited to 'generic/tkZinc.c')
-rw-r--r--generic/tkZinc.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/generic/tkZinc.c b/generic/tkZinc.c
index d6e5215..5c577e7 100644
--- a/generic/tkZinc.c
+++ b/generic/tkZinc.c
@@ -1533,6 +1533,12 @@ ZincObjCmd(ClientData client_data, /* Main window associated with
wi->damaged_area_w = wi->damaged_area_h = 0;
/*
+ * Viewport item management init
+ */
+ wi->nb_of_viewport_items = 0;
+
+
+ /*
* Text management init.
*/
wi->text_info.sel_color = NULL;
@@ -8805,6 +8811,13 @@ Repair(ZnWInfo *wi)
//printf("Repair, scissors: %d\n", ISCLEAR(wi->flags, ZN_CONFIGURE_EVENT));
ce = ZnGLMakeCurrent(wi->dpy, wi);
+
+ // PRE-RENDERING Method. Called for non directAccess viewports and other special effects
+ // ONLY IF WE HAVE AT LEAST ONE VIEWPORT
+ if (wi->nb_of_viewport_items > 0) {
+ wi->top_group->class->PreRender(wi->top_group);
+ }
+
glDrawBuffer(GL_BACK);
#if defined(GL) && defined(ROTATION)