** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: array2dfile.h,v 1.7 2000/12/04 03:09:00 kevin Exp $
+** $Id: array2dfile.h,v 1.8 2000/12/04 04:15:48 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
#ifndef ARRAY2DFILE_H
#define ARRAY2DFILE_H
-#ifndef WIN32
+#ifndef MSVC
#include <unistd.h>
#endif
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: ct.h,v 1.39 2000/12/04 03:09:00 kevin Exp $
+** $Id: ct.h,v 1.40 2000/12/04 04:15:48 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
#include <cstdlib>
using namespace std;
-#ifndef WIN32
#include <sstream>
-#endif
-
#include <fstream>
#include <iostream>
#include <string>
~fnetorderstream (void)
{}
- virtual writeInt16 (kuint16 n);
- virtual writeInt32 (kuint32 n);
- virtual writeFloat32 (kfloat32 n);
- virtual writeFloat64 (kfloat64 n);
+ virtual void writeInt16 (kuint16 n);
+ virtual void writeInt32 (kuint32 n);
+ virtual void writeFloat32 (kfloat32 n);
+ virtual void writeFloat64 (kfloat64 n);
- virtual readInt16 (kuint16& n);
- virtual readInt32 (kuint32& n);
- virtual readFloat32 (kfloat32& n);
- virtual readFloat64 (kfloat64& n);
+ virtual void readInt16 (kuint16& n);
+ virtual void readInt32 (kuint32& n);
+ virtual void readFloat32 (kfloat32& n);
+ virtual void readFloat64 (kfloat64& n);
};
frnetorderstream (const char* filename, int mode)
: fnetorderstream (filename, mode) {}
- writeInt16 (kuint16 n);
- writeInt32 (kuint32 n);
- writeFloat32 (kfloat32 n);
- writeFloat64 (kfloat64 n);
+ virtual void writeInt16 (kuint16 n);
+ virtual void writeInt32 (kuint32 n);
+ virtual void writeFloat32 (kfloat32 n);
+ virtual void writeFloat64 (kfloat64 n);
- readInt16 (kuint16& n);
- readInt32 (kuint32& n);
- readFloat32 (kfloat32& n);
- readFloat64 (kfloat64& n);
+ virtual void readInt16 (kuint16& n);
+ virtual void readInt32 (kuint32& n);
+ virtual void readFloat32 (kfloat32& n);
+ virtual void readFloat64 (kfloat64& n);
};
#endif
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: imagefile.h,v 1.18 2000/07/13 07:03:21 kevin Exp $
+** $Id: imagefile.h,v 1.19 2000/12/04 04:15:48 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
#ifndef IMAGEFILE_H
#define IMAGEFILE_H
+#ifndef MSVC\r
+#include <unistd.h>\r
+#endif\r
#include <string>
#include <sys/types.h>
-#include <unistd.h>
#include <fstream>
#include <iostream>
#include "ctsupport.h"
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: sgp.h,v 1.18 2000/09/04 09:06:46 kevin Exp $
+** $Id: sgp.h,v 1.19 2000/12/04 04:15:48 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
MARK_BSQUARE = 9, // big open square
MARK_BDIAMOND = 10, // big open diamond
};
- static const int MARK_COUNT = 11;
+ enum { MARK_COUNT = 11, };
static const unsigned char MARKER_BITMAP[MARK_COUNT][5];
SGP (const SGPDriver& driver);
#ifndef __CM_SSTREAM__
#define __CM_SSTREAM__
+\r
+#ifndef MSVC\r
#include <string>
#include <cstdio>
}
} // End of namespace std
+\r
+#endif\r
#endif
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: array2dfile.cpp,v 1.12 2000/12/04 03:42:00 kevin Exp $
+** $Id: array2dfile.cpp,v 1.13 2000/12/04 04:15:48 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
#include "array2dfile.h"
#include <ctime>
-#ifndef WIN32
#include <sstream>
-#endif
+
using namespace std;
#endif
}
-fnetorderstream& fnetorderstream::writeInt16 (kuint16 n) {
+void\r
+fnetorderstream::writeInt16 (kuint16 n) {
#ifndef WORDS_BIGENDIAN
SwapBytes2 (&n);
#endif
write (reinterpret_cast<const char*>(&n), 2);
- return (*this);
}
-fnetorderstream& fnetorderstream::writeInt32 (kuint32 n) {
+void\r
+fnetorderstream::writeInt32 (kuint32 n) {
#ifndef WORDS_BIGENDIAN
SwapBytes4(&n);
#endif
write (reinterpret_cast<const char*>(&n), 4);
- return (*this);
}
-fnetorderstream& fnetorderstream::writeFloat32 (kfloat32 n) {
+void\r
+fnetorderstream::writeFloat32 (kfloat32 n) {
#ifndef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
write (reinterpret_cast<const char*>(&n), 4);
- return (*this);
}
-fnetorderstream& fnetorderstream::writeFloat64 (kfloat64 n) {
+void\r
+fnetorderstream::writeFloat64 (kfloat64 n) {
#ifndef WORDS_BIGENDIAN
SwapBytes8 (&n);
#endif
write (reinterpret_cast<const char*>(&n), 8);
- return (*this);
}
-fnetorderstream& fnetorderstream::readInt16 (kuint16& n) {
+void\r
+fnetorderstream::readInt16 (kuint16& n) {
read (reinterpret_cast<char*>(&n), 2);
#ifndef WORDS_BIGENDIAN
SwapBytes2 (&n);
#endif
- return (*this);
}
-fnetorderstream& fnetorderstream::readInt32 (kuint32& n) {
+void\r
+fnetorderstream::readInt32 (kuint32& n) {
read (reinterpret_cast<char*>(&n), 4);
#ifndef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
- return (*this);
}
-fnetorderstream& fnetorderstream::readFloat32 (kfloat32& n) {
+void\r
+fnetorderstream::readFloat32 (kfloat32& n) {
read (reinterpret_cast<char*>(&n), 4);
#ifndef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
- return (*this);
}
-fnetorderstream& fnetorderstream::readFloat64 (kfloat64& n) {
+void\r
+fnetorderstream::readFloat64 (kfloat64& n) {
read (reinterpret_cast<char*>(&n), 8);
#ifndef WORDS_BIGENDIAN
SwapBytes8 (&n);
#endif
- return (*this);
}
-frnetorderstream& frnetorderstream::writeInt16 (kuint16 n) {
+void\r
+frnetorderstream::writeInt16 (kuint16 n) {
#ifdef WORDS_BIGENDIAN
SwapBytes2 (&n);
#endif
write (reinterpret_cast<char*>(&n), 2);
- return (*this);
}
-frnetorderstream& frnetorderstream::writeInt32 (kuint32 n) {
+void\r
+frnetorderstream::writeInt32 (kuint32 n) {
#ifdef WORDS_BIGENDIAN
SwapBytes4(&n);
#endif
write (reinterpret_cast<char*>(&n), 4);
- return (*this);
}
-frnetorderstream& frnetorderstream::writeFloat32 (kfloat32 n) {
+void \r
+frnetorderstream::writeFloat32 (kfloat32 n) {
#ifdef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
write (reinterpret_cast<char*>(&n), 4);
- return (*this);
}
-frnetorderstream& frnetorderstream::writeFloat64 (kfloat64 n) {
+void \r
+frnetorderstream::writeFloat64 (kfloat64 n) {
#ifdef WORDS_BIGENDIAN
SwapBytes8 (&n);
#endif
write (reinterpret_cast<char*>(&n), 8);
- return (*this);
}
-frnetorderstream& frnetorderstream::readInt16 (kuint16& n) {
+void \r
+frnetorderstream::readInt16 (kuint16& n) {
read (reinterpret_cast<char*>(&n), 2);
#ifdef WORDS_BIGENDIAN
SwapBytes2 (&n);
#endif
- return (*this);
}
-frnetorderstream& frnetorderstream::readInt32 (kuint32& n) {
+void \r
+frnetorderstream::readInt32 (kuint32& n) {
read (reinterpret_cast<char*>(&n), 4);
#ifdef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
- return (*this);
}
-frnetorderstream& frnetorderstream::readFloat32 (kfloat32& n) {
+void\r
+frnetorderstream::readFloat32 (kfloat32& n) {
read (reinterpret_cast<char*>(&n), 4);
#ifdef WORDS_BIGENDIAN
SwapBytes4 (&n);
#endif
- return (*this);
}
-frnetorderstream& frnetorderstream::readFloat64 (kfloat64& n) {
+void\r
+frnetorderstream::readFloat64 (kfloat64& n) {
read (reinterpret_cast<char*>(&n), 8);
#ifdef WORDS_BIGENDIAN
SwapBytes8 (&n);
#endif
- return (*this);
}