Browse Source

expose some more stuff

David Rose 24 years ago
parent
commit
4d6334533b

+ 14 - 0
panda/src/display/graphicsWindow.I

@@ -385,6 +385,20 @@ get_button_event(int device) {
   return _input_devices[device].get_button_event();
 }
 
+////////////////////////////////////////////////////////////////////
+//     Function: GraphicsWindow::render_and_update
+//       Access: Published
+//  Description: Renders the scene associated with the window and
+//               updates the window.
+////////////////////////////////////////////////////////////////////
+INLINE void GraphicsWindow::
+render_and_update() {
+  if (_gsg != (GraphicsStateGuardian *)NULL) {
+    _gsg->render_frame();
+  }
+  update();
+}
+
 ////////////////////////////////////////////////////////////////////
 //     Function: GraphicsWindow::set_sync
 //       Access: Public

+ 1 - 0
panda/src/display/graphicsWindow.h

@@ -193,6 +193,7 @@ PUBLISHED:
   virtual void main_loop();
   virtual bool supports_update() const;
   virtual void update();
+  INLINE void render_and_update();
 
 public:
   virtual void begin_frame();

+ 9 - 0
panda/src/sgraphutil/appTraverser.I

@@ -27,3 +27,12 @@ AppTraverser(TypeHandle graph_type) :
   _graph_type(graph_type)
 {
 }
+
+////////////////////////////////////////////////////////////////////
+//     Function: AppTraverser::Destructor
+//       Access: Public
+//  Description:
+////////////////////////////////////////////////////////////////////
+INLINE AppTraverser::
+~AppTraverser() {
+}

+ 2 - 1
panda/src/sgraphutil/appTraverser.h

@@ -37,8 +37,9 @@ class Node;
 ////////////////////////////////////////////////////////////////////
 class EXPCL_PANDA AppTraverser :
   public TraverserVisitor<NullTransitionWrapper, NullLevelState> {
-public:
+PUBLISHED:
   INLINE AppTraverser(TypeHandle graph_type);
+  INLINE ~AppTraverser();
 
   void traverse(Node *root);