Panda3D
pipelineCyclerLinks.h
1 // Filename: pipelineCyclerLinks.h
2 // Created by: drose (16Feb06)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #ifndef PIPELINECYCLERLINKS_H
16 #define PIPELINECYCLERLINKS_H
17 
18 #include "pandabase.h"
19 #include "selectThreadImpl.h" // for THREADED_PIPELINE definition
20 #include "pnotify.h"
21 
22 ////////////////////////////////////////////////////////////////////
23 // Class : PipelineCyclerLinks
24 // Description : This just stores the pointers to implement a
25 // doubly-linked list of PipelineCyclers for a
26 // particular Pipeline object. We use a hand-rolled
27 // linked list rather than any STL container, because we
28 // want PipelineCyclers to be able to add and remove
29 // themselves from this list very quickly.
30 //
31 // These pointers are inherited from this separate class
32 // so the Pipeline object itself can be the root of the
33 // linked list.
34 ////////////////////////////////////////////////////////////////////
35 class EXPCL_PANDA_PIPELINE PipelineCyclerLinks {
36 protected:
37 #ifdef THREADED_PIPELINE
38  INLINE PipelineCyclerLinks();
39  INLINE ~PipelineCyclerLinks();
40 
41  INLINE void make_head();
42  INLINE void clear_head();
43 
44  INLINE void remove_from_list();
45  INLINE void insert_before(PipelineCyclerLinks *node);
46 
47  INLINE void take_list(PipelineCyclerLinks &other);
48 
49  PipelineCyclerLinks *_prev, *_next;
50 #endif
51  friend class Pipeline;
52 };
53 
54 #include "pipelineCyclerLinks.I"
55 
56 #endif
This class manages a staged pipeline of data, for instance the render pipeline, so that each stage of...
Definition: pipeline.h:41