, m_LineWidthSet(
false)
45, m_LineJoinStyle(eMiteredJoin)
46, m_LineJoinStyleSet(
false)
47, m_LineCapStyle(eButtCap)
48, m_LineCapStyleSet(
false)
49, m_PdfShadeStyle(eGouraud)
50, m_PdfShadeStyleSet(
false)
52, m_PointSizeSet(
false)
53, m_ShadeModel(GL_SMOOTH)
54, m_ShadeModelSet(
false)
55, m_ScissorRect(0, 0, 0, 0)
56, m_ScissorSet(
false)
57, m_Color(1.0f, 1.0f, 1.0f, 1.0f)
59, m_ColorMaskRed(
true)
60, m_ColorMaskGreen(
true)
61, m_ColorMaskBlue(
true)
62, m_ColorMaskAlpha(
true)
63, m_ColorMaskSet(
false)
64, m_PolygonModeFace(GL_FRONT_AND_BACK)
65, m_PolygonMode(GL_FILL)
66, m_PolygonModeSet(
false)
67, m_LineStippleFactor(1)
68, m_LineStipplePattern(0xFFFF)
69, m_LineStippleSet(
false)
70, m_PolygonStippleSet(
false)
71, m_SourceBlendFactor(GL_ONE)
72, m_TargetBlendFactor(GL_ZERO)
73, m_BlendFuncSet(
false)
74, m_BlendEquation(GL_FUNC_ADD)
75, m_BlendEquationSet(
false)
76, m_BlendFuncSeparateSet(
false)
77, m_BlendColor(0.0f, 0.0f, 0.0f, 0.0f)
78, m_BlendColorSet(
false)
79, m_ScaleInvarient(
false)
80, m_ScaleInvarientSet(
false)
176 if(
mask== GL_ALL_ATTRIB_BITS)
182 if(!(
mask|GL_LINE_BIT)) {
195 if(!(
mask|GL_POINT_BIT)) {
200 if(!(
mask|GL_LIGHTING_BIT)) {
205 if(!(
mask|GL_SCISSOR_BIT)) {
212 if(!(
mask|GL_CURRENT_BIT)) {
218 if(!(
mask|GL_SCISSOR_BIT)) {
228 if(!(
mask|GL_POLYGON_BIT)) {
238 if(!(
mask|GL_LINE_BIT)) {
245 if(!(
mask|GL_POLYGON_STIPPLE_BIT)) {
252 if(!(
mask|GL_COLOR_BUFFER_BIT)) {
270 if(!(
mask|GL_ENABLE_BIT)) {
290 if(e==GL_BLEND && (
mask|GL_COLOR_BUFFER_BIT))
292 if(e==GL_ALPHA_TEST && (
mask|GL_COLOR_BUFFER_BIT))
294 if(e==GL_DITHER && (
mask|GL_COLOR_BUFFER_BIT))
296 if(e==GL_COLOR_LOGIC_OP && (
mask|GL_COLOR_BUFFER_BIT))
298 if(e==GL_INDEX_LOGIC_OP && (
mask|GL_COLOR_BUFFER_BIT))
301 if(e==GL_DEPTH_TEST && (
mask|GL_DEPTH_BUFFER_BIT))
304 if(e==GL_FOG && (
mask|GL_FOG_BIT))
307 if(e==GL_COLOR_MATERIAL && (
mask|GL_LIGHTING_BIT))
309 if(e==GL_LIGHTING && (
mask|GL_LIGHTING_BIT))
311 if(e==GL_LIGHT0 && (
mask|GL_LIGHTING_BIT))
313 if(e==GL_LIGHT1 && (
mask|GL_LIGHTING_BIT))
315 if(e==GL_LIGHT2 && (
mask|GL_LIGHTING_BIT))
317 if(e==GL_LIGHT3 && (
mask|GL_LIGHTING_BIT))
319 if(e==GL_SHADE_MODEL && (
mask|GL_LIGHTING_BIT))
322 if(e==GL_LINE_SMOOTH && (
mask|GL_LINE_BIT))
324 if(e==GL_LINE_STIPPLE && (
mask|GL_LINE_BIT))
327 if(e==GL_POINT_SMOOTH && (
mask|GL_POINT_BIT))
330 if(e==GL_CULL_FACE && (
mask|GL_POLYGON_BIT))
332 if(e==GL_POLYGON_STIPPLE && (
mask|GL_POLYGON_BIT))
335 if(e==GL_SCISSOR_TEST && (
mask|GL_SCISSOR_BIT))
338 if(e==GL_STENCIL_TEST && (
mask|GL_STENCIL_BUFFER_BIT))
341 if(e==GL_TEXTURE_1D && (
mask|GL_TEXTURE_BIT))
343 if(e==GL_TEXTURE_2D && (
mask|GL_TEXTURE_BIT))
345 if(e==GL_TEXTURE_3D && (
mask|GL_TEXTURE_BIT))
348 if(e==GL_NORMALIZE && (
mask|GL_TRANSFORM_BIT))
350 if(e==GL_RESCALE_NORMAL && (
mask|GL_TRANSFORM_BIT))
373vector<GLenum>::const_iterator iter = std::find(
m_Enabled.begin(),
m_Enabled.end(), glstate);
382vector<GLenum>::iterator iter = std::find(
m_Enabled.begin(),
m_Enabled.end(), glstate);
397vector<GLenum>::const_iterator iter = std::find(
m_Disabled.begin(),
m_Disabled.end(), glstate);
438GLsizei width, GLsizei height)
440 TVPRects(x, y, x+width, y+height);
493 ColorC(
CRgbaColor(
float(v[0]),
float(v[1]),
float(v[2]),
float(v[3])));
582GLenum srcAlpha, GLenum dstAlpha)
ncbi::TMaskedQueryRegions mask
CGlState Class to encapsulate Rendering state so that a set of user-selected GL state options can be ...
class CRgbaColor provides a simple abstraction for managing colors.
bool IsDisabled(GLenum glstate) const
Return true if option is in m_Disabled list for this state.
GLenum m_PolygonModeFace
parameters for glPolygonMode.
void Color4fv(const GLfloat *v)
virtual void MergeStates(CGlState &s, GLbitfield mask)
This is for pushing and popping states - retain state variables not included in the mask (as per glPu...
ELineJoinStyle
Enumerators for non-enumerated state values (e.g. pdf-only state values)
ELineCapStyle m_LineCapStyle
Cap (line terminator) style (effects pdf only)
virtual void PointSize(GLfloat s)
Set point size for drawing: glPointSize()
virtual void Enable(GLenum glstate)=0
virtual void PdfShadeStyle(EPdfShadeStyle s)
In (our) PDF files there are two kinds of polys, flat ones (move to, line to, fill) which can have an...
GLfloat m_PointSize
Point size (glPointSize())
virtual void PolygonMode(GLenum face, GLenum mode)
Set the polygon rasterization mode.
GLboolean m_ColorMaskGreen
virtual void Color3d(GLdouble r, GLdouble g, GLdouble b)
virtual void BlendFunc(GLenum sfactor, GLenum dfactor)=0
Options to be used when GL_BLEND is enabled.
virtual void ColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
Set the color mask (glColorMask)
bool m_ScaleInvarient
If true, object dimension are in pixels/points (not zoomable)
virtual void ScaleInvarient(bool b, CVect2< TModelUnit > scale=CVect2< TModelUnit >(TModelUnit(1), TModelUnit(1)))
Generic rendering options not specfically tied to OpenGL (or pdf..)
virtual void LineStipple(GLint factor, GLushort pattern)
Set line stipple pattern: glLineStipple(). Deprecated in gl 3.2+.
virtual void BlendColor(const CRgbaColor &c)
glBlendColor() - Optional constant color for blending
ELineJoinStyle m_LineJoinStyle
Joining style for adjacent lines (effects pdf only)
virtual void PointSize(GLfloat size)=0
Set point size for drawing: glPointSize()
I3DTexture * m_Texture
For now only allow 1 texture per object (no multi-texturing)
IRender & GetGl()
convenience function for getting current render manager
virtual void Color3fv(const GLfloat *v)
GLushort m_LineStipplePattern
CGlRect< TVPUnit > TVPRect
virtual void Enable(GLenum glstate)
glEnable() all options in m_Enabled
virtual void Scissor(GLint x, GLint y, GLsizei width, GLsizei height)
Set clipping window: glScissor(x,y,width,height)
virtual void Reset()
Resets the state back to the default one.
EPdfShadeStyle m_PdfShadeStyle
Pdf shading style (effects pdf only)
CRgbaColor m_BlendColor
Optional color to be used in blending (glBlendColor())
GLenum m_TargetAlphaFactor
virtual void LineWidth(GLfloat w)
Set line width for drawing: glLineWidth()
bool IsEnabled(GLenum glstate) const
Return true if option is in m_Enabled list for this state.
CRgbaColor m_Color
Current color (glColor())
virtual void LineCapStyle(ELineCapStyle c)
Set line cap ending style (pdf only)
virtual void BlendEquation(GLenum mode)
Options for glBlendEquation.
bool x_MergeFlag(GLenum e, GLbitfield mask)
helper function for MergeState that determines if a flag was masked
GLenum m_SourceRgbFactor
Blend factors for glBlendFuncSeparate.
virtual void Color3dv(const GLdouble *v)
CVect2< TModelUnit > m_ScaleFactor
Only needed for scale-invariant rendering (from CGlPane::GetScale()
void MakeCurrent(ERenderTarget target)
Set current options.
void GetLineStipple(GLint &factor, GLushort &pattern) const
ERenderTarget
Different api levels based on information from OpenGL driver.
void GetColorMask(GLboolean &red, GLboolean &green, GLboolean &blue, GLboolean &alpha)
virtual void Disable(GLenum glstate)
glDisable() all options in m_Disabled
GLubyte m_PolygonStippleMask[32 *32]
GLenum m_SourceBlendFactor
Blend factors for glBlendFunc()
virtual void Color3f(GLfloat r, GLfloat g, GLfloat b)
Set current color (glColor{3,4}{f,d})
virtual void SetTexture(I3DTexture *tex)
Allow 1 texture for now (no multi-texturing)
bool m_BlendFuncSeparateSet
GLenum m_ShadeModel
Shade model (GL_FLAT or GL_SMOOTH)
virtual void Color4dv(const GLdouble *v)
virtual void Color4f(GLfloat r, GLfloat g, GLfloat b, GLfloat a)
GLfloat m_LineWidth
Line width (glLineWidth())
GLint m_LineStippleFactor
glLineStipple(factor, pattern) Deprecated in OpenGL 3+
virtual void MakeCurrent()=0
GLboolean m_ColorMaskBlue
virtual void LineJoinStyle(ELineJoinStyle s)
PDF-specific rendering state.
CGlState()
Defaults are set to be the stated openGL defaults for those values.
virtual void ShadeModel(GLenum mode)
Set shade model for default lighting: glShadeModel(GL_FLAT or GL_SMOOTH)
virtual void Disable(GLenum glstate)=0
glDisable()
GLboolean m_ColorMaskRed
ColorMask.
virtual void Color4d(GLdouble r, GLdouble g, GLdouble b, GLdouble a)
virtual void BlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
Options for glBlendFuncSeparate, also enabled via Enable(GL_BLEND).
GLboolean m_ColorMaskAlpha
GLenum m_SourceAlpahFactor
virtual void LineWidth(GLfloat w)=0
Set line width for drawing: glLineWidth()
virtual void BlendFunc(GLenum sfactor, GLenum dfactor)
Options to be used when GL_BLEND is enabled.
virtual void Color4fv(const GLfloat *v)
vector< GLenum > m_Disabled
Set of all options to be disabled (glDisable())
bool m_Dirty
Set to false in MakeCurrent and true when any parms are updated.
TVPRect m_ScissorRect
Scissor rectangle.
virtual void PolygonStipple(GLubyte *mask)
Set polygon stipple pattern: glPolygonStipple(). Deprecated in gl 3.2+.
vector< GLenum > m_Enabled
Set of all options to be enabled (glEnable())
virtual void ColorC(const CRgbaColor &c)
GLenum m_BlendEquation
Blend equatnion for glBlendEquation()
GLenum m_TargetBlendFactor
float GetBlue(void) const
float GetGreen(void) const
float GetAlpha(void) const
const float * GetColorArray(void) const
Access the color array directly.
float GetRed(void) const
Get specific channels in floating point values.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
double r(size_t dimension_, const Int4 *score_, const double *prob_, double theta_)
int g(Seg_Gsm *spe, Seq_Mtf *psm, Thd_Gsm *tdg)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4