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

Fix mipmaps for 90% #68

Merged
merged 7 commits into from
Jan 23, 2021
Merged

Fix mipmaps for 90% #68

merged 7 commits into from
Jan 23, 2021

Conversation

Displee
Copy link
Contributor

@Displee Displee commented Jan 8, 2021

I wasted a week on fixing mipmaps. You're not going to believe the fix 😡

However, there seems to be an issue with MeshLambertMaterial. When using that in the mipmaps example the mesh becomes black, but when using MeshBasicMaterial the textures work. Somehow MeshLambertMaterial is being treated differently.

I tried to update the MeshLambertMaterial class and set the default values like threejs does in r106, but I had no luck yet.

Forgive me for my useless "merge pull request" commits xD.

Add window favicon and update Kotlin to 1.3.72
Merge with threekt master
Add multi material ray intersecting for indexed and non-indexed buffe…
@Displee
Copy link
Contributor Author

Displee commented Jan 8, 2021

I added the kotlinx-io dependency because it's required for a Texture object to have a non-nulled image in order for it to render anything. Maybe you can add an EMPTY_IMAGE constant in the Texture class or something so you don't need the dependency in the examples module. What's your opinion on this matter?

@markaren
Copy link
Owner

I'm a little sidetracked at the moment. I promise to look at this next week!

@markaren
Copy link
Owner

Aight, I had a look. There was clearly a wrong use with texImage2D that you spotted. Good job.
For the MeshLambertMaterial case, simply add a light source :D

@markaren markaren merged commit bd26222 into markaren:master Jan 23, 2021
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.

None yet

2 participants