00001 /********************************************************************** 00002 * File: polyvert.h (Formerly polypt.h) 00003 * Description: Code for the POLYPT class. 00004 * Author: Ray Smith 00005 * Created: Wed Oct 23 11:02:56 BST 1991 00006 * 00007 * (C) Copyright 1991, Hewlett-Packard Ltd. 00008 ** Licensed under the Apache License, Version 2.0 (the "License"); 00009 ** you may not use this file except in compliance with the License. 00010 ** You may obtain a copy of the License at 00011 ** http://www.apache.org/licenses/LICENSE-2.0 00012 ** Unless required by applicable law or agreed to in writing, software 00013 ** distributed under the License is distributed on an "AS IS" BASIS, 00014 ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00015 ** See the License for the specific language governing permissions and 00016 ** limitations under the License. 00017 * 00018 **********************************************************************/ 00019 00020 #ifndef POLYVERT_H 00021 #define POLYVERT_H 00022 00023 #include "elst2.h" 00024 #include "rect.h" 00025 00026 class POLYPT:public ELIST2_LINK 00027 { 00028 public: 00029 POLYPT() { //empty 00030 } 00031 POLYPT( //constructor 00032 const FCOORD &position, //coords 00033 const FCOORD &vector) { //step to next 00034 pos = position; 00035 vec = vector; //just copy 00036 } 00037 00038 void prep_serialise() { //set ptrs to counts 00039 } 00040 void dump( //write external bits 00041 FILE *) { 00042 } 00043 void de_dump( //read external bits 00044 FILE *) { 00045 } 00046 00047 static POLYPT* deep_copy(const POLYPT* src) { 00048 return new POLYPT(*src); 00049 } 00050 //really simple 00051 make_serialise (POLYPT) 00052 00053 FCOORD pos; 00054 FCOORD vec; //vector to next 00055 }; 00056 00057 ELIST2IZEH_S (POLYPT) 00058 #endif