44 VL_DEBUG_SET_OBJECT_NAME()
59 VL_DEBUG_SET_OBJECT_NAME()
85 glViewport( x, y, w, h );
91 if (!Has_GL_EXT_texture_integer)
97 Log::bug(
"Viewport::activate(): GL_EXT_texture_integer not supported.\n");
106 GLboolean color_write_mask[4] = {0,0,0,0};
107 glGetBooleanv( GL_COLOR_WRITEMASK, color_write_mask);
109 GLboolean depth_write_mask = 0;
110 glGetBooleanv( GL_DEPTH_WRITEMASK, &depth_write_mask );
112 GLboolean stencil_write_mask = 0;
113 glGetBooleanv( GL_STENCIL_WRITEMASK, &stencil_write_mask );
116 glColorMask( GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE );
117 glDepthMask( GL_TRUE );
118 glStencilMask( GL_TRUE );
123 glEnable( GL_SCISSOR_TEST );
124 glScissor( x, y, w, h );
127 glDisable( GL_SCISSOR_TEST );
144 glColorMask( color_write_mask[0], color_write_mask[1], color_write_mask[2], color_write_mask[3] );
145 glDepthMask( depth_write_mask );
146 glStencilMask( stencil_write_mask );
156 y -= framebuffer_height - 1 - (this->
y() +
height() -1);
160 if (x<0 || y<0 || x>=this->
width() || y>=this->
height())
EClearColorMode mClearColorMode
Vector4< float > fvec4
A 4 components vector with float precision.
const T_Scalar & r() const
bool isPointInside(int x, int y, int framebuffer_height) const
Returns true if the given point is inside the Viewport.
Visualization Library main namespace.
EClearColorMode clearColorMode() const
static void bug(const String &message)
Use this function to provide information about programming errors: wrong parameter initialization...
const T_Scalar & g() const
const T_Scalar & b() const
const T_Scalar & a() const