A question about textures and exporting
-
Ummm it could be more than just that, what type of image file are you using to texture your model and at what Rez is it?
-
What 'options' did you set in the FBX exporter dialog [bottom-right button...].
It must be 'checked' to include textures, which of course will mess you up if you expected them and it's 'unchecked' !
The texture image files [jpg/png etc] are put in a folder [named after the fbx file] which is with the fbx file.
You must keep them together; moving the fbx file away from its folder will result in its textures not being found, and plain colors being substituted... -
Here is an example of a simple object I'm trying to export.
In sketchup the textures are fine.
In unity they are blurred down to 1 color.
I am using .PNG and .JPG files for my textures, I insert the texture I want and then I right click > texture > position. 4 yellow pins appear and then I stretch the the texture to fit the face.
As for the post above mine, textures are enabled when exporting.
Thanks for the help
-
@tux24 said:
...I insert the texture I want and then I right click > texture > position. 4 yellow pins appear and then I stretch the the texture to fit the face...
I am not 100% sure that this is the problem but 3rd party apps often have problems with distorted materials in SU. Try to click on such a positioned material afterwards and "Make texture unique". This will make sure it is a rectangular image.
-
You have not yet confirmed that your FBX export options are set to include textures... and if so, that a folder is being made containing these image files... and that if so, you are keeping that folder and the FBX file together when importing it into another application and you are also telling that application to import any textures...
-
The texture is importing into unity, that's clear but what G and I said that other outside apps are not compatible with distorted textures, I import my models into unity also and I had the same problem at first, stretching the texture is distorting the texture, the only pin you can adjust us the green pin to rotate the texture but bare in mind you must keep the texture the same scale when doing so, adjusting the textures scale is also distorting the texture
-
How are you sure the texture is importing?
If the texture is distorted than unique_texture files of the distorted version should be in the folder...
A textured-material can be re-positioned, rotated and scaled, and still only needs 3 vertex normals to set it in all apps that I know of.
BUT if a textured-material has been otherwise UV-mapped, so it's distorted/skewed/perspectivized etc in the SKP then it needs 4, and virtually all export formats only use 3, as that the number of points in a triangular facets. To overcome this several exporters leave the face's UV-mapping as 'normal' but export a distorted version of the texture-image file instead, so it appears right in the exported version using 3 vertices...It might well be that your app can't cope with vertex mapping other than the simplest... but I'd be surprised.
If it is failing the texture would still be there even if badly distorted, the gray used looks more like the default RGB color rather than the actual texture - that's why I suspect the missing image-files...
Have you tried something like 'TextureRotate' toolset - which despite its name, lets you rotate/position/scale a selected texture by fixed amounts or by using the arrow keys to 'nudge nu fixed increments.... this means that only the simplest kinds of UV-remapping is done and there's no distortion by accidentally using the wrong editor pin etc...So are the textures getting exported, are there distorted ones etc ?
-
@TIG textures are enabled on export, the textures are in the correct file location.
I just looked up a video on youtube, it was a guy creating a simple house and exporting it to unity. I decided to do a test and to create the exact same house and use the exact same textures (without stretching/altering them in any way) I imported it in to unity and same problem.
The guy in the video did not get that problem.
Is it possible my laptop is not powerful enough to handle it? I don't think so, my laptop is only about 1 year old, 4g ram ect - not the best but it should be able to do these simple tasks.
-
OK, it looks like the Sketchup texture side is working fine...
The Unity side isn't working.
This needs questions on the Unity forums...
For example is there as Unity setting to import 'with/without textures' ?A brief Google search shows several people with similar/related issues...
One cause mentioned is that the FBX has to be an editable mesh to take the textures.
I guess that this might mean it must be 'triangulated'.
This is one of the Options in the FBX exporter's settings.
Also is your SKP model near to the origin?
I have heard that Unity doesn't like importing stuff miles away from 0,0,0...Another frequently mentioned issue... '[FBX into Unity]...textures will be applied automatically only if they're in the main "Assets" folder. Otherwise [you] have to assign then manually [from the FBX's texture-folder].'
So have you tried copying the texture files into your Unity project's 'Assets' subfolder
OR, have you tried importing the textures from their subfolder and then importing the FBX, so it then finds and uses them ?This is all Unity stuff - not Sketchup ...
This is also interesting... http://www.mat-d.com/site/how-to-export-from-blender-to-unity-3d-with-textures-tutorial/ look from Step 4... it explains how to 'bake' the materials into a copy of the FBX file itself [using a free converter] before importing it... This is so that Unity is given the textures inside the FBX and so Unity doesn't have to find them, or be pointed at them manually...
It is a Blender tutorial, but just skip over the parts until you have an FBX file and a folder of textures from your SKP... Also as hard-copy... http://www.mat-d.com/site/wp-content/uploads/blender_unity_tutorial_files.zip -
@TIG thank you for going the extra mile with this, I really appreciate it
Triangulating the surfaces didn't work, I haven't tried any of the other methods you suggested but I will certainly look into them.
And thanks to everyone else
If I manage to fix this issue, I'll be sure to post the solution in case someone else posts the same question.
-
I realise this is a few years old, just been looking for a similar solution. Have found this and will try tonight.
https://www.linkedin.com/pulse/importing-models-unity-3d-from-google-sketchup-muhammad-faizan-atiq
Advertisement