Download

Online

Gallery

Blog

  Index  | Recent Threads  | List Attachments  | Search
 Welcome Guest  |  Register  |  Login
Login Name  Password
 

Sweet Home 3D Forum



No member browsing this thread
Thread Status: Active
Total posts in this thread: 2
[ Jump to Last Post ]
Post new Thread
Author
Previous Thread This topic has been viewed 1135 times and has 1 reply Next Thread
stain35
Newbie




Joined: Apr 28, 2020
Post Count: 10
Status: Offline
Reply to this Post  Reply with Quote 
Issue with object files import

I realise that there are several threads for this subject but I haven't found anything that solved my issue.

I have Obj files I have created in Blender myself, some Blend files I have downloaded as Blender files from Sketchfab plus some that I have downloaded from places such as CG Trader.

So they are either object files to start with or exported from Blender.

I have mtl files created alongside the object. I have even, in one instance, edited the obj file to have the absolute path of the mtl file.

However, none of these are imported into SH3D successfully as furniture with the materials attached. They are always just the object itself, no colours.

I have considered zipping these together, to see if that remedies the issue, but not sure if this is a standard zipfile or needs specialist obj file zipping processes.

An example of an mtl file and obj file in text format is below (note these are in the same folder). I will follow the rules and credit the originator:

"Amazon Echo" (https://skfb.ly/6npGF) by Eternal Realm is licensed under Creative Commons Attribution (http://creativecommons.org/licenses/by/4.0/).

AmazonEcho.mtl:

# Blender MTL File: 'echo.blend'
# Material Count: 5

newmtl base
Ns 225.000000
Ka 1.000000 1.000000 1.000000
Kd 0.800000 0.800000 0.800000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2

newmtl blue
Ns 225.000000
Ka 1.000000 1.000000 1.000000
Kd 0.800000 0.800000 0.800000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2

newmtl dot
Ns 225.000000
Ka 1.000000 1.000000 1.000000
Kd 0.800000 0.800000 0.800000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2

newmtl gray
Ns 225.000000
Ka 1.000000 1.000000 1.000000
Kd 0.800000 0.800000 0.800000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2

newmtl white
Ns 225.000000
Ka 1.000000 1.000000 1.000000
Kd 0.800000 0.800000 0.800000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2


AmazonEcho.obj (just the first few lines - note did try with absolute mtl file path):

# Blender v2.93.1 OBJ File: 'echo.blend'
# www.blender.org
mtllib AmazonEcho.mtl
o echo_Circle.086



I have a link to full obj file but unsure as to whether I can add that for Sketchfab copyright reasons. However, it is free to download there.
[Nov 20, 2021, 1:56:31 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Puybaret
Expert
Member's Avatar

France
Joined: Nov 7, 2005
Post Count: 9176
Status: Offline
Reply to this Post  Reply with Quote 
Re: Issue with object files import

Your MTL file actually describes only grey colors (Kd R G B values are the same!).
Try to change them, for example Kd 0 0 1 for blue.
This must be because of the way colors are defined in Blender.
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D developer
[Nov 20, 2021, 4:07:21 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
[ Jump to Last Post ]
Show Printable Version of Thread  Post new Thread

    Get Sweet Home 3D at SourceForge.net. Fast, secure and Free Open Source software downloads
   
© Copyright 2006-2024 eTeks - All rights reserved