Skip to content

Conversation

@ramenguy99
Copy link
Collaborator

No description provided.

ramenguy99 and others added 28 commits July 18, 2022 15:48
…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 kaufManu self-requested a review July 28, 2022 19:21

// 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;
Copy link
Contributor

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):
Copy link
Contributor

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?

@kaufManu kaufManu merged commit 909f1f5 into main Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants