Panda3D
Loading...
Searching...
No Matches
graphicsOutputBase.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 graphicsOutputBase.h
10 * @author drose
11 * @date 2009-05-27
12 */
13
14#ifndef GRAPHICSOUTPUTBASE_H
15#define GRAPHICSOUTPUTBASE_H
16
17#include "pandabase.h"
19
20class Texture;
21
22/**
23 * An abstract base class for GraphicsOutput, for all the usual reasons.
24 */
25class EXPCL_PANDA_GSGBASE GraphicsOutputBase : public TypedWritableReferenceCount {
26PUBLISHED:
27 virtual void set_sort(int sort)=0;
28 virtual Texture *get_texture(int i=0) const=0;
29
30public:
31 static TypeHandle get_class_type() {
32 return _type_handle;
33 }
34 static void init_type() {
35 TypedWritableReferenceCount::init_type();
36 register_type(_type_handle, "GraphicsOutputBase",
37 TypedWritableReferenceCount::get_class_type());
38 }
39 virtual TypeHandle get_type() const {
40 return get_class_type();
41 }
42 virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
43
44private:
45 static TypeHandle _type_handle;
46
47 friend class GraphicsPipe;
48 friend class GraphicsEngine;
49 friend class DisplayRegion;
50};
51
52#include "graphicsOutputBase.I"
53
54#endif
An abstract base class for GraphicsOutput, for all the usual reasons.
Represents a texture object, which is typically a single 2-d image but may also represent a 1-d or 3-...
Definition texture.h:72
TypeHandle is the identifier used to differentiate C++ class types.
Definition typeHandle.h:81
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.