14 #ifndef DEPTHOFFSETATTRIB_H 15 #define DEPTHOFFSETATTRIB_H 52 INLINE
DepthOffsetAttrib(
int offset, PN_stdfloat min_value, PN_stdfloat max_value);
56 static CPT(
RenderAttrib) make(
int offset, PN_stdfloat min_value, PN_stdfloat max_value);
59 INLINE
int get_offset()
const;
60 INLINE PN_stdfloat get_min_value()
const;
61 INLINE PN_stdfloat get_max_value()
const;
64 MAKE_PROPERTY(offset, get_offset);
65 MAKE_PROPERTY(min_value, get_min_value);
66 MAKE_PROPERTY(max_value, get_max_value);
69 virtual void output(std::ostream &out)
const;
72 virtual int compare_to_impl(
const RenderAttrib *other)
const;
73 virtual size_t get_hash_impl()
const;
79 PN_stdfloat _min_value;
80 PN_stdfloat _max_value;
83 static int get_class_slot() {
86 virtual int get_slot()
const {
87 return get_class_slot();
89 MAKE_PROPERTY(class_slot, get_class_slot);
92 static void register_with_read_factory();
103 static void init_type() {
104 RenderAttrib::init_type();
106 RenderAttrib::get_class_type());
111 return get_class_type();
113 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
117 static int _attrib_slot;
This is the base class for a number of render attributes (other than transform) that may be set on sc...
This is the fundamental interface for extracting binary objects from a Bam file, as generated by a Ba...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Base class for objects that can be written to and read from Bam files.
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.
This is the fundamental interface for writing binary objects to a Bam file, to be extracted later by ...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
virtual void write_datagram(BamWriter *manager, Datagram &dg)
Writes the contents of this object to the datagram for shipping out to a Bam file.
static int register_slot(TypeHandle type_handle, int sort, RenderAttrib *default_attrib)
Adds the indicated TypeHandle to the registry, if it is not there already, and returns a unique slot ...
An instance of this class is passed to the Factory when requesting it to do its business and construc...
This is a special kind of attribute that instructs the graphics driver to apply an offset or bias to ...
A class to retrieve the individual data elements previously stored in a Datagram.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
TypeHandle is the identifier used to differentiate C++ class types.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...