Сторонние библиотеки

From FreeCAD Documentation
Revision as of 21:19, 10 February 2020 by FuzzyBot (talk | contribs) (Updating to match new version of source page)

Обзор

Эти библиотеки не изменились в проекте FreeCAD. Они используются, в основном без изменений как динамические библиотеки (*.so или *.dll). Если их необходимо их изменение или нужен класс оболочка(wrapper class), тогда код оболочки или измененный код библиотеки помещается в пакет базовой установки FreeCAD. The used libraries are:

The dependencies need to be installed in the system before proceeding with compilation; see compile on Linux/Unix, compile on Windows, and compile on MacOS for more information.

Рассмотрим используемый Набор библиотек вместо загрузки и установки всего по вашему усмотрению.

Links

Link table
Имя библиотеки Необходимая Версия Ссылка на неё
Python >= 2.5.x http://www.python.org/
OpenCasCade >= 5.2 http://www.opencascade.org
Qt >= 4.1.x http://www.qtsoftware.com
Coin3D >= 2.x http://www.coin3d.org
ODE >= 0.10.x http://www.ode.org
SoQt >= 1.2 http://www.coin3d.org
Xerces-C++ >= 2.7.x < 3.0 http://xml.apache.org/xerces-c/
GTS >= 0.7.x http://gts.sourceforge.net/
Zlib >= 1.x.x http://www.zlib.net/
Boost >= 1.33.x http://www.boost.org/
Eigen3 >= 3.0.1 http://eigen.tuxfamily.org/index.php?title=Main_Page

Подробная информация

Python

Версия: 2.5 или выше

Лицензия: Python 2.5 license

Python 2 became obsolete in 2019. Further development of FreeCAD will use exclusively Python 3; compatibility with Python 2 won't be tested, so old workbenches and macros that use this version will have to be updated or they may stop working. Please post on the FreeCAD forum if you encounter problems with Python 3.

Python is a popular all-purpose scripting language that is widely used in Linux and open source software. In FreeCAD, Python is used during compilation and also at runtime in different ways. It is used

  • to write test scripts to test for different conditions, such as memory leaks, to ensure functionality of the software after changes, for post build checks, and test coverage tests,
  • to write macros and macro recording,
  • to implement application logic for standard packages,
  • to implement auxiliary tools such as the Addon Manager,
  • to implement entire workbenches like Draft and Arch,
  • to dynamically load packages,
  • to implement rules for design (knowledge engineering),
  • to do fancy Internet interactions like work groups and PDM

Вы можете использовать исходники или бинарники из http://www.python.org/ или в качестве альтернативы использовать ActiveState Python от http://www.activestate.com/ хотя немножко сложно получить отладочные библиотеки от ActiveState.

Python was chosen as the scripting language for FreeCAD for different reasons:

  • It is more object oriented than Perl and Tcl.
  • The code is more readable than Perl and Visual Basic.
  • It is easier to embed in another application, unlike, say, Java.

In summary, Python is well documented, and it's easy to embed and extend in a C++ application. It is also well tested and has strong support from the open source community. Read more about Python and browse the official documentation at Python.org.

Boost

Версия: 1.33.x

Лицензия: Boost Software License - Версия 1.0

Boost C++ библиотеки это коллекция рецензируемых библиотек, с открытым исходным кодом, они расширяют функциональные возможности C++. Библиотеки лицензируется на условиях Boost Software License, которая позволяет использовать Boost с проектами как с открытым так и с закрытым исходным кодом. Многие основатели Boost входят в комитет стандартизации C++ и несколько Boost библиотек приняты для включения в Technical Report 1 о C++0x.

Due to their popularity and stability, many Boost libraries have been accepted for incorporation into the C++11 standard, and more are planned for inclusion in subsequent C++ standards.

В целях обеспечения эффективности и гибкости, Boost широко использует шаблоны. Boost был источником обширной работы и исследований в обобщенном программировании и мета-программирование на С++.

OpenCasCade

Версия: 5.2 и выше

Лицензия: OCTPL

OCC это полнофункциональное CAD Ядро. Первоначально, оно разрабатывалось французской компанией Matra Datavision для приложений Strim (Styler) и Euclid Quantum позже его код открыли. Это действительно огромная библиотека сделавшая создание свободного CAD приложения - возможным, в первую очередь, предоставив некоторые пакеты которые трудно или невозможно было реализовать как проект с открытым исходным кодом:

  • Полностью STEP совместимое геометрическое ядро
  • Топологические модели данных и все необходимые функции для работы с ними (отрезать, слить, вытянуть, и так далее. . . )
  • Стандартные процессоры Импорта- / Экспорта в STEP, IGES, VRML
  • 3D и 2D просмотрщики с поддержкой выбора(выделения)
  • Структуры данных документа и проекта с поддержкой сохранения и восстановления, внешне связанных документов, перечитывания истории проектирования (параметрическое моделирование) и средство для загрузки новых типов данных как динамически расширяемых пакетов

