14#ifndef DRAWABLEREGION_H
15#define DRAWABLEREGION_H
29class EXPCL_PANDA_DISPLAY DrawableRegion {
31 INLINE DrawableRegion();
32 INLINE DrawableRegion(
const DrawableRegion ©);
33 INLINE
void operator = (
const DrawableRegion ©);
34 virtual ~DrawableRegion();
42 enum RenderTexturePlane {
106 INLINE
void update_pixel_factor();
107 virtual void pixel_factor_changed();
110 int _screenshot_buffer_type;
111 int _draw_buffer_type;
115 LColor _clear_value[RTP_COUNT];
117 PN_stdfloat _pixel_zoom;
118 PN_stdfloat _pixel_factor;
get_clear_color
Returns the current clear color value.
int get_draw_buffer_type() const
Returns the RenderBuffer into which the GSG should issue draw commands.
get_clear_stencil
Returns the current clear stencil value.
set_pixel_zoom
Sets the amount by which the pixels of the region are scaled internally when filling the image intera...
virtual void set_clear_value(int n, const LColor &clear_value)
Sets the clear value for any bitplane.
set_clear_stencil
Sets the clear stencil to the indicated value.
void set_clear_stencil_active(bool clear_stencil_active)
Toggles the flag that indicates whether the stencil buffer should be cleared every frame.
virtual bool supports_pixel_zoom() const
Returns true if a call to set_pixel_zoom() will be respected, false if it will be ignored.
void set_clear_color_active(bool clear_color_active)
Toggles the flag that indicates whether the color buffer should be cleared every frame.
static int get_renderbuffer_type(int plane)
Returns the RenderBuffer::Type that corresponds to a RenderTexturePlane.
virtual const LColor & get_clear_value(int n) const
Returns the clear value for any bitplane.
bool get_clear_depth_active() const
Returns the current setting of the flag that indicates whether the depth buffer should be cleared eve...
virtual bool get_clear_active(int n) const
Gets the clear-active flag for any bitplane.
get_clear_depth
Returns the current clear depth value.
virtual void set_clear_active(int n, bool clear_aux_active)
Sets the clear-active flag for any bitplane.
set_clear_depth
Sets the clear depth to the indicated value.
virtual bool is_any_clear_active() const
Returns true if any of the clear types (so far there are just color or depth) have been set active,...
get_pixel_zoom
Returns the value set by set_pixel_zoom(), regardless of whether it is being respected or not.
void copy_clear_settings(const DrawableRegion ©)
Copies only the clear settings from the other drawable region.
set_clear_color
Sets the clear color to the indicated value.
bool get_clear_stencil_active() const
Returns the current setting of the flag that indicates whether the color buffer should be cleared eve...
bool get_clear_color_active() const
Returns the current setting of the flag that indicates whether the color buffer should be cleared eve...
void set_clear_depth_active(bool clear_depth_active)
Toggles the flag that indicates whether the depth buffer should be cleared every frame.
int get_screenshot_buffer_type() const
Returns the RenderBuffer that should be used for capturing screenshots from this particular DrawableR...
virtual void disable_clears()
Disables both the color and depth clear.
get_pixel_factor
Returns the amount by which the height and width of the region will be scaled internally,...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.