2 * the main local module header
11 #define debug_instruction_buffer 0
12 #define debug_clean_instruction_buffer 0
13 #define verbose_missing_output 0
14 #define dynamic_debug 0
15 #define check_integrity_on_draw 0
17 #define debug_track_fonts 0
18 #define debug_track_special_font 1 /* child of the above, won't work if the above is 0 */
19 #define debug_track_special_font_x 6 /* ditto */
20 #define debug_track_special_font_y 6 /* above above ditto */
22 #define screen_buffer 1
23 #define second_screen_buffer 0
24 #define retain_image_inipos 0
26 #define use_memory_pool 0
36 TDRAW_SDRAWN
, /* static but already drawn */
37 TDRAW_SREDRAW
, /* flag to make a static element redrawn */
38 TDRAW_VOLATILE
, /* a draw that gets deleted after being drawn (override replacement) */
39 TDRAW_SDESTROY
, /* the flag to destroy a static element */
44 typedef struct RAW_ENGINE RAW_ENGINE
;
48 u32 layer
; /* the drawing level that the surface is drawn */
49 u8 type
; /* see the drawings_type enumeration */
50 Rectan src
; /* size of the image */
51 u16 dx
, dy
; /* destination coordinates */
53 void *surface_ptr
; /* points to the image held by the external application */
56 /* typedef struct INSTRUCTION_ENGINE INSTRUCTION_ENGINE; */
59 * this structure is the core of the linked list
60 * drawing priority algorithm. The layer for each
61 * added entries is the only dependency to change
62 * the drawing position of an entry.
64 struct INSTRUCTION_ENGINE
67 INSTRUCTION_ENGINE
*next
;
70 typedef struct DRAWING_ELEMENTS
72 void (*callback
)(void);
75 typedef struct debug_status
81 /* inside graphics.c */
82 extern u8
Graphics_DrawIsPresent(v_elem
*elem
);
84 extern u8
Graphics_GetSafeDrawOp();
86 extern void Graphics_SetSafeDrawOp(u8 safe
);
88 extern void Graphics_ResetScreenDraw();
90 extern void Graphics_SetDrawnLastCycle();
92 extern void Graphics_RedrawScreen();
94 /* inside painter.c */
95 extern int Graphics_PainterInit();
96 extern int Graphics_PainterReset();
97 extern void Graphics_PainterClean();
99 extern EBUF
*Graphics_GetRawBuffer();
100 extern EBUF
*Graphics_GetQueueBuffer();
102 extern void Graphics_CoreDrawAll();
103 extern void graphics_CoreCleanAll();
105 extern INSTRUCTION_ENGINE
*Graphics_GetFirstElem();
106 extern void Graphics_SetFirstElem(INSTRUCTION_ENGINE
*elem
);
108 extern INSTRUCTION_ENGINE
*Graphics_GetLastElem();
109 extern void Graphics_SetLastElem(INSTRUCTION_ENGINE
*elem
);
111 extern INSTRUCTION_ENGINE
*Graphics_AddDrawingInstruction(u32 layer
, u8 type
, Rectan
*isrc
, Rectan
*idst
, void *isurface
);
113 extern INSTRUCTION_ENGINE
*Graphics_PushRaw(RAW_ENGINE
*raw
);
116 /* inside coredraw.c */
117 extern int Graphics_RedrawSection(INSTRUCTION_ENGINE
*indep
);
119 extern void Graphics_CoreDrawAll(); /* new for draw_objects */
121 extern void Graphics_CoreCleanAll();
123 extern void Graphics_CoreCleanDoneDynamics(); /* new for clean_drawn_objects */
125 extern void Graphics_SetAllToRedraw();
127 extern void Graphics_DestroyElement(INSTRUCTION_ENGINE
*elem
);
129 extern void Graphics_FreeVObject(v_object
*source
);
133 extern void Graphics_DebugPrintQueue(); /* new for print_queue */
135 extern void Graphics_DebugBufferQueue(EBUF
*src
); /* new for buffer_queue */
137 extern void Graphics_DebugPrintMissing(EBUF
*src
); /* new for print_missing */
139 extern void Graphics_DebugQueueIntegrityCheck(); /* new for Queue_Integrity_Check */
142 /* inside pixels.c *obsolete* don't use just yet */
143 extern void Graphics_PutPixel(v_object
*vobj
, u32 x
, u32 y
, u32 pixel
);
145 extern u32
Graphics_GetPixel(v_object
*vobj
, u32 x
, u32 y
);
147 extern void Graphics_CleanPixels();
149 extern int Pixels_Init();
151 extern void Pixels_Clean();
153 extern void Pixels_Poll();
161 #endif /* NOT __VIDEO_H */