1 /***********************************************************************
5 File OpenGl_togl_update :
12 HISTORIQUE DES MODIFICATIONS :
13 --------------------------------
14 xx-xx-xx : xxx ; Creation.
15 20-02-96 : FMN ; Suppression code inutile:
16 01-04-96 : CAL ; Integration MINSK portage WNT
17 05-02-97 : FMN ; Suppression de OpenGl_tgl_vis.h
18 07-10-97 : FMN ; Simplification WNT
19 08-08-98 : FMN ; ajout PRINT debug
20 18-11-98 : CAL ; S4062. Ajout des layers.
22 ************************************************************************/
24 #define RIC120302 /* GG Avoid duplicate code with
28 /*----------------------------------------------------------------------*/
33 #include <OpenGl_tgl_all.hxx>
34 #include <InterfaceGraphic_Graphic3d.hxx>
35 #include <InterfaceGraphic_Visual3d.hxx>
36 #include <OpenGl_tgl_funcs.hxx>
37 #include <OpenGl_tsm_ws.hxx>
39 #include <OpenGl_tgl.hxx>
40 #include <OpenGl_txgl.hxx>
41 #include <OpenGl_tgl_tox.hxx>
42 #include <OpenGl_tgl_funcs.hxx>
45 void EXPORT call_togl_update
47 CALL_DEF_VIEW * aview,
48 CALL_DEF_LAYER * anunderlayer,
49 CALL_DEF_LAYER * anoverlayer
55 Tint swap = 1; /* swap buffers ? yes */
58 TsmGetWSAttri (aview->WsId, WSUpdateState, &data);
59 update_state = data.ldata;
61 * Si l'update_state est NotDone, alors on retrace
63 if (update_state == TNotDone) {
65 call_togl_redraw( aview, anunderlayer, anoverlayer );
67 TsmGetWSAttri (aview->WsId, WSWindow, &data);
68 if (TxglWinset (call_thedisplay, (Window) data.ldata) == TSuccess) {
69 call_func_redraw_all_structs_begin (aview->WsId);
71 call_togl_setplane( aview ); /* update clipping planes */
73 if (anunderlayer->ptrLayer)
74 call_togl_redraw_layer2d (aview, anunderlayer);
75 call_func_redraw_all_structs_proc (aview->WsId);
76 if (anoverlayer->ptrLayer)
77 call_togl_redraw_layer2d (aview, anoverlayer);
78 call_func_redraw_all_structs_end (aview->WsId, swap);
79 call_togl_redraw_immediat_mode (aview);