Topic : TOS - das Betriebssystem
Author :
Version : tos.hyp (5. März 2013)
Subject : Programmieren/Atari
Nodes : 3001
Index Size : 93602
HCP-Version : 5
Compiled on : Atari
@charset : atarist
@lang :
@default : Titel
@help :
@options : +g -i -s +x +zz -t4
@width : 70
View Ref-File7.8.1.4 Bindings für vq_margins TOS
C: int16_t vq_margins( int16_t handle, int16_t *top_margin,
int16_t *bottom_margin, int16_t *left_margin, int16_t
*right_margin, int16_t *hdpi, int16_t *vdpi );
Umsetzung:
int16_t vq_margins( int16_t handle, int16_t *top_margin,
int16_t *bottom_margin, int16_t *left_margin,
int16_t *right_margin, int16_t *hdpi,
int16_t *vdpi )
{
intout[0] = 0;
contrl[0] = 5;
contrl[1] = 0;
contrl[3] = 0;
contrl[5] = 2100;
contrl[6] = handle;
vdi ();
*top_margin = intout[1];
*bottom_margin = intout[2];
*left_margin = intout[3];
*right_margin = intout[4];
*hdpi = intout[5];
*vdpi = intout[6];
return ( intout[0] );
}
GEM-Arrays:
Adresse Feldelement Belegung
contrl contrl[0] 5 # Opcode der Funktion
contrl+2 contrl[1] 0 # Einträge in ptsin
contrl+4 contrl[2] 0 # Einträge in ptsout
contrl+6 contrl[3] 0 # Einträge in intin
contrl+8 contrl[4] 7 # Einträge in intout
contrl+10 contrl[5] 2100 # Escape/Sub-Opcode
contrl+12 contrl[6] handle
intout intout[0] Return-Wert
intout+2 intout[1] top_margin
intout+4 intout[2] bottom_margin
intout+6 intout[3] left_margin
intout+8 intout[4] right_margin
intout+10 intout[5] hdpi
intout+12 intout[6] vdpi