OCCT is a big and complex set of C++ libraries that provide functionality required by a CAD application:

  • A complete STEP compliant geometry kernel.
  • A topological data model and needed functions to work with shapes (cut, fuse, extrude, and many others).
  • Standard import and export processors for files like STEP, IGES, VRML.
  • A 2D and 3D viewer with selection support.
  • A document and project data structure with support for save and restore, external linking of documents, recalculation of design history (parametric modeling) and a facility to load new data types as an extension package dynamically.

There are two main versions of OpenCASCADE in existence in different Linux distributions. One is distributed by the original developers; it is known as OCCT, and is packaged under the names occ or occt. The other version is the "community edition", abbreviated OCE, and is normally found with the oce name. FreeCAD can compile against either version, however, since 2016 FreeCAD recommends compiling against the official OCCT libraries rather than the OCE ones. The reason is that the community edition lacks important bug fixes and functions that make using FreeCAD better.

Чтобы узнать больше о OpenCasCade посмотрите странице OpenCasCade или http://www.opencascade.org.

Qt

Версия: 4.1.x или выше

Лицензия: GPL v2.0/v3.0 или коммерческая (для Версии 4.5 он также LPGL v2.1)

Я не думаю, что нужно много рассказывать о Qt. Это один из наиболее часто используемых инструментальных средств графического интерфейса в проектах с открытым исходным кодом.Для меня главным в использовании Qt является Qt Designer, и возможность загрузить целый диалоговых окон, как (XML) ресурсов и включение специализированных виджетов. В CAx приложениях взаимодействие с пользователем и диалоговые окна на сегодняшний день являются большей частью кода и хорошее проектирование диалогов очень важно для простого расширения FreeCAD новой функциональностью. Дополнительную информацию и очень качественную online документацию вы можете найти на http://www.qtsoftware.com.

Further information about Qt libraries and their programming documentation are available at Qt Documentation.

Shiboken2 and Pyside2

Shiboken is the Python binding generator that Qt for Python uses to create the PySide module, in other words, it is the system that is used to expose the Qt C++ API to the Python language.

The original Shiboken and PySide packages were meant to be used with Python 2 and Qt4; since these two versions are considered obsolete in 2019, please use Shiboken2 and PySide2, which work with Python 3 and Qt5. New development of FreeCAD is done with Python 3 and Qt5, so compatibility with Python 2 and Qt4 is not guaranteed after FreeCAD 0.18.

Read more about Shiboken and Pyside on Qt for Python.

Coin3D

Версия: 2.0 и выше

Лицензия: GPL v2.0 или коммерческая

Coin это высокоуровневая библиотека 3D графики с C++ API. Coin использует структуры данных в виде древа сцен для отображения графики в реальном времени, подходит для большинства в основном научных и инженерных приложений визуализации.

Coin построен на стандарте-индустрии OpenGL библиотеки в режиме немедленного рендеринга, и добавляет абстракции для высокоуровневых примитивов, обеспечивает 3D интерактивность, очень повышает удобство и производительность программиста, и содержит много сложных функций оптимизации для быстрого рендеринга, которые являются прозрачными для прикладного программиста.

Coin основан на SGI Open Inventor API. Open Inventor, для тех кто не знаком с ним , уже давно стал стандартом де-факто графической билиотеки для 3D визуализации и програмного обеспечения для визуального моделирования в научном и инженерном сообществе. Она доказала это в теченнии 10 лет, как зрелый вклад в качестве основного строительного блока в тысячи крупномасштабных инженерных приложений по всему миру.

Мы будем использовать OpenInventor как 3D просмотрщик в FreeCAD потому что OpenCasCade просмотрщик (AIS и Graphics3D) имеют серьёзные ограничения и узкие места в производительности, особенно когда речь заходит о крупномасштабном инженерном отображении. Всякие вещи, вроде текстур или объемного рендеринга на самом деле не поддерживаются, и так далее ....

Coin портирован на широкий спектр платформ: любая UNIX / Linux / *BSD платформа, все операционные системы Microsoft Windows, и Mac OS X.

SoQt

Версия: 1.2.0 или выше

Лицензия: GPL v2.0 или коммерческая

SoQt это Inventor привязки к Qt Gui Toolkit. К сожалению это больше не LGPL так что мы должны удалить её из кодовой базы FreeCAD и связать её как библиотеку. Он имеет ту же модель лицензирования, что и coin. И вы должны скомпилировать его с вашей версией Qt.

