22 #define _USE_MATH_DEFINES // for M_PI 33 #define PROTO_INCREMENT 32 34 #define CONFIG_INCREMENT 16 105 for (Bit = Class->
NumProtos; Bit < NewNumProtos; Bit++)
111 tprintf(
"Ouch! number of protos = %d, vs max of %d!",
124 float Slope, Intercept, Normalizer;
126 Slope = tan(Proto->
Angle * 2.0 * M_PI);
127 Intercept = Proto->
Y - Slope * Proto->
X;
128 Normalizer = 1.0 / sqrt (Slope * Slope + 1.0);
129 Proto->
A = Slope * Normalizer;
130 Proto->
B = -Normalizer;
131 Proto->
C = Intercept * Normalizer;
#define WordsInVectorOfSize(NumBits)
void FreeBitVector(BIT_VECTOR BitVector)
int AddProtoToClass(CLASS_TYPE Class)
#define reset_bit(array, bit)
int AddConfigToClass(CLASS_TYPE Class)
#define zero_all_bits(array, length)
BIT_VECTOR NewBitVector(int NumBits)
void * Erealloc(void *ptr, int size)
void FillABC(PROTO Proto)
DLLSYM void tprintf(const char *format,...)
void FreeClassFields(CLASS_TYPE Class)
CLASS_TYPE NewClass(int NumProtos, int NumConfigs)
void FreeClass(CLASS_TYPE Class)
BIT_VECTOR ExpandBitVector(BIT_VECTOR Vector, int NewNumBits)