-
Notifications
You must be signed in to change notification settings - Fork 67
VariableTopologyMeshes loaders #4
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…bject. Set the texture_alpha uniform for meshes when rendering instead of in make_renderable, this wasn't a problem before since each object had its own instance of the shader. Also removed unused setting of transparency uniform in Webcam.render.
Also added sorting back to front for transparent objects based on distance to camera
Position, scale and color were not being set when preloading is disabled since meshes were not yet loaded. We now keep track of these properties and set them at load time.
Avoid recomputing the camera view-projection, light matrices and model matrices every time an object is used for rendering. This noticeably speeds up rendering with many objects.
get_projection_matrix() was returning the wrong matrix causing fragment picking to not work correctly.
Moved and unified the logic for drawing other render passes (shadows, fragmap and depth prepass) inside the Meshes class since now it needs to ensure that vertex buffers are updated.
- Prioritize jpegs over pickle files when high_quality is set in from_directory.
kaufManu
approved these changes
Jul 28, 2022
|
|
||
| // get closest depth value from light's perspective (using [0,1] range fragPosLight as coords) | ||
| float closestDepth = texture(shadow_map, projCoords.xy).r; | ||
| // float closestDepth = texture(shadow_map, projCoords.xy).r; |
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove unused code.
| # Transpose because np is row-major but OpenGL expects column-major. | ||
| prog['mvp'].write(mvp.T.astype('f4').tobytes()) | ||
|
|
||
| def make_pickable(self, vertex_buffer, index_buffer=None): |
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What happened with this function?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.