From 00dbb1617b0ffb378cdf18f5e2e2129f8a9d78c7 Mon Sep 17 00:00:00 2001 From: "Asad M. Zaman" Date: Thu, 9 Sep 2004 23:50:15 +0000 Subject: [PATCH] added make_copy on polylightnode, more cleanup coming up --- panda/src/pgraph/polylightNode.cxx | 13 +++++++++++++ panda/src/pgraph/polylightNode.h | 1 + 2 files changed, 14 insertions(+) diff --git a/panda/src/pgraph/polylightNode.cxx b/panda/src/pgraph/polylightNode.cxx index 05acefaae8..be52dfbc2d 100755 --- a/panda/src/pgraph/polylightNode.cxx +++ b/panda/src/pgraph/polylightNode.cxx @@ -56,6 +56,19 @@ PandaNode(name) _sin_freq = 2.0; } +//////////////////////////////////////////////////////////////////// +// Function: PolylightNode::make_copy +// Access: Public, Virtual +// Description: Returns a newly-allocated Node that is a shallow copy +// of this one. It will be a different Node pointer, +// but its internal data may or may not be shared with +// that of the original Node. +//////////////////////////////////////////////////////////////////// +PandaNode *PolylightNode:: +make_copy() const { + return new PolylightNode(*this); +} + //////////////////////////////////////////////////////////////////// // Function: PolylightNode::Constructor // Access: Public diff --git a/panda/src/pgraph/polylightNode.h b/panda/src/pgraph/polylightNode.h index a6bc3d702e..6e90b915fe 100755 --- a/panda/src/pgraph/polylightNode.h +++ b/panda/src/pgraph/polylightNode.h @@ -103,6 +103,7 @@ PUBLISHED: public: Colorf flicker() const; + virtual PandaNode *make_copy() const; private: