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

02 Combined Image Sampler does not explicitly state fragment shader changes #55

Open
d-hain opened this issue Jan 9, 2025 · 1 comment

Comments

@d-hain
Copy link

d-hain commented Jan 9, 2025

I the Texture Mapping/Combined image sampler chapter it doesn't state anywhere to change the fragment shader back to only containing outColor = texture(texSampler, fragTexCoord); in its main function.
This is not a problem until the Loading models chapter where the model will look very wrong as a result of the fragment shader still having the following main function:

void main() {
    outColor = vec4(fragColor * texture(texSampler, fragTexCoord).rgb, 1.0);
}

It would be nice to add that either after the texture color changing example or somewhere in the Loading models chapter just to avoid confusion.

@SaschaWillems
Copy link
Collaborator

Thanks. I'll try to improve this.

But in general all chapters come with full sources (see links at the bottom of the chapter) where you can see how the code should look like. For the chapter you mentioned, said fragment shader code has the correct code.

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

No branches or pull requests

2 participants