Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
acgl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ACGL
acgl
Commits
50edd1df
Commit
50edd1df
authored
13 years ago
by
Robert Menzel
Browse files
Options
Downloads
Patches
Plain Diff
added comments for temporary test code
parent
b565ccfc
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
include/ACGL/OpenGL/HiLevelObjects/RenderObject.hh
+15
-6
15 additions, 6 deletions
include/ACGL/OpenGL/HiLevelObjects/RenderObject.hh
with
15 additions
and
6 deletions
include/ACGL/OpenGL/HiLevelObjects/RenderObject.hh
+
15
−
6
View file @
50edd1df
////////////////////////////////////////////////////////////////////////////////
// Copyright (c) 2011, Computer Graphics Group RWTH Aachen University
//
// Copyright (c) 2011,
2012
Computer Graphics Group RWTH Aachen University //
// All rights reserved. //
////////////////////////////////////////////////////////////////////////////////
...
...
@@ -102,7 +102,12 @@ public:
}
//! testing
// ==================================================================================================== \/
// ==================================================================== TESTING WAYS TO STAY COMPATIBLE \/
// ==================================================================================================== \/
public
:
//! for testing only: the new enable/disable/render sets store the old GL states, so they can't be const
//! some old code works with const RenderObjects. don't rely on this function anymore
inline
void
enableC
()
const
{
if
(
mpFrameBufferObject
)
...
...
@@ -125,22 +130,25 @@ public:
}
}
//! testing
//! for testing only: the new enable/disable/render sets store the old GL states, so they can't be const
//! some old code works with const RenderObjects. don't rely on this function anymore
inline
void
disableC
()
const
{
glBindVertexArray
(
0
);
}
//! draws the VAO, everything needed for drawing is performed by this call, has side effects, just for compatibility / testing
//! for testing only: the new enable/disable/render sets store the old GL states, so they can't be const
//! some old code works with const RenderObjects. don't rely on this function anymore
inline
void
renderC
()
const
{
enableC
();
draw
();
disableC
();
}
// ==================================================================================================== \/
// ============================================================================================ METHODS \/
// ==================================================================================================== \/
private
:
void
enableFrameBufferObject
();
void
disableFrameBufferObject
();
...
...
@@ -163,6 +171,7 @@ protected:
ConstSharedFrameBufferObject
mpFrameBufferObject
;
// optional
ConstSharedViewport
mpViewport
;
// optional
//! old states so render() can be side-effect free
Viewport
mLastViewport
;
GLint
mLastShaderProgram
;
GLint
mLastFBO
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment