Defines | Functions

xgequatrotball.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <malloc.h>
#include <string.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/cursorfont.h>
#include "xgedit.h"
#include "xgeprivate.h"
Include dependency graph for xgequatrotball.c:

Defines

#define T0   0.5
#define T1   0.53125
#define T2   0.46875
#define STKSIZE   16
#define NEIGHBOURS(a, b)   abs(a.x-b.x) <= 1 && abs(a.y-b.y) <= 1
#define OUTPUT(px, z)
#define PUSH(p, v, l)
#define READ(p, v, l)   { p = stack[stp-1].px; v = stack[stp-1].vx; l = stack[stp-1].level; }
#define POP   stp--;

Functions

void _xge_QuatRotBallDrawCircles (short xc, short yc, short r, trans3f *tr)

Define Documentation

#define NEIGHBOURS (   a,
  b 
)    abs(a.x-b.x) <= 1 && abs(a.y-b.y) <= 1
#define OUTPUT (   px,
  z 
)
Value:
{ if ( z >= 0.0 ) { \
      if ( _pkv_npix == PKV_BUFSIZE ) { _pkv_npix -= 2;  PKV_FLUSH \
        memcpy ( &_pkv_pixbuf[0], &_pkv_pixbuf[PKV_BUFSIZE-2], 2*sizeof(xpoint) ); \
        _pkv_npix = 2; } \
      if ( _pkv_npix > 1 ) \
        { if ( NEIGHBOURS ( px, _pkv_pixbuf[_pkv_npix-2] ) ) _pkv_npix--; } \
      _pkv_pixbuf[_pkv_npix] = px;  _pkv_npix++; \
    } \
    lastz = z; \
  }
#define POP   stp--;
#define PUSH (   p,
  v,
  l 
)
Value:
{ if (stp < STKSIZE) { stack[stp].px = p;  stack[stp].vx = (v); \
                         stack[stp].level = l;  stp++; } }
#define READ (   p,
  v,
  l 
)    { p = stack[stp-1].px; v = stack[stp-1].vx; l = stack[stp-1].level; }
#define STKSIZE   16
#define T0   0.5
#define T1   0.53125
#define T2   0.46875

Function Documentation

void _xge_QuatRotBallDrawCircles ( short  xc,
short  yc,
short  r,
trans3f tr 
)