Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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
1
Question by Monopowaa · May 11, 2018 at 01:51 PM · shadersblendermaterialsimported

Lightweight shader doesn't properly apply to blender imported GameObjects

Hi !

Unity 2018.1 is out. I have created fresh shaders with the new Shader Graph tool. So far, it's very cool ! Next, I have created a new material to try out my new shader. All good so far. Finally, when I drag & drop my material on a freshly made Unity cube GameAsset, it works fine !

But when I drag & drop my material on a very basic asset I created & imported from Blender, the material from my fresh shader does NOT work. WHY ?

Here is a screenshot: - On the right, a cube with the working material. The cube is a basic Unity cube GameAsset. - On the Left, my game Asset on which I apply the very same material (on the turret & shield child objects - obviously not on the canon). It doesn't render properly.

alt text

Regarding technical questions :

  • This is under Unity 2018.1.0f2

  • The graphics parameters I have set are the "LightWeightPipelineAsset" (Edit -> Project Settings -> - Graphics -> Lightweight Pipeline Asset").

  • The Lightweights pipeline is installed via the Asset Manager and works fine.

  • The shader I created for my material is a PBR-type (Right click -> Create -> Shader -> PBR Graph)

  • I have tried the importing settings for the tank turret as "Import materials" unchecked. (I tried with checked too by the way..)

  • The imported item comes from Blender.

Here is the "graphical architecture" of my shader (very basic)

alt text

Has anyone an idea why it doesn't work on imported gameObjects ?

Cheers !

shader-issue.jpg (232.5 kB)
shadertest.jpg (90.7 kB)
Comment
Add comment · Show 3
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 Glurth · May 11, 2018 at 02:02 PM 0
Share

$$anonymous$$ay I suggest you use a different texture when testing your shader. Here is a google image search for "test texture mapping" just click and pick.

The advantage to using images like these for your shader texture are, they enable you to see issues with UV mapping clearly and quickly (which is where I suspect the problem lies, though not sure why)

avatar image Monopowaa Glurth · May 11, 2018 at 04:05 PM 0
Share

HI ! thanks for the fast reply.

It doesn't look like this is the issue. See screenshot below.

alt text

untitled.jpg (150.4 kB)
avatar image Glurth Monopowaa · May 11, 2018 at 04:42 PM 1
Share

I would disagree and say this appears to confirm UV mapping is the issue! I would suggest at this point you take a look at the mesh's UV array, at runtime, and Debug.Log it to the console. I'd bet that you will see all the same value for every element in the array. You can access the UV array using: (uncomplied, example only)

  Vector2[] meshUVs = gameObject.GetComponenent < $$anonymous$$eshFilter >.shared$$anonymous$$esh.uv;

Alas, I still can offer no specific advice on resolving it. (thus a comment, not an answer)

1 Reply

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

Answer by Kciwsolb · May 11, 2018 at 05:43 PM

I am going to ask the obvious here for my answer, but we all forget sometimes so it is worth asking. Did you UV unwrap your imported object in Blender? If an object is not UV unwrapped, it will appear as one solid color. If it is not unwrapped, do so in Blender.

Comment
Add comment · Show 3 · 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 Monopowaa · May 11, 2018 at 07:16 PM 0
Share

You guys are both right... I simply forgot my UV unwrapping !!!

$$anonymous$$illion thanks... I was looking somewhere else and would never have found it !

avatar image Glurth Monopowaa · May 11, 2018 at 08:54 PM 0
Share

Ah! Glad someone who actually knows Blender chimed in ;)

avatar image craig4android · Jun 10, 2019 at 08:17 PM 0
Share

dude, wtf!!!! $$anonymous$$e too

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

104 People are following this question.

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

Related Questions

FBX Model Shading Become Metallic When Rigging Is Enabled 0 Answers

Unity not importing materials from blender. 0 Answers

Shader for highlighting on mouse over, multiple shaders or property on shader? 0 Answers

Problem with model import and materials/uv 0 Answers

How to make a Diffused Shader on top of a Vertex Shader? For Billboard Sprites to show in front of 3D Meshes. 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