Commit Graph

180 Commits

Author SHA1 Message Date
enricoturri1966
fb1334af85 #5798 - Fixed naming of single part objects when loaded from 3mf files produced by 3rd part softwares 2021-08-23 11:23:31 +02:00
Vojtech Bubnik
a25d2d1de4 Support for SL1S printer:
Where SL1 is mentioned, mention it as SL1 / SL1S.
Support loading / saving of SL1S files in addition to SL1.
2021-08-13 13:40:13 +02:00
Vojtech Bubnik
e947a29fc8 Follow-up to 7c01ddf996
1) Starting with this commit, configuration block exported into G-code
   is delimited by "; prusaslicer_config = begin" and "; prusaslicer_config = end".
   These delimiters look like any other key / value configuration pairs
   on purpose to be compatible with older PrusaSlicer config parsing from G-code.
2) Config parser from G-code newly searches for "; generated by ..."
   comment over the complete G-code, thus it is compatible with various
   post processing scripts extending the G-code at the start.
3) Config parser from G-code parses PrusaSlicer version from
   the "; generated by PrusaSlicer ...." header and if the G-code was
   generated by PrusaSlicer 2.4.0-alpha0 and newer, it expects that
   the G-code already contains the "; prusaslicer_config = begin / end"
   tags and it relies on these tags to extract configuration.
4) A new simple and robust parser was written for reading project configuration
   from 3MF / AMF, while a heuristic parser to read config from G-code located
   at the end of the G-code file was used before.
2021-08-12 15:27:46 +02:00
Vojtech Bubnik
49fdf3da7b follow-up to a86e7107a5:
Make is_converted_from_meters / is_converted_from_inches exclusive-or.
Maybe it would be better to make a single enum from the two booleans,
if they are exclusive-or?
2021-08-05 15:35:44 +02:00
enricoturri1966
9264b79be7 Tech ENABLE_RELOAD_FROM_DISK_FOR_3MF set as default 2021-07-21 14:10:05 +02:00
Lukáš Hejl
569b7d7dab Removed unnecessary backward compatibility with old multi-material painted 3MF from the early stage of development. 2021-07-12 13:37:33 +02:00
Vojtech Bubnik
0f3cabb5d9 Support for forward compatibility of configurations, user and system
config bundles, project files (3MFs, AMFs). When loading these files,
the caller may decide whether to substitute some of the configuration
values the current PrusaSlicer version does not understand with
some reasonable default value, and whether to report it. If substitution
is disabled, an exception is being thrown as before this commit.
If substitution is enabled, list of substitutions is returned by the
API to be presented to the user. This allows us to introduce for example
new firmware flavor key in PrusaSlicer 2.4 while letting PrusaSlicer
2.3.2 to fall back to some default and to report it to the user.

When slicing from command line, substutions are performed by default
and reported into the console, however substitutions may be either
disabled or made silent with the new "config-compatibility" command
line option.

Substitute enums and bools only.  Allow booleans to be parsed as
    true: "1", "enabled", "on" case insensitive
    false: "0", "disabled", "off" case insensitive
This will allow us in the future for example to switch the draft_shield
boolean to an enum with the following values: "disabled" / "enabled" / "limited".

Added "enum_bitmask.hpp" - support for type safe sets of options.
See for example PresetBundle::load_configbundle(...
LoadConfigBundleAttributes flags) for an example of intended usage.

WIP: GUI for reporting the list of config substitutions needs to be
implemented by @YuSanka.
2021-06-27 16:57:05 +02:00
Vojtech Bubnik
95f4690e25 Support / seam / MMU painting serialization / deserialization:
Changed the serialization structure
	std::map<int, std::vector<bool>>
to a significantly more compact
	std::pair<std::vector<std::pair<int, int>>, std::vector<bool>>
Such change shall significantly improve efficiency of Undo / Redo stack.
2021-06-10 09:26:30 +02:00
tamasmeszaros
8fdb0fddc0 Get rid of Contour3D 2021-06-08 10:28:23 +02:00
Vojtech Bubnik
980ca195f5 Merge remote-tracking branch 'remotes/origin/lh_multi_material_segmentation' into vb_print_regions 2021-05-26 15:23:35 +02:00
Lukas Matena
4a7f078527 Fixed debug build 2021-05-24 12:20:29 +02:00
Lukas Matena
c5c6f51ae0 Fixed third batch of locale-dependent calls 2021-05-24 12:20:29 +02:00
Lukas Matena
fef385cd6b Fixed second batch of locale-dependent calls 2021-05-24 12:20:29 +02:00
tamasmeszaros
657d19482b Minor code refinements 2021-04-21 16:49:11 +02:00
tamasmeszaros
d069591514 Write hollow flag to SL1 files if any object is hollowed. 2021-04-21 16:29:12 +02:00
Lukáš Hejl
f49ceb1e0f WIP: MMU segmentation without top and bottom layers 2021-04-19 07:04:50 +02:00
Lukáš Hejl
e3c33844d5 WIP: Duplicated the FDM support gizmo for the MMU segmentation 2021-04-19 07:01:11 +02:00
tamasmeszaros
9aac1b6fa5 Fix issue with importing sl1 files with non-ascii filenames. 2021-04-07 12:41:38 +02:00
Vojtech Bubnik
8adb495e7d Fix of 589d2be442 2021-03-08 11:29:52 +01:00
Vojtech Bubnik
589d2be442 Fix of Repair with Netfabb does not work on builds after 2.3.0 release (Windows 10) #6193
This is more a workaround than a fix: Windows 10 3D model fixing API refuses
to load a zip64 encoded 3MF. We need to get in touch with Microsoft on that
issue, for now the 3MFs generated for the Windows 10 3D model fixing API
will be limited to 4GB. Saving a bigger 3MF will fail.
2021-03-08 09:36:21 +01:00
Vojtech Bubnik
32db22b77c Fix of Improve Support material adhesion by base type interface layers
under soluble supports. #5823
Implemented as a pull request #5903 by @spiky2021
and reworked.

commit c7993e619225553a2c4078787907b9ebbd9ac759
Author: spiky2021 <77010315+spiky2021@users.noreply.github.com>
Date:   Thu Feb 11 12:39:25 2021 +0100

    Base type interfaces for soluble interface supports

    At the moment soluble support material adhesion is weak due to sparse support layers under soluble support layers. I reported as issue #5823 with pictures, as well.
    I modified two methods to the SupportMaterial Class including their headers.
    The new methods add two base type interface layers to the support structure, in case the extruders are different and soluble support is choosen.
    Since it is conditionally activated, it in general doesn't need a GUI input. But a GUI option number of base interface layers may enabled users to adapt this feature to their needs.
    This is my second try to provide a pull request on this topic. Reset my fromer repository, because first I merged this and all other changes to my master and couldn't provide separate pull request anymore.
2021-02-15 18:07:44 +01:00
Vojtech Bubnik
9c568a543c Improving 3MF import: checking for invalid data. 2021-02-12 16:46:49 +01:00
YuSanka
e664100bf6 SPE-1103 Added menu items for the conversation of the volumes from/to meters
Related to #4521
2021-02-10 20:34:05 +01:00
Vojtěch Bubník
b7ae342e8e
Merge pull request #5963 from wavexx/remove_undeeded_includes
Remove unneeded inclusion of boost::nowide
2021-02-10 10:43:56 +01:00
Vojtech Bubnik
5e9a8ea700 Fixed some clang warnings 2021-02-09 19:23:58 +01:00
Lukas Matena
1834ebe981 Fixing Clang warnings 3 2021-02-08 17:52:29 +01:00
enricoturri1966
c767ce18de Removed debug code 2021-02-08 13:23:11 +01:00
Vojtech Bubnik
5449e6c549 Fixing some compiler warnings on Linux 2021-02-08 11:58:03 +01:00
YuSanka
e7544ed0c4 Fix of #5888 - Pause Print M117 message not saved after reloading .3mf project 2021-02-05 19:39:28 +01:00
Vojtech Bubnik
c2e956c6d1 3MF and AMF error reporting: Use boost::log instead of printf(). 2021-02-05 15:20:23 +01:00
Vojtech Bubnik
828271d016 Improved AMF/3MF security when parsing invalid meshes. 2021-02-05 14:19:51 +01:00
Yuri D'Elia
c6fa06579f Remove unneeded inclusion of boost::nowide 2021-02-03 20:41:04 +01:00
enricoturri1966
f939cac841 #5071 - Reload from disk for 3mf files 2021-02-01 14:33:07 +01:00
enricoturri1966
b178a1b04f 3mf export - Do not export unneeded space 2021-01-27 15:53:44 +01:00
enricoturri1966
d68489c7d7 3mf export - Removed export of duplicated line into model config file 2021-01-27 12:26:46 +01:00
Vojtech Bubnik
05f9910c8f Fixes after merge. 2021-01-27 09:35:39 +01:00
Vojtech Bubnik
7a6c038480 Refactoring of 3MF file export to use the new homebrewed miniz
streaming interface. This shall fix high memory consumption and
crashes when exporting extremely large 3MF files.
2021-01-27 09:18:17 +01:00
Vojtech Bubnik
55c698feef WIP: Exporting 3MFs through a streaming interface. 2021-01-27 09:18:16 +01:00
Vojtěch Bubník
57d0f4b4f6
Merge pull request #5544 from hzeller/fix-assignment-of-charliteral-to-writable-charptr
Fix assignment of string literals to char*.
2021-01-05 13:11:29 +01:00
Lukas Matena
6c2ce4b6b6 Escape special xml characters when writing metadata into the model file
This should fix #5577
2021-01-04 14:21:24 +01:00
Henner Zeller
79e041b961 Fix assignment of string literals to char*.
Fix some char *foo = "string literal" assignments that
really should be assigned to const char*.

