00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef AMBIENTLIGHT_H
00016 #define AMBIENTLIGHT_H
00017
00018 #include "pandabase.h"
00019
00020 #include "lightNode.h"
00021
00022
00023
00024
00025
00026
00027
00028
00029 class EXPCL_PANDA_PGRAPHNODES AmbientLight : public LightNode {
00030 PUBLISHED:
00031 AmbientLight(const string &name);
00032
00033 protected:
00034 AmbientLight(const AmbientLight ©);
00035
00036 public:
00037 virtual PandaNode *make_copy() const;
00038 virtual void write(ostream &out, int indent_level) const;
00039 virtual bool is_ambient_light() const;
00040
00041 PUBLISHED:
00042 virtual int get_class_priority() const;
00043
00044 public:
00045 virtual void bind(GraphicsStateGuardianBase *gsg, const NodePath &light,
00046 int light_id);
00047
00048 public:
00049 static void register_with_read_factory();
00050 virtual void write_datagram(BamWriter *manager, Datagram &dg);
00051
00052 protected:
00053 static TypedWritable *make_from_bam(const FactoryParams ¶ms);
00054 void fillin(DatagramIterator &scan, BamReader *manager);
00055
00056 public:
00057 static TypeHandle get_class_type() {
00058 return _type_handle;
00059 }
00060 static void init_type() {
00061 LightNode::init_type();
00062 register_type(_type_handle, "AmbientLight",
00063 LightNode::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 AmbientLight &light) {
00075 light.output(out);
00076 return out;
00077 }
00078
00079 #include "ambientLight.I"
00080
00081 #endif