Skip to content

Conversation

@thibka
Copy link

@thibka thibka commented Nov 21, 2025

Fix a small typo in the documentation. The default value for anisotropy is 1, not 0.

@mrdoob
Copy link
Owner

mrdoob commented Nov 21, 2025

The docs are now auto generated. You should fix this instead:

/**
* The number of samples taken along the axis through the pixel that has the
* highest density of texels. By default, this value is `1`. A higher value
* gives a less blurry result than a basic mipmap, at the cost of more
* texture samples being used.
*
* @type {number}
* @default 0
*/
this.anisotropy = anisotropy;

But... To be more correct, it should say the the default value is Texture.DEFAULT_ANISOTROPY 🤔

@Mugen87
Copy link
Collaborator

Mugen87 commented Nov 21, 2025

Indeed. Let's use Texture.DEFAULT_ANISOTROPY. The ctor parameter is already documented that way.

I believe when I initially wrote this JSDoc, I wasn't sure if using Texture.DEFAULT_ANISOTROPY with the @default tag produces a parsing error. But I've tested it now and turns out it works just fine.

@mrdoob mrdoob added this to the r182 milestone Nov 22, 2025
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