(they also happen to be constexpr, but that only prevents
to assign something later to foo, but does not alter
the char* type).

Signed-off-by: Henner Zeller <h.zeller@acm.org>
2020-12-20 13:40:25 -08:00
Vojtech Bubnik
ba9a9b4e7a Fixed buffer overflow in the OBJ parser.
Improved error reporting on OBJ parser.
2020-12-17 09:53:21 +01:00
Vojtech Bubnik
7df9f3e422 Improvements of OBJ parser robustness. 2020-12-17 09:17:07 +01:00
Vojtech Bubnik
2f71af1ee4 Saving "converted from inches" to 3MF and AMF even if the file source
information is empty.
2020-12-16 12:05:29 +01:00
Lukáš Hejl
d59f345fbb Fix of #5443 - Assigned input file path for ModelVolume also for AMF archives 2020-12-15 14:18:11 +01:00
Vojtech Bubnik
9fdf8c8b8d Fixed retrieving of the "saved in inches" flag from 3MF.
Fixed "import STL from Inches" - it should always scale up even if the
object is bigger than 3x3x3mm.
2020-12-12 18:54:34 +01:00
Vojtech Bubnik
5605088aad Follow-up on aaaa85c1f8
Fix of #5007 - "Reload from disk" causes objects converted to inches to revert to mm
1) Storing and reloading the "source_in_inches" source flag from AMF and 3MF
2) When converting objects with mixed "inches" volumes, do the right thing
   and do not convert those that do not need conversion.
2020-12-12 12:06:15 +01:00
Vojtech Bubnik
aa6ddfec85 Added functions to export raw image data to PNG for debugging purposes.
Renamed PNGRead.cpp/hpp to PNGReadWrite.cpp,hpp
EdgeGrid: Resurrected debugging output to PNG.
2020-11-26 09:01:44 +01:00
Vojtech Bubnik
7c571c1d9d Merge of pull request Add support for RepetierServer #4384 by @docbobo
with the following refactorings:

1) Removed the "printhost_slug" config from the Printer config
   and from all the Printer config related spots.
2) "printhost_slug" renamed to "printhost_port". Slug sounds nasty.
3) Improved error reporting of RepetierHost class.
4) Refactored for the new "Physical Printers"

Following refactorings were done independently of the Repetier pull request:
1) Removed PrintHost static print config.
2) Clean-up after conversion of print host configuration
   from Printer config to Physical Printer config.
3) Fixed some issues, where the Printer config was still queried for
   host configuration. Vojtech believes that this should not happen
   after the host configuration is converted to physical printers.

Vojtech still feels that more refactoring is needed in regard to porting
the host configuration from Printer profile to the new Physical Printer
profile.
2020-10-28 09:51:05 +01:00
Vojtech Bubnik
95af708171 Removed m_ prefix from public member variables. 2020-10-09 13:09:21 +02:00