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: 17
Posts: 17   Pages: 2   [ Previous Page | 1 2 ]
[ Jump to Last Post ]
Post new Thread
Author
Previous Thread This topic has been viewed 6876 times and has 16 replies Next Thread
ninja592
Newbie




Joined: Aug 23, 2020
Post Count: 9
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

Interesting... this is what the PluginFurniturecatalog.properties for the modified version shows:

#
# PluginFurnitureCatalog.properties Sun Aug 23 12:54:54 EEST 2020
# Generated by Furniture Library Editor
# id=SweetHome3D#BlendSwap-CC-0-Models
name=Blend Swap CC-0
description=Blend Swap models Public domain
version=1.7.1 license=Public domain
provider=www.sweethome3d.com


What I also noticed is that my 2 test objects, the chicken and the iPhone show up correctly in the file:

id#85=Blend Swap CC-0#chicken
name#85=Chicken
tags#85=Blend Swap, Animal
creationDate#85=2016-02-10
category#85=Animals
icon#85=/Chicken.png
model#85=/Chicken/chicken.obj
multiPartModel#85=true
width#85=24.2
depth#85=32.8
height#85=45.6
movable#85=true
doorOrWindow#85=false
modelSize#85=204809 creator#85=CDmir230


id#64=Blend Swap CC-0#iphone
name#64=iPhone
tags#64=Electronics
creationDate#64=2013-09-05
category#64=Electronics
icon#64=/iPhone.png
model#64=/iPhone/iphone.obj
multiPartModel#64=true
width#64=5.8
depth#64=11.5
height#64=0.9
movable#64=true
doorOrWindow#64=false
modelRotation#64=1 0 0 0 0 1 0 -1 0
modelSize#64=69053
creator#64=Bheema


So the entries in the file look correct, but when I import the .sh3f file into SH3D, they show up incorrectly.

I'm not sure if I understand your second question. What I did with the libraries was:
- download zip file to external drive
- unzip file to external drive
- make modifications via FurnitureLibraryEditor-1.25.jar
- save modified file with a different name on external drive
- double-click modified .sh3f file to import it into SH3D
[Sep 8, 2020, 10:54:30 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
harbinger
Member
Member's Avatar

US
Joined: Feb 27, 2014
Post Count: 87
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

Ok, maybe we're getting somewhere.
It seems that FLE should be renumbering the entries when saving, and SH3D's reader expects to start at entry #1. I've added, subtracted, and renumbered quite a few entries in all my SH3F files, but they always get listed in numerical order, starting with #1.

Renumber your two entries so that they are listed as #1 and #2 (instead of #85 and #64), and make sure that the edited .properties file is in its correct place in the furniture folder hierarchy, and pull up SH3D again.
EDIT: also remove the # in front of the ID line, so that it reads:
id=SweetHome3D#BlendSwap-CC-0-Models
SH3D may need that ID line, but the # renders it as a comment line.

Does this fix it?
----------------------------------------
[Edit 1 times, last edit by harbinger at Sep 8, 2020, 4:49:29 PM]
[Sep 8, 2020, 4:43:12 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
harbinger
Member
Member's Avatar

US
Joined: Feb 27, 2014
Post Count: 87
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

Ok, I can verify the problem is not with the numbering. I opened CC-0 with FLE, added and applied a new category to one furniture entry, saved it with the same path name, opened the modified .properties file and verified the category for that entry was indeed changed, opened the SH3F file in SH3D, and saw that the new category was not applied. IOW, I replicated ninja's problem.

Doing further testing....
[Sep 9, 2020, 5:16:32 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
harbinger
Member
Member's Avatar

US
Joined: Feb 27, 2014
Post Count: 87
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

GOOD NEWS!

I figured out the problem. I thought it was odd that the ID of each entry in the .properties file contained the name of the BlendSwap file within the ID, but this wasn't the case for the other sh3f .properties files. So on a hunch, I took that out of the ID text and left the id name, checked it in SH3D, and sure enough that was the problem.

So here's how you fix it:
1. Open BlendSwap-CC-0.sh3f with 7-zip, or some other decompression program.
2. Extract the file PluginFurnitureCatalog.properties onto your desktop.
3. Open the file with a text editing program like Notepad, and do a Find/Replace.
4. In the Find field, enter Blend Swap CC-0# and mind the spaces and trailing pound sign. Replace all instances. You should notice this text disappear from the id= lines of each furniture entry.
5. Save the file and put it back into the SH3F archive. Close the archive.
6. You can then make changes with FLE, then open it directly with SH3D. The new categorization should be correct.

I don't know why the SH3F reader in Sweet Home would treat an edited file that way, but at least it's there if we need it.

If all goes well, consider this thread [RESOLVED]! biggrin
[Sep 9, 2020, 6:38:02 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
ninja592
Newbie




Joined: Aug 23, 2020
Post Count: 9
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

Wow, thank you for your tests harbinger!

Unfortunately I didn't get the same results...

I followed your steps exactly with my modified file and also removed the extra # in front of "id=SweetHome3D#BlendSwap-CC-0-Models", but I still get the same behavior. Then I took the original file and did exactly the same steps, but it still didn't work correctly.

I then compared another modified file (from BlendSwap-CC-BY) that imported correctly and this is what it shows:

#
# PluginFurnitureCatalog.properties Sun Aug 23 09:24:06 EEST 2020
# Generated by Furniture Library Editor
#

id=SweetHome3D#BlendSwap-CC-BY-Models
name=Blend Swap CC-BY
description=Blend Swap models Creative Commons Attribution
version=1.7.1
license=Creative Commons Attribution 3.0
license provider=www.sweethome3d.com

id#1=Blend Swap CC-BY#arbolito
name#1=Christmas tree
tags#1=Blend Swap, Decoration
creationDate#1=2013-09-05
category#1=Decoration
icon#1=/Christmas tree.png
model#1=/Christmas tree/arbolito.obj
multiPartModel#1=true
width#1=25.4
depth#1=26.2
height#1=38
movable#1=true
doorOrWindow#1=false
modelSize#1=705006
creator#1=Hermescn


So they look similar when modified but one imports correctly while the other doesn't...

@harbinger: Could you post the start of your modified BlendSwap-CC-0 file and your first entry please? Maybe I can find something in there if I compare it...
[Sep 9, 2020, 2:10:34 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
ninja592
Newbie




Joined: Aug 23, 2020
Post Count: 9
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

I have found the problem!

I checked the contents of BlendSwap-CC-0.sh3f again and noticed that there is PluginFurnitureCatalog.properties but also PluginFurnitureCatalog_en_US.properties. In the en_US file, the item names + categories still had the original names and did not contain my modifications.

My Windows was set to US English, after I changed it to UK English everything was exactly where it needed to be in SH3D biggrin

Then I thought I'll try to remove the PluginFurnitureCatalog_en_US.properties file from BlendSwap-CC-0.sh3f and changed the Windows language back to US English and it worked as well. Problem resolved smile

Thank you so much harbinger, I would have never thought to look into the contents of the *.sh3f file!
[Sep 12, 2020, 12:16:29 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
harbinger
Member
Member's Avatar

US
Joined: Feb 27, 2014
Post Count: 87
Status: Offline
Reply to this Post  Reply with Quote 
Re: Problems with categories in BlendSwap-CC-0 furniture library

I'm so glad we were able to put our brains together to solve the problem!
[Sep 12, 2020, 6:30:41 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Posts: 17   Pages: 2   [ Previous Page | 1 2 ]
[ 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