19 #ifndef __QD3DDRAWCONTEXT__
20 #define __QD3DDRAWCONTEXT__
43 #include <X11/Xutil.h>
57 #if !defined(QD3D_NO_DIRECTDRAW)
75 #if PRAGMA_STRUCT_ALIGN
76 #pragma options align = power
77 #elif PRAGMA_STRUCT_PACKPUSH
79 #elif PRAGMA_STRUCT_PACK
83 #if PRAGMA_ENUM_ALWAYSINT
84 #if defined(__fourbyteints__) && !__fourbyteints__
85 #define __QD3DDRAWCONTEXT__RESTORE_TWOBYTEINTS
86 #pragma fourbyteints on
88 #pragma enumsalwaysint on
89 #elif PRAGMA_ENUM_OPTIONS
90 #pragma option enum =int
91 #elif PRAGMA_ENUM_PACK
92 #if __option(pack_enums)
93 #define __QD3DDRAWCONTEXT__RESTORE_PACKED_ENUMS
94 #pragma options(!pack_enums)
103 enum TQ3DrawContextClearImageMethod
105 kQ3ClearMethodNone = 0,
106 kQ3ClearMethodWithColor = 1
108 typedef enum TQ3DrawContextClearImageMethod TQ3DrawContextClearImageMethod;
112 TQ3DrawContextClearImageMethod clearImageMethod;
115 TQ3Boolean paneState;
117 TQ3Boolean maskState;
118 TQ3Boolean doubleBufferState;
126 #if CALL_NOT_IN_CARBON
240 TQ3DrawContextClearImageMethod
method);
252 TQ3DrawContextClearImageMethod *
method);
340 #if CALL_NOT_IN_CARBON
384 enum TQ3MacDrawContext2DLibrary
386 kQ3Mac2DLibraryNone = 0,
387 kQ3Mac2DLibraryQuickDraw = 1,
388 kQ3Mac2DLibraryQuickDrawGX = 2
390 typedef enum TQ3MacDrawContext2DLibrary TQ3MacDrawContext2DLibrary;
392 struct TQ3MacDrawContextData
396 TQ3MacDrawContext2DLibrary library;
400 typedef struct TQ3MacDrawContextData TQ3MacDrawContextData;
406 #if CALL_NOT_IN_CARBON
416 Q3MacDrawContext_New(
const TQ3MacDrawContextData *drawContextData);
427 Q3MacDrawContext_SetWindow(TQ3DrawContextObject drawContext,
CWindowPtr window);
438 Q3MacDrawContext_GetWindow(TQ3DrawContextObject drawContext,
450 Q3MacDrawContext_SetGXViewPort(TQ3DrawContextObject drawContext,
451 gxViewPort viewPort);
462 Q3MacDrawContext_GetGXViewPort(TQ3DrawContextObject drawContext,
463 gxViewPort *viewPort);
474 Q3MacDrawContext_SetGrafPort(TQ3DrawContextObject drawContext,
486 Q3MacDrawContext_GetGrafPort(TQ3DrawContextObject drawContext,
498 Q3MacDrawContext_Set2DLibrary(TQ3DrawContextObject drawContext,
499 TQ3MacDrawContext2DLibrary library);
510 Q3MacDrawContext_Get2DLibrary(TQ3DrawContextObject drawContext,
511 TQ3MacDrawContext2DLibrary *library);
523 typedef struct OpaqueTQ3XBufferObject *TQ3XBufferObject;
524 struct TQ3XColormapData
534 typedef struct TQ3XColormapData TQ3XColormapData;
535 struct TQ3XDrawContextData
542 TQ3XColormapData *colorMapData;
544 typedef struct TQ3XDrawContextData TQ3XDrawContextData;
551 #if CALL_NOT_IN_CARBON
561 Q3XDrawContext_New(
void);
572 Q3XDrawContext_Set(TQ3DrawContextObject drawContext,
unsigned long flag,
584 Q3XDrawContext_Get(TQ3DrawContextObject drawContext,
unsigned long flag,
591 #if CALL_NOT_IN_CARBON
601 Q3XBuffers_New(Display *dpy,
unsigned long numBuffers, Window
window);
612 Q3XBuffers_Swap(Display *dpy, TQ3XBufferObject buffers);
623 Q3X_GetVisualInfo(Display *dpy, Screen *screen);
634 Q3XDrawContext_New(
const TQ3XDrawContextData *xContextData);
645 Q3XDrawContext_SetDisplay(TQ3DrawContextObject drawContext,
646 const Display *display);
657 Q3XDrawContext_GetDisplay(TQ3DrawContextObject drawContext, Display **display);
668 Q3XDrawContext_SetDrawable(TQ3DrawContextObject drawContext, Drawable drawable);
679 Q3XDrawContext_GetDrawable(TQ3DrawContextObject drawContext,
691 Q3XDrawContext_SetVisual(TQ3DrawContextObject drawContext,
692 const Visual *visual);
703 Q3XDrawContext_GetVisual(TQ3DrawContextObject drawContext, Visual **visual);
714 Q3XDrawContext_SetColormap(TQ3DrawContextObject drawContext, Colormap colormap);
725 Q3XDrawContext_GetColormap(TQ3DrawContextObject drawContext,
737 Q3XDrawContext_SetColormapData(TQ3DrawContextObject drawContext,
738 const TQ3XColormapData *colormapData);
749 Q3XDrawContext_GetColormapData(TQ3DrawContextObject drawContext,
750 TQ3XColormapData *colormapData);
762 struct TQ3Win32DCDrawContextData
767 typedef struct TQ3Win32DCDrawContextData TQ3Win32DCDrawContextData;
768 #ifndef QD3D_NO_DIRECTDRAW
769 enum TQ3DirectDrawObjectSelector
771 kQ3DirectDrawObject = 1,
772 kQ3DirectDrawObject2 = 2
774 typedef enum TQ3DirectDrawObjectSelector TQ3DirectDrawObjectSelector;
776 enum TQ3DirectDrawSurfaceSelector
778 kQ3DirectDrawSurface = 1,
779 kQ3DirectDrawSurface2 = 2
781 typedef enum TQ3DirectDrawSurfaceSelector TQ3DirectDrawSurfaceSelector;
783 struct TQ3DDSurfaceDescriptor
785 TQ3DirectDrawObjectSelector objectSelector;
788 LPDIRECTDRAW lpDirectDraw;
789 LPDIRECTDRAW2 lpDirectDraw2;
792 TQ3DirectDrawSurfaceSelector surfaceSelector;
795 LPDIRECTDRAWSURFACE lpDirectDrawSurface;
796 LPDIRECTDRAWSURFACE2 lpDirectDrawSurface2;
799 typedef struct TQ3DDSurfaceDescriptor TQ3DDSurfaceDescriptor;
801 struct TQ3DDSurfaceDrawContextData
804 TQ3DDSurfaceDescriptor ddSurfaceDescriptor;
806 typedef struct TQ3DDSurfaceDrawContextData TQ3DDSurfaceDrawContextData;
815 #if CALL_NOT_IN_CARBON
825 Q3Win32DCDrawContext_New(
const TQ3Win32DCDrawContextData *drawContextData);
836 Q3Win32DCDrawContext_SetDC(TQ3DrawContextObject drawContext, HDC newHDC);
847 Q3Win32DCDrawContext_GetDC(TQ3DrawContextObject drawContext, HDC *curHDC);
856 #ifndef QD3D_NO_DIRECTDRAW
857 #if CALL_NOT_IN_CARBON
867 Q3DDSurfaceDrawContext_New(
const TQ3DDSurfaceDrawContextData *drawContextData);
878 Q3DDSurfaceDrawContext_SetDirectDrawSurface(
879 TQ3DrawContextObject drawContext,
880 const TQ3DDSurfaceDescriptor *ddSurfaceDescriptor);
891 Q3DDSurfaceDrawContext_GetDirectDrawSurface(
892 TQ3DrawContextObject drawContext,
893 TQ3DDSurfaceDescriptor *ddSurfaceDescriptor);
901 #if PRAGMA_ENUM_ALWAYSINT
902 #pragma enumsalwaysint reset
903 #ifdef __QD3DDRAWCONTEXT__RESTORE_TWOBYTEINTS
904 #pragma fourbyteints off
906 #elif PRAGMA_ENUM_OPTIONS
907 #pragma option enum =reset
908 #elif defined(__QD3DDRAWCONTEXT__RESTORE_PACKED_ENUMS)
909 #pragma options(pack_enums)
912 #if PRAGMA_STRUCT_ALIGN
913 #pragma options align = reset
914 #elif PRAGMA_STRUCT_PACKPUSH
916 #elif PRAGMA_STRUCT_PACK
920 #ifdef PRAGMA_IMPORT_OFF
QuickDraw GX object and constant definitions.
TQ3Status Q3DrawContext_GetMaskState(TQ3DrawContextObject context, TQ3Boolean *state)
TQ3Status Q3DrawContext_SetPaneState(TQ3DrawContextObject context, TQ3Boolean state)
TQ3Status Q3DrawContext_GetMask(TQ3DrawContextObject context, TQ3Bitmap *mask)
TQ3Status Q3DrawContext_SetDoubleBufferState(TQ3DrawContextObject context, TQ3Boolean state)
TQ3Status Q3DrawContext_SetClearImageColor(TQ3DrawContextObject context, const TQ3ColorARGB *color)
TQ3Status Q3DrawContext_SetMaskState(TQ3DrawContextObject context, TQ3Boolean state)
TQ3Status Q3DrawContext_SetData(TQ3DrawContextObject context, const TQ3DrawContextData *contextData)
TQ3Status Q3PixmapDrawContext_SetPixmap(TQ3DrawContextObject drawContext, const TQ3Pixmap *pixmap)
TQ3DrawContextObject Q3PixmapDrawContext_New(const TQ3PixmapDrawContextData *contextData)
TQ3Status Q3DrawContext_GetPaneState(TQ3DrawContextObject context, TQ3Boolean *state)
TQ3Status Q3DrawContext_GetData(TQ3DrawContextObject context, TQ3DrawContextData *contextData)
TQ3Status Q3DrawContext_SetMask(TQ3DrawContextObject context, const TQ3Bitmap *mask)
TQ3Status Q3DrawContext_SetClearImageMethod(TQ3DrawContextObject context, TQ3DrawContextClearImageMethod method)
TQ3Status Q3PixmapDrawContext_GetPixmap(TQ3DrawContextObject drawContext, TQ3Pixmap *pixmap)
TQ3ObjectType Q3DrawContext_GetType(TQ3DrawContextObject drawContext)
TQ3Status Q3DrawContext_SetPane(TQ3DrawContextObject context, const TQ3Area *pane)
TQ3Status Q3DrawContext_GetPane(TQ3DrawContextObject context, TQ3Area *pane)
TQ3Status Q3DrawContext_GetClearImageMethod(TQ3DrawContextObject context, TQ3DrawContextClearImageMethod *method)
TQ3Status Q3DrawContext_GetDoubleBufferState(TQ3DrawContextObject context, TQ3Boolean *state)
TQ3Status Q3DrawContext_GetClearImageColor(TQ3DrawContextObject context, TQ3ColorARGB *color)
Base types for Quickdraw 3D.
long TQ3ObjectType
Definition: QD3D.h:152
Interface to Quickdraw Graphics.
TQAMethodSelector
Definition: RAVE.h:1009
Definition: Quickdraw.h:2261
Definition: Quickdraw.h:1648
Definition: QD3DDrawContext.h:111
Definition: QD3DDrawContext.h:330