Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
2 captures
13 Jun 22 - 14 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
2
Question by citycrusher · Apr 10, 2012 at 05:36 AM · renderingmipmaps

How do you use mipmaps?

Mipmaps just seem to make everything look really bad so i always keep them unchecked. Is there a correct way of using them that doesn't just totally trash your graphics?

I'm assuming I just don't know how to make use of them! What I find is any way I play the mipmaps they just look like junk.... but they must have a sensible function. I'm interested in tightening up my rendering so I want to learn how to use them properly... I know they can make rendering much lighter.

my question is... how to implement mipmaps nicely?

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image citycrusher · Apr 10, 2012 at 03:52 PM 0
Share

thanks for your answer! not seeing any artifacts, but i found what was going on to destroy mipmaps. i had quality setting at 1/8 res. once i set quality to full res, mipmaps worked more as expected, nicely fading out in distance.

however my builds today with mipmaps, the graphics was not significantly better & it ran about 5 fps slower then without. seems in my current game project mipmaps have no place, but now that i know what's going on, i'll keep them in $$anonymous$$d for future projects!

2 Replies

· Add your reply
  • Sort: 
avatar image
5
Best Answer

Answer by Eric5h5 · Apr 10, 2012 at 06:59 AM

You should always have mipmaps checked if you're using 3D, because otherwise you get awful artifacts when the camera moves, plus it runs faster since it doesn't have to calculate so many pixels for distant objects. Other than looking slightly blurry compared to not having mipmaps, there shouldn't be any downsides, and the slight blurriness is more than compensated for by the lack of flickering texture artifacts. You can use trilinear filtering so that the transition between mipmap levels is smooth. If you have any serious degradation with mipmaps, that's not normal and maybe you need to update your drivers or something.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image cregox · Apr 16, 2013 at 10:39 PM 0
Share

Additionally @citycrusher, toy with `Aniso Level` and `Filter $$anonymous$$ode` for better / more expensive results. Worked for me! ;)

avatar image
3

Answer by Max_Bol · Aug 27, 2018 at 03:49 PM

There's not a clear an fixed answer to this question because it's always depends on the project itself.

.

The general rule is as following:

.

You need Mipmaps if...

Your asset might have a different level of details rendered on a screen at the same time. For example, if you got some generic props for the background that are repeated at many places in the screen (close to the camera as well as far from it), those asset will require mipmaps if you want to optimize the amount of memory used per-asset as well avoiding pixel artifacts when the rendering pipeline is forced to cut out 2/3 of the pixels of the texture as the asset is way too far in the background for it to display every details on its surface. You might also need mipmaps if you use any kind of LOD that uses the same texture between each layer of LOD.

.

You don't need Mipmaps if...

If your assets are always displayed from the same range and you don't allow the player to zoom in. This is the case for games like 2.5D isometric view games (like Diablo-style) in which the player can't zoom-in and might also be the case of some of the assets in a game with very limited depth visibility such as a a game focused on sidescrolling for its movement. A game like Little Nightmares doesn't need mipmaps for example because the level of details between the background assets and the forth assets doesn't really maters as it's mostly the same due to the game limited depth interactivity (meaning you mostly move on a 2 axis with limited depth-based movement toward the Z axis) In such cases, you need to control the source files directly by testing and attributing the right resolution to the assets' texture and settings. (In those case, the trick is usually to start with a 2K texture and, in Unity, drop the Max Size of the texture until it gets too ugly from the actual gameplay camera view. It's not rare that you can drop by half or even at a 1/4 a couple of textures as the impact is almost not noticeable unless you know about it. When you build the game built, the textures will get resized automatically based on the Max Size setting.)

.

The rule is usually a per-asset rule meaning that you got to think the same question for each texture. For example, if you're making a Metroidvanilla styled game where you can have a far-off view in the background that includes assets (such as rocks or trees) you also use close to the camera, those will mostly require mipmaps. On the other hand, if you got some walls and some props (like animated doors) that never appears far from the camera (like the assets used in a part underground), those don't need mipmaps at all and you should avoid those at all cost! Another example in a more mainstream kind of game would be a FPS. Your player's arms which mostly floats in the air... as well as your player model (if unique) doesn't need any mipmaps. They are only seen from up close so you don't need to allow the engine to waste any resources that would allow it to display a less-then-required level of details. Enemies that might appears over 100m away will requires mipmaps.

.

Now, one of the most asked question is about how to avoid mipmaps to look ugly. There are multiple possibles reasons for a mipmaps to look ugly or visually create artifacts on the textures.

  1. The mipmaps settings are wrong. Obviously, if the settings are wrongs, the result will be wrong.

  2. The model's UVs aren't properly set. This is the less obvious part that might make you hate yourself now and then. The general rule for the UVs of the model to be properly setup with mipmaps is to avoid having UV seams anywhere near important details in the model's texture. If you got some emissive bits on your model, makes sure there are no seams close to those emissive bits. Otherwise, you might be forced to turn mipmaps off from the emissive texture as it will make the seams visible from a mile away once the mipmaps kicks in.

  3. Use clamp and avoid repeat wrap mode. Repeat wrap mode is basically when you need the texture to loop so that you can use extend and use the same part of the texture multiple times through its UVs. For example, a fence's texture might use Repeat Wrap mode to allow a relatively high level of details while keeping the texture size small. Such things works really badly with the mipmaps as the Repeat wrap Mode might generate artifacts in the alpha channel which end up displaying seams in-between the tiled texture. For such things, instead, you should use a Clamp Wrap mode and, in the model and its UVs, manually set the faces/vertex so that it repeat within the UVs bounds.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image warmanw · Jul 17, 2019 at 08:15 AM 0
Share

Very nice explanation @$$anonymous$$ax_Bol . Can you also clarify one question. I have checked with Adreno that mipmaps are actually placed in the same texture. so the question is if we have 100 textures and each increase their size somewhere 1.3 times. that is actually a real down side. no?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

8 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

iOS: Specify Top Level Texture Mipmap 0 Answers

Why the object is pixelated in build? 1 Answer

Mipmap view not working in editor. 0 Answers

How to disable mipmaps? 1 Answer

Floor - aliasing 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges