19#ifndef NS_ATARI_PLOT_H
20#define NS_ATARI_PLOT_H
23#define CONV_KEEP_LIMIT 512000
26#define CONV_BLOCK_SIZE 32000
29#define PLOT_FLAG_DITHER 0x04
30#define PLOT_FLAG_TRANS 0x08
33#define PLOT_FLAG_HAS_DITHER 0x0400
34#define PLOT_FLAG_HAS_ALPHA 0x0800
35#define PLOT_FLAG_OFFSCREEN 0x1000
38#define PLOT_FLAG_LOCKED 0x08000
41#define FONTPLOT_FLAG_MONOGLYPH 0x01
44#define MFDB_FLAG_STAND 0x01
45#define MFDB_FLAG_ZEROMEM 0x02
46#define MFDB_FLAG_NOALLOC 0x04
49#define BITMAPF_MONOGLYPH 4096
50#define BITMAPF_BUFFER_NATIVE 8192
53#define ERR_BUFFERSIZE_EXCEEDS_SCREEN 1
55#define ERR_PLOTTER_NOT_AVAILABLE 3
129 unsigned long bg,
unsigned long flags);
130bool plot_blit_mfdb(GRECT * loc, MFDB * insrc,
short fgcolor, uint32_t flags);
143#define NSLT2VDI(dst, src) \
145 switch( src->stroke_type ) { \
146 case PLOT_OP_TYPE_DOT: \
147 dst = (0xAAAA00 | 7); \
149 case PLOT_OP_TYPE_DASH: \
152 case PLOT_OP_TYPE_SOLID: \
153 case PLOT_OP_TYPE_NONE: \
160#ifdef WITH_8BPP_SUPPORT
164#define OFFSET_WEB_PAL 16
165#define OFFSET_CUST_PAL 232
166#define RGB_TO_VDI(c) rgb_to_666_index( (c&0xFF),(c&0xFF00)>>8,(c&0xFF0000)>>16)+OFFSET_WEB_PAL
170#define ABGR_TO_RGB(c) ( ((c&0xFF)<<16) | (c&0xFF00) | ((c&0xFF0000)>>16) ) << 8
175#define OFFSET_CUSTOM_COLOR 255
bool plot_blit_mfdb(GRECT *loc, MFDB *insrc, short fgcolor, uint32_t flags)
const struct plotter_table atari_plotters
atari plottr operation table
void plot_get_abs_clipping(struct rect *dst)
Get the maximum clip extent, in absolute screen coords.
bool plot_blit_bitmap(struct bitmap *bmp, int x, int y, unsigned long bg, unsigned long flags)
float plot_get_scale(void)
void rgb_to_vdi1000(unsigned char *in, RGB1000 *out)
Convert an RGB color to an VDI Color.
long plot_get_flags(void)
bool plot_get_clip(struct rect *out)
const char * plot_err_str(int i)
translate an error number
short rgb_to_666_index(unsigned char r, unsigned char g, unsigned char b)
void vdi1000_to_rgb(unsigned short *in, unsigned char *out)
VdiHdl plot_get_vdi_handle(void)
void plot_get_clip_grect(GRECT *out)
Get clipping for current framebuffer as GRECT.
float plot_set_scale(float)
set scale of plotter.
bool plot_copy_rect(GRECT src, GRECT dst)
copy an rectangle from the plot buffer to screen
void plot_set_abs_clipping(const GRECT *area)
Subsequent calls to plot_clip will be clipped by the absolute clip.
bool plot_set_dimensions(const struct redraw_context *ctx, int x, int y, int w, int h)
Set plot origin and canvas size.
void plot_get_abs_clipping_grect(GRECT *dst)
Get the maximum clip extent, in absolute screen coords.
bool plot_get_dimensions(GRECT *dst)
Get current canvas size.
int plot_init(const struct redraw_context *ctx, char *fdrvrname)
Init screen and font driver objects.
RISC OS wimp toolkit bitmap.
Plot style for stroke/fill plotters.
Plotter operations table.
void * screen
pointer to screen, or NULL
short scr_h
resolution vert.
unsigned long screensize
size of screen (in bytes)
short pixelsize
bytes per pixel
unsigned long hicolors
if colors = 0
unsigned long mask_b
blue color mask
int colors
0=hiclor, 2=mono
short vdi_handle
vdi handle
short scr_bpp
bits per pixel
unsigned short pitch
row pitch
unsigned long mask_a
alpha color mask
unsigned long EdDiVersion
unsigned short clut
type of clut support
unsigned short vdiformat
pixel format
unsigned long mask_g
green color mask
short scr_w
resolution horz.
unsigned long mask_r
red color mask