Panda3D
vertexDataBlock.h
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file vertexDataBlock.h
10  * @author drose
11  * @date 2007-06-04
12  */
13 
14 #ifndef VERTEXDATABLOCK_H
15 #define VERTEXDATABLOCK_H
16 
17 #include "pandabase.h"
18 #include "simpleAllocator.h"
19 #include "vertexDataPage.h"
20 #include "referenceCount.h"
21 
22 class VertexDataPage;
23 class VertexDataBlock;
24 
25 /**
26  * A block of bytes that stores the actual raw vertex data referenced by a
27  * GeomVertexArrayData object.
28  */
29 class EXPCL_PANDA_GOBJ VertexDataBlock : public SimpleAllocatorBlock, public ReferenceCount {
30 protected:
31  INLINE VertexDataBlock(VertexDataPage *page,
32  size_t start, size_t size);
33 
34 PUBLISHED:
35  INLINE VertexDataPage *get_page() const;
36  INLINE VertexDataBlock *get_next_block() const;
37 
38 public:
39  INLINE unsigned char *get_pointer(bool force) const;
40 
41  friend class VertexDataPage;
42 };
43 
44 #include "vertexDataBlock.I"
45 
46 #endif
A block of bytes that holds one or more VertexDataBlocks.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A block of bytes that stores the actual raw vertex data referenced by a GeomVertexArrayData object.
A single block as returned from SimpleAllocator::alloc().
SimpleAllocatorBlock * get_next_block() const
Returns a pointer to the next allocated block in the chain, or NULL if there are no more allocated bl...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A base class for all things that want to be reference-counted.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.