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

panda/src/pgraph/lightLensNode.h

Go to the documentation of this file.
00001 // Filename: lightLensNode.h
00002 // Created by:  drose (26Mar02)
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 #ifndef LIGHTLENSNODE_H
00020 #define LIGHTLENSNODE_H
00021 
00022 #include "pandabase.h"
00023 
00024 #include "light.h"
00025 #include "lensNode.h"
00026 
00027 ////////////////////////////////////////////////////////////////////
00028 //       Class : LightLensNode
00029 // Description : A derivative of Light and of LensNode.  
00030 ////////////////////////////////////////////////////////////////////
00031 class EXPCL_PANDA LightLensNode : public Light, public LensNode {
00032 PUBLISHED:
00033   LightLensNode(const string &name);
00034 
00035 protected:
00036   LightLensNode(const LightLensNode &copy);
00037 
00038 public:
00039   virtual PandaNode *as_node();
00040   virtual Light *as_light();
00041 
00042 PUBLISHED:
00043   // We have to explicitly publish these because they resolve the
00044   // multiple inheritance.
00045   virtual void output(ostream &out) const;
00046   virtual void write(ostream &out, int indent_level = 0) const;
00047 
00048 public:
00049   virtual void write_datagram(BamWriter *manager, Datagram &dg);
00050 
00051 protected:
00052   void fillin(DatagramIterator &scan, BamReader *manager);
00053 
00054 public:
00055   static TypeHandle get_class_type() {
00056     return _type_handle;
00057   }
00058   static void init_type() {
00059     Light::init_type();
00060     LensNode::init_type();
00061     register_type(_type_handle, "LightLensNode",
00062                   Light::get_class_type(),
00063                   LensNode::get_class_type());
00064   }
00065   virtual TypeHandle get_type() const {
00066     return get_class_type();
00067   }
00068   virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
00069 
00070 private:
00071   static TypeHandle _type_handle;
00072 };
00073 
00074 INLINE ostream &operator << (ostream &out, const LightLensNode &light) {
00075   light.output(out);
00076   return out;
00077 }
00078 
00079 #include "lightLensNode.I"
00080 
00081 #endif

Generated on Fri May 2 00:41:45 2003 for Panda by doxygen1.3