Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

pandatool/src/lwo/lwoSurfaceSidedness.cxx

Go to the documentation of this file.
00001 // Filename: lwoSurfaceSidedness.cxx
00002 // Created by:  drose (24Apr01)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) 2001, Disney Enterprises, Inc.  All rights reserved
00008 //
00009 // All use of this software is subject to the terms of the Panda 3d
00010 // Software license.  You should have received a copy of this license
00011 // along with this source code; you will also find a current copy of
00012 // the license at http://www.panda3d.org/license.txt .
00013 //
00014 // To contact the maintainers of this program write to
00015 // panda3d@yahoogroups.com .
00016 //
00017 ////////////////////////////////////////////////////////////////////
00018 
00019 #include "lwoSurfaceSidedness.h"
00020 #include "lwoInputFile.h"
00021 
00022 #include "dcast.h"
00023 #include "indent.h"
00024 
00025 TypeHandle LwoSurfaceSidedness::_type_handle;
00026 
00027 ////////////////////////////////////////////////////////////////////
00028 //     Function: LwoSurfaceSidedness::read_iff
00029 //       Access: Public, Virtual
00030 //  Description: Reads the data of the chunk in from the given input
00031 //               file, if possible.  The ID and length of the chunk
00032 //               have already been read.  stop_at is the byte position
00033 //               of the file to stop at (based on the current position
00034 //               at in->get_bytes_read()).  Returns true on success,
00035 //               false otherwise.
00036 ////////////////////////////////////////////////////////////////////
00037 bool LwoSurfaceSidedness::
00038 read_iff(IffInputFile *in, size_t stop_at) {
00039   LwoInputFile *lin = DCAST(LwoInputFile, in);
00040 
00041   _sidedness = (Sidedness)lin->get_be_int16();
00042 
00043   return true;
00044 }
00045 
00046 ////////////////////////////////////////////////////////////////////
00047 //     Function: LwoSurfaceSidedness::write
00048 //       Access: Public, Virtual
00049 //  Description:
00050 ////////////////////////////////////////////////////////////////////
00051 void LwoSurfaceSidedness::
00052 write(ostream &out, int indent_level) const {
00053   indent(out, indent_level)
00054     << get_id() << " { sidedness = " << (int)_sidedness << " }\n";
00055 }

Generated on Fri May 2 03:21:02 2003 for Panda-Tool by doxygen1.3