#include "FImage.h" #include "stdlib.h" #include "memory.h" void FImage::Init(void) { fPixels=NULL; fXSize=0; fYSize=0; } FImage::FImage(void) { Init(); } FImage::FImage(short x, short y) { Init(); SetSize(x,y); } void FImage::SetSize(short x, short y) { if (fPixels!=NULL) { DisposPtr((Ptr)fPixels); } fPixels=(float *)NewPtr(sizeof(float) * x * y); if (fPixels!=NULL) { fXSize=x; fYSize=y; } }