- Home /
Can't assign texture to .obj imported from Blender
I'm working on a mac with blender 2.69 and exporting .obj to create mesh assets for my game.
Everything is working fine except for when i try to assign a material to the object.
I select the object on the hierarchy then change it's material from the Mesh renderer component. The mesh changes material but it doesn't display the texture of that material. Only the shader color.
I tested with several textures, default grass texture from unity and some of my own. I also used other file format: .fbx.
Everything works fine when i use cubes or spheres created directly in Unity.
My colleagues are working with 3ds max and no error occurs with the .obj and .fbx they export.
Am I doing something wrong or is this a blender related problem? How can i solve this?
Did you assign your UV map to the $$anonymous$$aterial? Do you have a UV map?
I just export a plain(no material, no textures) cube from blender to unity and when i assign a material to it on Unity it doesn't show the texture but only the plain image color of said image texture.
Example: I assign a default grass texture from Unity to an object imported from blender. Only green shows up.
I assign a grass texture to a cube made in unity. Everything works fine.
I will still give it a try though.
I confirmed the same w/ obj/fbx basic cube no material/texture/etc from Blender to Unity...but if all you want is a cube why go through this? And if your $$anonymous$$esh will be more complicated then you'll have a UV map.
It worked! Thank you.
Still, it seems a little bit messy for more complex objects… I will have to unwrap complex objects just to be able to add simple textures?
Any advice on a less time consu$$anonymous$$g solution?
Answer by getyour411 · Apr 03, 2014 at 01:01 AM
I'm still learning the basics myself but I think that's pretty much the way it works, otherwise the 2D Texture has no way to know to align to the 3D coordinates. There are some spiffy ways of doing things via code but that's out of my league.
I'll put this as an Answer.
Fair enough. I accept this answer.
Thank you for your trouble.
P.S: i just worked with cubes to pave the way for more complex meshes. Starting simple and building on top of it.
Yeah I've spent the last hour fiddling around with this and can't make the imported Cube show a texture either so I don't know how Unity default cube is doing it unless it has some some magic behind the scenes stuff.
Your answer
Follow this Question
Related Questions
Blender Rigify humanoid animation importing into Unity with SIDEWAYS feet 0 Answers
Importing "advanced" materials from Blender into Unity? 2 Answers
Unity breaks animation from Blender 1 Answer
Prefab Color Question 1 Answer
Is it possible to export from a blender to a format that Unity uses in a MeshFilter? 1 Answer