Print at Jan 29, 2022, 6:49:35 AM

Posted by Puybaret at Dec 13, 2016, 6:17:57 PM
Re: Export to HTML5 plug-in
Hello everybody,

Here's the new versions 1.2 of Export to HTML5 and Export to XML/OBJ plug-ins.
Both plug-ins are now based on the management of the new XML entry that was added to .sh3d files in Sweet Home 3D 5.3. The JavaScript part of the Export to HTML5 plug-in now supports pinch for zoom under Android and Windows, and was optimized to draw 3D lines faster.

To let the XML entry generated by Export to XML/OBJ plug-in share the same DTD as the Home.xml entry in .sh3d files, its XML format had to evolve a little to fix some typos and other small problems:
- logitude attribute of <compass> element was corrected as longitude
- nameVisible attribute of <room> element was renamed as areaVisible
- size attribute of <textStyle> element was renamed as fontSize
- <Text> element was renamed as <text> with lowercase letters
- the default value of wallsAlpha attribute of <environment> element is now 0 instead of 1
- the default value of thickness attribute of <polyline> element is now 1 instead of 0.
I sincerely hope these changes won't bother you too much. A few attributes were missing too but that won't change the way you could have already use the XML files generated by the plug-in. The properties stored in HomeObject instances were also saved in <property> elements, and read in JavaScript if needed. Finally, the attributes named structure and exportFlags are the only additional attributes in the <home> element written by Export to XML/OBJ plug-in.

Hope you'll enjoy these improvements smile
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D developer