Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GSoC 2017] Support 3MF Format Read/Write. #4046

Merged
merged 125 commits into from
Sep 4, 2017
Merged

Conversation

Samir55
Copy link
Member

@Samir55 Samir55 commented Jun 24, 2017

3MF is generally smaller than other comparable 3D formats where transforms and object references are supported. 3MF has an advantage over the STL format since STL doesn’t contain color or material/property and also it doesn’t have mesh topology which in turn results in larger file size.
This topic was discussed in this original issue: #2811

Features:

  • Import/Export to 3MF files command line options.
  • Export plate with modifiers and print configs in .3MF (GUI).
  • Export selected objects with modifiers print configs in .3MF (GUI).

The test suite is found in 23_3mf.t in xs/t/.
The code is documented using Doxygen syntax.

Related Links:

Other Pull Requests:

Samir55 and others added 30 commits May 30, 2017 20:00
…n slic3r.cpp

Fix miniz.c error:
 * Miniz source functions were included more than once (once during TMF.cpp and once during compiling miniz.c in /xs/src/miniz.
 * Miniz is a header file library.
 * Solution was to add #define MINIZ_HEADER_FILE_ONLY to include the header part of the single header library miniz.c.
…sic string.

- Remove #define #define MINIZ_HEADER_FILE_ONLY in the previous commit ( It's not the solution)
…use #define MINIZ_HEADER_FILE_ONLY before including it.
Add zip lib to target_link_libraries.
I think this makes TMF read/write more modular.
* Write types in "[Content_Types].xml" at /
* Create "_rels" folder at /
* write <triangles> element representing the volumes of each object.
* Adding ModelObject part number attribute (Specific to the new 3MF format).
* xmlns schema link added to < Types > element.
* Write ModelMaterials custom config data.
…roblem was that 3MF 3d matrices were row major matrices.
* Add namspaces as constant map<string, string> carrying name of namspace and the link to the namespace.
…alues but according to c++11 I must use .at(key) to compile.
@Samir55
Copy link
Member Author

Samir55 commented Aug 19, 2017

@alexrj, @lordofhyphens I have updated the code according to the link you have provided in IRC and I have used also -Weffc++ and -Wextra flags to see warnings. There were only warnings about TMFEditor and TMFParserContext not having their override versions of copy constructor and =operator overloading. I will implement them when I wake up, I don't see any need for them in our case, however.

@Samir55
Copy link
Member Author

Samir55 commented Aug 19, 2017

@alexrj @lordofhyphens If there are any improvements I should do please tell me :)

@Samir55 Samir55 changed the title GSoC Support 3MF Format Read/Write. [GSoC 2017] Support 3MF Format Read/Write. Aug 21, 2017
* Add Slic3r::ZipArchive class to handle creating zip files.
* Add Doxygen documentation to ZipArchive class.
* Update MANIFEST file/
* Update CMakeLists.txt file
@lordofhyphens
Copy link
Member

lordofhyphens commented Sep 3, 2017

Not in MANIFEST: t/23_3mf.t
Not in MANIFEST: t/models/3mf/box.3mf
Not in MANIFEST: t/models/3mf/chess.3mf
Not in MANIFEST: t/models/3mf/FaceColors.3mf
Not in MANIFEST: t/models/3mf/gimblekeychain.3mf
Not in MANIFEST: t/models/3mf/SplitPyramid.3mf
Not in MANIFEST: t/models/amf/FaceColors.amf.xml
Not in MANIFEST: t/models/stl/gimblekeychainExtended.stl
Not in MANIFEST: t/models/stl/spikey_top.stl
MANIFEST appears to be out of sync with the distribution

@Samir55 probably should add these files to the MANIFEST file.

@Samir55
Copy link
Member Author

Samir55 commented Sep 3, 2017

I've added the test files to the MANIFEST But these files should be removed from the repo (they are no longer used)

t/models/3mf/FaceColors.3mf
t/models/3mf/SplitPyramid.3mf
t/models/stl/gimblekeychainExtended.stl

@lordofhyphens sorry I forgot to add them :)

@lordofhyphens
Copy link
Member

@Samir55 Then you should git rm everything that shouldn't be in the repo and remove from MANIFEST.

@Samir55
Copy link
Member Author

Samir55 commented Sep 3, 2017

  • t/models/3mf/FaceColors.3mf It was removed using unlink() function I've added in this commit . It is generated only when the test is run.
  • t/models/3mf/SplitPyramid.3mf this file was generated during a test I deleted later at this commit .
  • t/models/stl/gimblekeychainExtended.stl was a file generated also by 3mf test (conversion from gimblekeychainExtended.3mf to STL) and I've removed that file in that commit
    @lordofhyphens I mean they are only on your branch.

@lordofhyphens
Copy link
Member

Well, that would do it ;)

@alranel alranel merged commit 5cd9ecb into slic3r:master Sep 4, 2017
@ghost ghost mentioned this pull request May 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature request This is an idea for a new feature in Slic3r
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants