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

LineMaterial: Refactor GLSL. #22726

Merged
merged 3 commits into from
Oct 25, 2021
Merged

LineMaterial: Refactor GLSL. #22726

merged 3 commits into from
Oct 25, 2021

Conversation

Mugen87
Copy link
Collaborator

@Mugen87 Mugen87 commented Oct 25, 2021

Related issue: https://discourse.threejs.org/t/warning-output-of-vertex-shader-worldstart-not-read-by-fragment-shader/31125

Description

Depending on how LineMaterial is configured, the following warnings can occur:

THREE.WebGLProgram: Program Info Log: WARNING: Output of vertex shader 'worldStart' not read by fragment shader
THREE.WebGLProgram: Program Info Log: WARNING: Output of vertex shader 'vUv' not read by fragment shader

The PR fixes these warnings by introducing some #ifdef statements so varyings are only defined if they are actually required.

@WestLangley
Copy link
Collaborator

/ping @gkjohnson

Copy link
Collaborator

@gkjohnson gkjohnson left a comment

Choose a reason for hiding this comment

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

Awesome -- thank you!

@Mugen87 Mugen87 added this to the r134 milestone Oct 25, 2021
@Mugen87 Mugen87 merged commit 431baa0 into mrdoob:dev Oct 25, 2021
@mrdoob
Copy link
Owner

mrdoob commented Oct 26, 2021

Thanks!

@bernhard-42
Copy link

@Mugen87 Thanks a lot, this was really fast - it's already part of r134!

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.

5 participants