SoQt is no longer used in FreeCAD, it was replaced by Quarter which is a more recent Qt binding.

Quarter

Version: 1.0 or higher

License: BSD 3-clause license

Quarter is a newer Coin3D binding to the Qt toolkit. A version of it is included in the source code of FreeCAD so it is compiled together with it.

Pivy

Version: 0.6.3 or higher

License: BSD 3-clause license

Pivy is a library that wraps the Coin3d library for use in Python. It is not needed to build FreeCAD or to start it, but it is needed as a runtime dependency by the Draft Workbench, and by other workbenches that use it internally, like Arch and BIM.

If you are not going to use these workbenches, you won't need Pivy.

Ply

Version: 3.11 or higher

License: BSD 3-clause license

Ply is the Python-Lex-Yacc parser. It is used as a runtime dependency by the OpenSCAD Workbench. If you don't use this workbench, you may not need this package.

For more information see Ply homepage

Xerces-C++

Версия: 2.7.0 или выше

Лицензия: Apache Software License Версия 2.0

Xerces-C++ синтаксический анализатор XML написанный на портируемом подмножестве C++. Xerces-C++ позволяет вашему приложению легко читать и записывать XML данные. Динамическая библиотека предназначена для анализа, генерации, обработки и проверки XML документов.

Анализатор используется для сохранения и восстановления параметров в FreeCAD.

Eigen3

Version: 3.0 or higher

License: Starting from the 3.1.1 version, it is licensed under the Mozilla Public License 2.0. Earlier versions were licensed under the GNU Lesser General Public License 3.

Eigen is a C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms.

If you just want to use Eigen, you can use the header files right away. There is no binary library to link to, and no configured header file. Eigen is a pure template library defined in the headers.

Eigen is used in FreeCAD for many vector operations in 3D space. To learn more, visit Eigen homepage.

Zipios++

Version: 0.1.5 or higher

License: GNU Lesser General Public License 2.1

Zipios++ is a C++ library for reading and writing .zip files. Access to individual entries is provided through standard C++ iostreams. A simple read-only virtual file system that mounts regular directories and .zip files is also provided. The structure and public interface of Zipios++ are loosely based on the java.util.zip package of Java.

FreeCAD's native file format .FCstd is in reality a .zip file that stores and compresses other types of data within it, such as BREP and XML files. Therefore, Zipios++ is used to save and open compressed archives, including FreeCAD files.

A copy of Zipios++ is included in the source code of FreeCAD so it is compiled together with it. If you want to use an external Zipios++ library, provided by your operating system, you may set -DFREECAD_USE_EXTERNAL_ZIPIOS=ON with cmake.

Zipios++ uses the Zlib library to perform the actual decompression of files.

Zlib

Версия: 1.x.x

Лицензия: zlib License

zlib разработан для свободного, универсального, юридически неизрасходованного - то есть, не отнесенного к какому-либо патенту - библиотека сжатия данных без потерь для использования практически на любом оборудовании и операционной системе. zlib формат данных самопереносимый между платформами. В отличие от метода сжатия LZW используемого в Unix compress(1) и GIF формата изображений, метод сжатия используемый в настоящее время в zlib по существу , никогда не расширяет данные. (LZW может удвоить или утроить размер файла в крайних случаях.) память требуемая zlib не зависит от входных данных и может быть уменьшена, при необходимости, в таких расходах на сжатие.

A copy of this library is included in the source code of FreeCAD so it is compiled together with it.

libarea

Version: 0.0.20140514-1 or higher

License: BSD 3-clause license

Libarea is a software library to compute profile and pocket operations which are used in computer aided manufacturing (CAM) software. It was created by Dan Heeks for his HeeksCNC project.

A copy of the library is included with the source code of the Path Workbench, so it is compiled together with it.

LibPack

LibPack это удобный пакет со всеми вашими библиотеками упакованными вместе. Он в настоящее время доступен для платформы Windows на странице Загрузок ! Если вы работаете в Linux вам не нужен LibPack, вы должны использовать репозитории пакетов вашего дистрибутива Linux..

If you're working under Linux, you don't need the LibPack, as you can get the dependencies from your distribution's repositories as mentioned in the compile on Unix page.

FreeCAD 12.1.2

See the announcement in the forum: New libpacks for Windows with Qt5.12, OCC7.3 and Python 3.6 by apeltauer

It includes among other things: Boost 1.67, Coin3D 4.0.0a, Eigen3, Open CASCADE Technology 7.3.0, Python 3.6.8, PySide2, Qt 5.12.1, Salome SMESH, Shiboken2, vtk7, Xerces-C, Zipios++, zlib 1.2.11

CompileOnMac/ru
Third Party Tools/ru