Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Repeating textures not working.

Discussion in 'Editor & General Support' started by tlemo_, Dec 22, 2018.

  1. tlemo_

    tlemo_

    Joined:
    Dec 22, 2018
    Posts:
    5
    Hello! I've been having a problem. upload_2018-12-21_16-44-9.png
    The texture I'm using for a project is stretching, along with all of the other textures. I've searched the internet for answers, but to no avail. As you can see in the image, I'm also using post-processing.

    I am looking for answers with none of the following.
    • Questions that tell me to change to repeat. I already have repeat on, please do not tell me to turn it on.
    upload_2018-12-21_16-49-29.png
    • Questions that tell me to increase the tiling. It may fix one block, but it messes up the texture on other sides (if it's not a cube) along with the rest of the blocks.
    • Scripting, especially long scripting or intermediate terms. I'm very new to unity and won't understand.
    Thanks!
    - RebelRuby89​
     

    Attached Files:

  2. kdgalla

    kdgalla

    Joined:
    Mar 15, 2013
    Posts:
    4,386
    Are using Unity's default cube and scaling it? Scaling the cube does not change the cube's underlying UV map, so if you scale the cube, it will stretch the texture accordingly. Also, you've already noticed that it doesn't make sense to change the material tiling if you have multiple objects that use that material and require different tiling. Rather, you either need each object to have a UV mapping for it's tiling, or use a shader that does not rely on the model's UV coordinates (like a world-space coordinate shader).

    Instead of using the cube, You could try Probuilder to build your level. Then you could build in such a way that it will tile the UVs as you build.

    As for shaders, there is a world-space texture mapping shader included in the demo scenes that are included in the standard assets. That's the shader that draws the grid-pattern on the level geometry.
     
  3. tlemo_

    tlemo_

    Joined:
    Dec 22, 2018
    Posts:
    5
    Yes.
    Hmm...
    I never heard of Probuilder before. I looked it up, and it looks awesome! I'll definitley try it out.