Forum Discussion
waynecochran
8 months agoProtege
How to enable / disable mipmaps when creating a SceneTexture from a Bitmap?
I don't see a SceneTexture constructor that takes a bitmap as an argument AND disables or enables mipmapping.
val samplerConfig = SamplerConfig(
mipmapMode = Filter.NEAREST,
minFilter = Filter.NEAREST,
magFilter = Filter.NEAREST,
addressModeU = AddressMode.CLAMP_TO_EDGE,
addressModeV = AddressMode.CLAMP_TO_EDGE,
lodBias = 0.0f
)
val myTexture = SceneTexture(myBitmap, samplerConfig)Are mipmaps auto always generated here? Is there anyway to control this (e.g., what if I don't want mipmapping)?
Other SceneTexture constructors have a `numberOfMips` argument, but none of those take a Bitmap as an argument. Perhaps this is controlled at the SceneMaterial level, but I don't see anything concerning mipmaps there.
1 Reply
Replies have been turned off for this discussion
- dav-sMeta Employee
Hi!
Right now when creating a SceneTexture, there are roughly log2 levels of mipmaps generated for any bitmap created and there is no current way to customize that.
The lodBias in the sampler should let you customize which levels are used for sampling but loading from the Bitmap will currently always generate the levels.
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 6 months ago
- 29 days ago
- 25 days ago
- 10 months ago