home *** CD-ROM | disk | FTP | other *** search
- #ifndef GS_USERCOPPER
- #define GS_USERCOPPER
-
- struct copper_struct
- {
- unsigned short *list; /* pointer to list of copper instructions */
- void *copctrl; /* ptr to controlling struct for user copper lists (UCopList) */
- /* This is NULL for 1st call & alloced by copper routines */
- /* Additional calls to copper routines use same struct */
- void *display; /* ptr to controlling Intuition Screen struct */
- };
-
- struct hard_copper
- {
- struct display_struct *d; /* ptr to GameSmith display structure already set up */
- unsigned short *list; /* ptr to list of copper instructions (pnemonic list) */
- unsigned long flags; /* hard copper flags (allocation, etc.) */
- /* the following are system only fields. Do not touch! */
- unsigned short *LOF_cop[2]; /* ptr to hardware copper list (long frame) pages 1 & 2 */
- unsigned short *SHF_cop[2]; /* ptr to hardware copper list (short frame) pgs 1 & 2 */
- unsigned long coplen; /* length (in bytes) of hardware copper list */
- };
-
- /* hard copper flags: */
-
- #define UCF_DOUBLE 0x01 /* build two display lists for double buffered display */
-
- /* user copper instructions: */
-
- #define UC_END 0 /* marks end of copper list. MUST be last command in table */
- #define UC_WAIT 1 /* wait for display beam position (y,x) */
- #define UC_MOVE 2 /* move data to a hardware register (register,data) */
- #define UC_NOSPRITES 3 /* turn sprites off (NOT SUPPORTED IN GS_VIEWPORT) */
- #define UC_SPRITES 4 /* turn sprites back on (NOT SUPPORTED IN GS_VIEWPORT) */
- #define UC_SETCOLOR 5 /* set a color register (color number,color value) */
- /* The following are hardware copper instructions only. For use with gs_viewport */
- #define UC_SETCOLORAGA 6 /* set an AGA color register */
- #define UC_PVP 7 /* load a parallax viewport */
- #define UC_SPVP 8 /* load a sliced parallax viewport */
-
- struct gs_pvp /* parallax viewport */
- {
- struct gs_pvp *next; /* (SYSTEM USE ONLY!) next parallax viewport this display */
- int height; /* height in scan lines */
- int width; /* width in pixels */
- int depth; /* depth of viewport */
- int xoff; /* X offset within bitmap (in pixels) */
- int yoff; /* Y offset */
- unsigned long flags;
- struct BitMap *bitmap[2]; /* ptr to bitmap(s) pages 1 & 2 */
- /* SYSTEM FIELDS. DO NOT TOUCH! DANGER, HIGH VOLTAGE! */
- unsigned long bplcon; /* offset to horizontal shift load copper instruction */
- unsigned long bplptr; /* offset to 1st bitplane pointer copper instruction */
- unsigned short scroll; /* horizontal scroll value */
- struct gs_viewport *vp; /* ptr to gs_viewport this pvp belongs to */
- unsigned char *LOF_planes1[8]; /* bitplane ptr temp hold for scroll reload (long frame) */
- unsigned char *SHF_planes1[8]; /* bitplane ptr temp hold for scroll reload (short frame) */
- unsigned char *LOF_planes2[8]; /* bitplane ptr temp hold for scroll reload (long frame) */
- unsigned char *SHF_planes2[8]; /* bitplane ptr temp hold for scroll reload (short frame) */
- };
-
- #define PVP_DPF 0x01 /* dual playfield mode */
- #define PVP_DPF1 0x02 /* only load/scroll playfield 1 */
- #define PVP_DPF2 0x04 /* only load/scroll playfield 2 */
- /* NEVER set both PVP_DPF1 and PVP_DPF2 */
- #define PVP_AGACOLOR 0x08 /* used only by spvp, set AGA color regs */
- #define PVP_RELOAD 0x10 /* SYSTEM FLAG: reload new scroll offsets */
- #define PVP_LINE1 0x20 /* spvp only: load color regs line 1 only */
-
- struct gs_spvp /* sliced parallax viewport */
- {
- int top,bottom; /* top and bottom movement values for scroll ratio */
- int height; /* height in scan lines */
- int width; /* width in pixels */
- int depth; /* depth of viewport */
- unsigned long flags; /* same as pvp */
- struct BitMap *bitmap[2]; /* ptr to bitmap to slice (pages 1 & 2) */
- unsigned long *ctable; /* ptr to color table for color change each line */
- unsigned short *cregs; /* ptr to list of color registers to modify each line */
- unsigned short nregs; /* number of registers in list */
- unsigned short scroll_type; /* scroll type (0 through n), effects ratio setup & scroller */
- short inc,carry; /* SYSTEM USE: Do Not Touch! */
- struct gs_pvp *list; /* SYSTEM USE: Do Not Touch! */
- };
-
- #endif
-