00001 00002 /************************************************************************** 00003 * cmfile_block.cpp - FVFF Colormap File Block 00004 * 00005 * Created: Mon Mar 31 18:06:17 2008 00006 * Copyright 2005-2008 Tim Niemueller [www.niemueller.de] 00007 * 00008 ***************************************************************************/ 00009 00010 /* This program is free software; you can redistribute it and/or modify 00011 * it under the terms of the GNU General Public License as published by 00012 * the Free Software Foundation; either version 2 of the License, or 00013 * (at your option) any later version. A runtime exception applies to 00014 * this software (see LICENSE.GPL_WRE file mentioned below for details). 00015 * 00016 * This program is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU Library General Public License for more details. 00020 * 00021 * Read the full text in the LICENSE.GPL_WRE file in the doc directory. 00022 */ 00023 00024 #include <fvutils/colormap/cmfile_block.h> 00025 00026 namespace firevision { 00027 #if 0 /* just to make Emacs auto-indent happy */ 00028 } 00029 #endif 00030 00031 /** @class ColormapFileBlock <fvutils/colormap/cmfile_block.h> 00032 * FireVision data file block for colormap files. 00033 * @author Tim Niemueller 00034 */ 00035 00036 00037 /** Constructor. 00038 * @param type block type, content specific 00039 * @param data_size size of the data segment 00040 * @param spec_header content-specific header 00041 * @param spec_header_size size of spec_header in bytes 00042 */ 00043 ColormapFileBlock::ColormapFileBlock(unsigned int type, size_t data_size, 00044 void *spec_header, size_t spec_header_size) 00045 : FireVisionDataFileBlock(type, data_size, spec_header, spec_header_size) 00046 { 00047 } 00048 00049 00050 /** Constructor. 00051 * @param type block type, content specific 00052 * @param data_size size of the data segment 00053 * @param spec_header_size size of spec_header in bytes 00054 */ 00055 ColormapFileBlock::ColormapFileBlock(unsigned int type, size_t data_size, 00056 size_t spec_header_size) 00057 : FireVisionDataFileBlock(type, data_size, spec_header_size) 00058 { 00059 } 00060 00061 00062 /** Constructor. 00063 * @param type block type, content specific 00064 * @param data_size size of the data segment 00065 */ 00066 ColormapFileBlock::ColormapFileBlock(unsigned int type, size_t data_size) 00067 : FireVisionDataFileBlock(type, data_size) 00068 { 00069 } 00070 00071 00072 /** Shallow copy constructor. 00073 * This creates a shallow copy of the given block. "Shallow" means that the data is not 00074 * copied but referenced. This instance is only valid as long as the original instance 00075 * still exists. 00076 * @param block block to copy 00077 */ 00078 ColormapFileBlock::ColormapFileBlock(FireVisionDataFileBlock *block) 00079 : FireVisionDataFileBlock(block) 00080 { 00081 } 00082 00083 00084 /** Virtual empty destructor. */ 00085 ColormapFileBlock::~ColormapFileBlock() 00086 { 00087 } 00088 00089 } // end namespace firevision