Commit Graph

381 Commits

Author SHA1 Message Date
wmayer
b2be356609 Import: Support of colors of the glTF format 2023-10-03 15:42:30 +02:00
wmayer
39d8f90cba Imoprt: move ExportOCAF2 to own source files
and move global functions to Tools class
2023-10-03 08:13:27 +02:00
Chris Hennes
8595b07b76 Merge pull request #10844 from ppphp/remove_redundant_definition
[cmake] some definitions do not matter now
2023-10-02 14:20:49 -05:00
wmayer
5a49ba8e20 Import: improve new STEP/IGES/glTF export function to support colors per face in headless mode
Fixes #10861
2023-10-02 17:10:34 +02:00
wmayer
2d4bcbba34 Import: fix legacy STEP/IGES/glTF export function to support colors per face
See issue #10861
2023-10-02 17:10:34 +02:00
wmayer
02df23ce95 Import: move OCAFBrowser to its own source files 2023-10-01 22:23:57 +02:00
wmayer
6d7b6b52c2 Import: rename ImportOCAFExt to ImportOCAFGui and move to own source files 2023-10-01 22:23:57 +02:00
wmayer
f7c348a47c Import: move class ExportOCAFGui tp its on source files 2023-10-01 22:23:57 +02:00
wmayer
abda1438ad Import: code-refactoring and clean-up
* Add new method ExportOCAF::exportObjects() to avoid code duplication
* Simplify handling of arguments passed to Python handler
* Fix several lint warnings
* Move ImportOCAFExt to the corresponding source files
2023-10-01 22:23:57 +02:00
liukaiwen
721b991b1c Merge remote-tracking branch 'origin/master' into remove_redundant_definition 2023-10-02 01:42:37 +08:00
wmayer
58cc0f2a0d Import: fix lint warnings
* Make constructors explicit
* Fix a regression from PR 10783
2023-10-01 08:01:41 +02:00
wmayer
75b313be28 Import: move IGES reader & writer to own classes 2023-10-01 00:18:11 +02:00
wmayer
f40dfe7193 Import: move STEP reader & writer to own classes 2023-10-01 00:18:11 +02:00
liukaiwen
329904a055 [cmake] some definitions do not matter build now 2023-09-27 18:17:14 +08:00
wmayer
b491afb604 Import: fixes #8666: Enable support to read glTF files 2023-09-25 13:02:59 +02:00
wmayer
943ae448d3 Import: move glTF writer to its own source files 2023-09-25 13:02:59 +02:00
pre-commit-ci[bot]
e92ed45df9 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2023-09-12 13:02:35 -04:00
wmayer
9d2775eda3 Import: move several .py files that black fails to re-format to a new directory and exclude it 2023-09-11 00:48:18 +02:00
pre-commit-ci[bot]
7eb41b4a78 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2023-09-10 19:23:47 +02:00
wmayer
af3a8d4224 Import: Apply clang format 2023-09-10 19:23:47 +02:00
wmayer
bf619d56eb Import: Apply clang format 2023-09-10 19:23:47 +02:00
Chris Hennes
1622079078 Import: Wrap PyArg_ParseTupleAndKeywords 2023-08-25 15:34:26 -05:00
andrea
ad71d1c7c1 removed unused files 2023-08-25 16:06:42 +02:00
wmayer
38a9082546 Import: modernize C++: use default member init 2023-08-23 00:55:03 +02:00
wmayer
da00501288 Mod: modernize C++: use equals default 2023-08-22 11:16:49 +02:00
wmayer
0e444a554d Import: modernize C++: return braced init list 2023-08-19 11:35:41 +02:00
wmayer
26ea9e4ea4 Import: modernize C++: use range-based for loop 2023-08-15 01:09:53 +02:00
Roy-043
e23c56e6c8 Import: Avoid dictionary.keys() where possible 2023-08-09 10:10:35 +02:00
Benjamin Bræstrup Sayoc
da2ae719f2 [Everywhere] FileInfo::hasExtension for multiple values (#9774)
* [Base] Add hasExtension for multiple values

* [Gui] Use hasExtension for multiple values

* [Drawing] Use hasExtension for multiple values

* [Fem] Use hasExtension for multiple values

* [Import] Use hasExtension for multiple values

* [Mesh] Use hasExtension for multiple values

* [Part] Use hasExtension for multiple values

* [TechDraw] Use hasExtension for multiple values
2023-08-07 09:55:19 -06:00
wmayer
7a3106d31b modernize C++: use bool literals 2023-08-06 01:35:39 +02:00
wmayer
9f99285d59 modernize C++: use nullptr 2023-08-05 11:23:12 -06:00
wmayer
2b3d48176c Mods: modernize C++: redundant void arg 2023-08-05 16:50:31 +02:00
andrea
68101ac933 removed old OCC <7 references
removed OCC <7 references
2023-08-04 21:22:40 -06:00
Syres916
8bc8209e8b [Import] Dxf Fix regression from https://github.com/FreeCAD/FreeCAD/commit/1cd9feb
See discussion https://forum.freecad.org/viewtopic.php?t=80040&sid=9937b585c8681fe5a2d27f37dcd3f163
2023-08-01 11:04:22 +02:00
Syres916
027a6a912a Merge branch 'master' into patch-80 2023-06-12 14:24:58 +01:00
Kevin Martin
d404dd59ef Handle long text/mtext on DXF import
This had previously been corrected using similar code but merging another
fix lost part of the original change for this issue.
2023-06-11 13:44:08 -04:00
Syres916
63df17f6ee [Import] DXF make codepage case insensitive
See discussion https://forum.freecad.org/viewtopic.php?t=78719

I don't believe https://github.com/FreeCAD/FreeCAD/issues/8704 is fixed even after this change, the example file Encoding-error.dxf which can be opened by Varicad Viewer still opens error free but has nothing in the 3D view.
2023-06-02 11:43:16 +01:00
wmayer
ba9c63a67a Import: fixes #9438: Crash when loading DXF file with a text element 2023-04-29 22:57:07 +02:00
luzpaz
38a01939e0 Migrate domain name from freecadweb to freecad (#9352)
* Migrate domain name from freecadweb to freecad
* Migrate src/Mod/Material files
* Migrate Stylesheet related files
* Migrate *.svg files
* Migrate miscellaneous files
* Migrate some build files
* Migrate recently added TD AR_IRAM template files

Closes #6415
2023-04-24 15:19:20 -05:00
Yorik van Havre
00b8693ac0 Merge pull request #9060 from kpemartin/master
Fix encoding error for import from older DXF files
2023-04-13 13:03:13 +02:00
easyw
4ccdb85595 fixing stepZ for exporting 2023-04-05 18:15:10 +02:00
Kevin Martin
9703853ee1 Add GIL locking for Python calls, alter cp mapping
Required GIL locking has been added where Python methods are
called.

The code mapping from codepage names like ansi_nnn to cpnnnn has
been altered a bit to shorten it.
2023-03-29 16:09:35 -04:00
Kevin Martin
4f24127848 Replace "aci" with the lesss cryptic "colorIndex"
The "a" in "aci" refers to a trademark which we want to avoid mentioning
in code. These values are indices into a color table (plus two special
values for BYBLOCK and BYLAYER) so using the term colorIndex seems more
readable.
2023-03-27 09:48:16 -04:00
Kevin Martin
8b36716bf8 Remove reference to a trademarked name 2023-03-27 09:11:52 -04:00
Kevin Martin
375e94dc3a Fix encoding error for import from older DXF files
The C++ importer incorrectly treated the contents of all TEXT and MTEXT
objects as beind encoded as UTF-8, but this is not true for DXF files
before AutoCAD 2007, where the encoding is "plain ASCII" plus some in-band
\U+dddd encoding. This would cause errors if the text contained non-ASCII
characters such as the Degree Sign.

This change causes the correct encoding to be used.
2023-03-27 07:14:07 -04:00
Pesc0
1c093e8729 remove remaining six dependencies 2023-03-26 23:39:00 +02:00
Kevin Martin
aaec21965a [Import] DXF: correction to documentation
Correction to documentation comment noticed while addressing these issues.
The comment for readDXF did not document its fourth option_source argument.
2023-03-24 23:03:52 +01:00
wmayer
6b498d82cc Import: issue #8884: C++ DXF importer never imports text (annotations
This reverts commit 877f6c09817
2023-03-22 20:09:20 +01:00
Kevin Martin
ad8483d320 Issue 8968: Correct C++ DXF importer to get all of long MTEXT text
If the MTEXT exceeds 250 characters, the contents are broken up into
several records in the DXF file. The C++ importer has been changed
to collect all these pieces into a single string containing all the text.
2023-03-20 11:48:47 -04:00
wmayer
38a100962c Import/Part: [skip ci] restore some comments 2023-03-14 21:47:41 +01:00