Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GSoC 2023: Create VertexStateManager #4675

Merged
merged 11 commits into from Jul 25, 2023

Conversation

jbinvnt
Copy link
Contributor

@jbinvnt jbinvnt commented Jun 21, 2023

VertexStateManager is a class for holding common logic used by multiple renderer classes. This reduces duplicate code and is expected to provide a single place where future changes to OpenGL operation will propagate across different types of renderers.

The intended use case for this class is to be a drop-in replacement for logic that currently makes certain rendering functions long and redundant. Therefore VertexStateManager objects are initialized with references to stack objects. This means that lifetime of a vsm should be limited to the scope of the function in which it is created.

Future refactoring might repurpose VertexStateManager into a larger hierarchy of classes. For now though, its goal is to accelerate ongoing investigation of OpenGL modernization by allowing the multiple rendering modes to share individual functions.

This pull request does not introduce any functional changes to the codebase. More PRs will follow for Google Summer of Code 2023.

src/glview/VertexStateManager.h Outdated Show resolved Hide resolved
src/glview/VertexStateManager.h Outdated Show resolved Hide resolved
src/glview/VertexStateManager.cc Outdated Show resolved Hide resolved
src/glview/preview/OpenCSGRenderer.cc Show resolved Hide resolved
@jbinvnt jbinvnt force-pushed the gsoc-2023-create-vsm branch 2 times, most recently from 5d23d29 to 20b3978 Compare July 9, 2023 19:13
@jbinvnt jbinvnt marked this pull request as ready for review July 9, 2023 22:40
Copy link
Member

@kintel kintel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good once my comments are addressed. I might not be around to approve it, but @t-paul can do a final check.

src/glview/preview/ThrownTogetherRenderer.h Outdated Show resolved Hide resolved
src/glview/VertexStateManager.cc Show resolved Hide resolved
src/glview/VertexStateManager.cc Show resolved Hide resolved
src/glview/VertexStateManager.h Outdated Show resolved Hide resolved
src/glview/VertexStateManager.cc Show resolved Hide resolved
@t-paul t-paul merged commit fba1ea3 into openscad:master Jul 25, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants