1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-04 18:06:22 +03:00

272 Commits

Author SHA1 Message Date
kgv
77cd443b99 0029377: Configuration, CMake - linkage errors while using static OCCT libraries on Windows platform
HAVE_NO_DLL is now defined when building Static libraries.
2017-12-20 18:50:45 +03:00
emv
803a8cafe5 0029363: No history for shapes which were produced as a result of intersection
1. Implementation of the *Generated* method for the algorithms in Boolean Component.
In terms of these algorithms the shape from the arguments can have Generated shapes only if these new shapes have been obtained as a result of pure intersection (not overlapping) of this shape with any other shapes from arguments.
Thus, the Generated shapes are always:
* VERTICES created from the intersection points and may be Generated from edges and faces only;
* EDGES created from the intersection edges and may be Generated from faces only.

So, only EDGES and FACES could have information about Generated shapes. For all other types of shapes the list of Generated shapes will be empty.

2. Optimization and simplification of the Modified and IsDeleted methods based on the correct filling of the BOPAlgo_BuilderShape::myImagesResult map.

3. Provide history of unification of the solids in the CellsBuilder algorithm.

4. Update of the documentation of Boolean Operations User guide with new chapter "History Information" describing rules for filling history for operations in Boolean Component.

5. Test cases for the issue. New grid "history" has been added into "boolean" category.
2017-12-20 18:50:21 +03:00
emv
944768d277 0029312: Using OBB to speed up Boolean Operations
1. Implementation of the user-defined option for usage of Oriented Bounding Boxes (OBB) in Boolean Operations for additional filtering (rejection) of selected for intersection pairs of sub-shapes.

By default the usage of OBB is turned off.
To enable/disable its usage the method SetUseOBB(flag) should be used. This method is available for all operations in Boolean Component.
To enable/disable it in draw the command "buseobb 0/1" should be used. Note, that this will affect all subsequent operations.

The OBB for the shapes are built by first necessity and stored into operation context (IntTools_Context).

2. Usage of the OBB in some test cases.
2017-12-08 16:39:15 +03:00
nbv
1a0339b464 0029311: Implementation of the Oriented Bounding Boxes (OBB) functionality
1. The class Bnd_OBB has been created to describe the Oriented Bounding Box.

2. Several key methods have been implemented: Bnd_OBB::IsOut(...), Bnd_OBB::Add(...) and Bnd_OBB::Enlarge(...).

3. Interface of Bnd_Box class has changed. New methods have been created. See Bnd_Box.hxx for detailed information.

4. BRepBndLib and Draw_Box classes have been amended in order to provide correct work with Bnd_OBB class.

5. Interface of "bounding" DRAW-command has been changed. Please see help for detailed information.

6. New DRAW-command "isbbinterf" has been created. Please see help for detailed information.

7. "boundingstr" and "optbounding" DRAW-commands have been eliminated because their function can be made by "bounding" DRAW-command (e.g. see tests/bugs/vis/buc60857 or samples/tcl/snowflake.tcl test cases).

8. Documentation has been updated.
2017-12-08 16:39:11 +03:00
kgv
992ed6b3c0 0029290: Visualization, TKOpenGl - allow defining Light source per ZLayer
Graphic3d_CLight is now defined as a class inheriting Standard_Transient,
so that it's fields now should be accessed through methods.
Graphic3d_CLight::IsEnabled() - new property allowing to disable light source everywhere.
Confusing alias OpenGl_Light has been removed.

Graphic3d_CLight::SetAttenuation() - the upper limit 1.0 of attenuation factors has been removed
since it contradicts to OpenGL specs and does not make sense.

Graphic3d_ZLayerSettings::Lights() - light sources list is now property of ZLayer.
When defined, it overrides light sources defined for View/Viewer.
New class Graphic3d_LightSet has been defined to define a set of light sources.

V3d_Light - removed obsolete interface for debug drawing lights sources.
V3d_Light is now an alias to Graphic3d_CLight.
V3d_TypeOfLight is now defined as a typedef to Graphic3d_TypeOfLightSource.
2017-11-30 23:09:23 +03:00
emv
81a55a6996 0029333: Boolean Operations - Prevent modification of the input shapes in case their sub-shapes have not been modified
Prevent modification of the input shapes in destructive mode in case their sub-shapes have not been modified:
1. Prevent edge splitting for the pave blocks with old vertices if it is possible to use the existing edge (*BOPAlgo_PaveFiller::MakeSplitEdges*);
2. Prevent creation of the new containers (WIRES/SHELLS/COMPSOLIDS) if non of its parts have been modified (*BOPAlgo_Builder::FillImagesContainer*);
3. Prevent creation of the new face if non of its wires have been modified (*BOPAlgo_Builder::FillImagesFaces*);
4. If possible, use the original face to be the representative for the group of SD faces (*BOPAlgo_Builder::FillSameDomainFaces*).

Cosmetic changes:
1. Documentation of the *BOPAlgo_Builder* class.
2. Making simple methods of the *BOPAlgo_Builder* class inline.
3. Getting rid of the *BOPAlgo_Builder::mySplits* field as it is excessive. *BOPAlgo_Builder::myImages* can be used instead.
3. Moving the Check Inverted option from *BOPAlgo_Options* to *BOPAlgo_Builder*.

Test cases for the issue.
Adjustment of the test case to their current behavior.
Test case *blend/complex/H2* has been deleted as duplicate of the test case *blend/simple/Z1*.
2017-11-30 12:11:20 +03:00
emv
1155d05a06 0025609: Clean up the duplicate classes in TKBO project
1. The package BOPCol has been fully removed:
- *BOPCol_BaseAllocator* is replaced with *Handle(NCollection_BaseAllocator)*;
- *BOPCol_BoxBndTree* is replaced with *BOPTools_BoxBndTree*;
- *BOPCol_Box2DBndTree* is removed as unused;
- *BOPCol_DataMapOfIntegerInteger* is replaced with *TColStd_DataMapOfIntegerInteger*;
- *BOPCol_DataMapOfIntegerListOfInteger* is replaced with *TColStd_DataMapOfIntegerListOfInteger*;
- *BOPCol_DataMapOfIntegerListOfShape* is replaced with *TopTools_DataMapOfIntegerListOfShape*;
- *BOPCol_DataMapOfIntegerMapOfInteger.hxx* is removed as unused;
- *BOPCol_DataMapOfIntegerReal* is replaced with *TColStd_DataMapOfIntegerReal*;
- *BOPCol_DataMapOfIntegerShape* is replaced with *TopTools_DataMapOfIntegerShape*;
- *BOPCol_DataMapOfShapeBox* is replaced with *TopTools_DataMapOfShapeBox*;
- *BOPCol_DataMapOfShapeInteger* is replaced with *TopTools_DataMapOfShapeInteger*;
- *BOPCol_DataMapOfShapeListOfShape* is replaced with *TopTools_DataMapOfShapeListOfShape*;
- *BOPCol_DataMapOfShapeReal* is replaced with *TopTools_DataMapOfShapeReal*;
- *BOPCol_DataMapOfShapeShape* is replaced with *TopTools_DataMapOfShapeShape*;
- *BOPCol_DataMapOfTransientAddress* is removed as unused;
- *BOPCol_IndexedDataMapOfIntegerListOfInteger* is removed as unused;
- *BOPCol_IndexedDataMapOfShapeBox* is removed as unused;
- *BOPCol_IndexedDataMapOfShapeInteger* is removed as unused;
- *BOPCol_IndexedDataMapOfShapeListOfShape* is replaced with *TopTools_IndexedDataMapOfShapeListOfShape*;
- *BOPCol_IndexedDataMapOfShapeReal* is removed as unused;
- *BOPCol_IndexedDataMapOfShapeShape* is replaced with *TopTools_IndexedDataMapOfShapeShape*;
- *BOPCol_IndexedMapOfInteger* is replaced with *TColStd_IndexedMapOfInteger*;
- *BOPCol_IndexedMapOfOrientedShape* is replaced with *TopTools_IndexedMapOfOrientedShape*;
- *BOPCol_IndexedMapOfShape* is replaced with *TopTools_IndexedMapOfShape*;
- *BOPCol_ListOfInteger* is replaced with *TColStd_ListOfInteger*;
- *BOPCol_ListOfListOfShape* is replaced with *TopTools_ListOfListOfShape*;
- *BOPCol_ListOfShape* is replaced with *TopTools_ListOfShape*;
- *BOPCol_MapOfInteger* is replaced with *TColStd_MapOfInteger*;
- *BOPCol_MapOfOrientedShape* is replaced with *TopTools_MapOfOrientedShape*;
- *BOPCol_MapOfShape* is replaced with *TopTools_MapOfShape*;
- *BOPCol_PListOfInteger* is removed as unused;
- *BOPCol_PInteger* is removed as unused
- *BOPCol_SequenceOfPnt2d* is replaced with *TColgp_SequenceOfPnt2d*;
- *BOPCol_SequenceOfReal* is replaced with *TColStd_SequenceOfReal*;
- *BOPCol_SequenceOfShape* is replaced with *TopTools_SequenceOfShape*;
- *BOPCol_Parallel* is replaced with *BOPTools_Parallel*;
- *BOPCol_NCVector* is replaced with *NCollection_Vector*;

2. The class *BOPDS_PassKey* and containers for it have been removed as unused;

3. The unused containers from *IntTools* package have been removed:
- *IntTools_DataMapOfShapeAddress* is removed as unused;
- *IntTools_IndexedDataMapOfTransientAddress* is removed as unused;

4. The container *BiTgte_DataMapOfShapeBox* is replaced with *TopTools_DataMapOfShapeBox*;

5. The class *BOPTools* has been removed as duplicate of the class *TopExp*;
2017-11-30 12:11:15 +03:00
ifv
18d8e3e794 0029289: Wrong derivatives in math_TrigonometricFunctionRoots.cxx file
Class MyTrigoFunction is removed from file math_TrigonometricFunctionRoots.cxx.
New class math_TrigonometricEquationFunction with the same functionality is created to provide possibilities
for individual testing.
Expressions for derivatives are corrected.
New Draw command "intconcon" for intersection 2d conic curves is created.
Test command OCC29289 (file QABugs_20.cxx) is created for individual testing math_TrigonometricEquationFunction.
It is used in tests/bugs/modalg_7/bug29289
2017-11-27 11:01:21 +03:00
abv
e7174545eb 0029113: Coding Rules - fix convention to have one header per API type
Paragraph on naming of classes is revised to describe correspondence of names of public types and files.
2017-11-22 15:41:13 +03:00
msv
f16a6cc5aa 0028467: Improve UnifySameDomain performance
This patch turns off some not needed modes of fix in the called ShapeFix_Face algorithm.

It stores pcurves on planes in the edges to avoid repeated computation of the same pcurves many times (it is done only when SafeInputMode is false).

It avoids unnecessary replace/apply actions in the modification context.

It removes the code that makes decomposition of surface of the face on several faces.

The new command buildpcurvesonplane has been added, which builds and stores pcurves of edges on planar faces. This is useful for investigations how presence of pcurves on planes influence performance of algorithms.

Make drawing of dimension line in snowflake test independent on the order of vertices in the result.
2017-11-14 15:56:53 +03:00
emv
98b3765966 0029237: Improve performance of Boolean Operations
In order to improve performance of Boolean Operations on the relatively fast cases the following improvements have been made:
1. Initialization of the FaceInfo information for the faces participating in Face/Face interference, even when the gluing is ON, to take into account intersection of their sub-shapes.
2. Code simplification & duplication removal - the methods BOPAlgo_ShellSplitter::MakeConnexityBlocks and BOPAlgo_WireSplitter::MakeConnexityBlocks have been unified into BOPTools_AlgoTools::MakeConnexityBlocks.
3. Avoid unnecessary bounding box computation for solids during DS initialization. The bounding boxes for solids will be computed during the building stage to find faces located inside solids.
   For the shape self-interference check (performed by the BOPAlgo_CheckerSI), the bounding box is still computed, as it is necessary to resolve Shape/Solid intersections.
4. Use only three sample points to check coincidence of line and plane.
5. Perform necessity of planes intersection only when the gluing is off.
6. Avoid repeated initialization of 2D classifier while building splits of the faces.
7. Post treat stage:
7.1. Method CorrectWires: Save edge's data (PCurve, parameter of the vertex, range) to avoid its recalculation.
7.2. Method CheckEdge: While checking vertices on edges avoid unnecessary calculation of their location.
8. Provide possibility to disable the classification of the input solids on the inverted status (to be the holes in the space).
9. Avoid building of bounding boxes for faces/solids during splitting of the input arguments for their classification relatively hole faces/shells if there are no holes created.
10. Avoid rebuilding of the faces/solids from arguments which does not acquire any inside parts from other arguments during the operation by using their draft versions as their splits.

Test cases for the issue.
Correction of the test cases boolean gdml_public A9 and bugs modalg_7 bug28485 as they are improvements.
Additional test case for the issue #28485 as it is fixed by the current changes.
2017-11-01 17:27:08 +03:00
abv
cf0786daf1 0024574: ICC compiler warnings on Windows
NCollection_UtfString and NCollection_UtfIterator classes are refactored to use methods overloading instead of switches to dispatch implementation depending on character (Unicode code unit) size.

ICC-specific preprocessor directives are added to avoid warnings.
Unused local functions and variables, class methods, unreachable statements, and extra throw() declarations reported by ICC are removed.
Usage of "expl" for name of local variable is avoided as it conflicts with standard C function "expl" defined in math.h as preprocessor macro.

Non-standard (MS-specific) argument envp is removed in definition of main() function on Windows.
Functions _main_ and _WinMain_ are renamed to Draw_Main and Draw_WinMain, respectively, to avoid using names reserved in C++.

Doxygen warning is fixed in XDE User's Guide.
2017-10-23 16:54:48 +03:00
kgv
744d9c0d22 0029228: Coding Rules - define rule for avoiding header inclusion list pollution 2017-10-19 12:26:43 +03:00
snn
a8a3b37c0d 0029119: Documentation for PMI in XCAF
Documentation is added to the XDE part of the User Guide for GD&T, Clipping planes and Saved view components.
2017-09-29 09:42:09 +03:00
oan
71c810df61 0028824: Possibility to build OCCT 7.1.0 and above using Visual Studio 2008
Possibility to build OCCT using Visual Studio 2008 (VC9) is restored.
For that:

- template functions and classes from namespace std or tr1 (for VC9) are imported to namespace opencascade which is then used instead of std in relevant places
- templates not provided by compiler (VC9) but required for OCCT are defined in this namespace (in Standard_Handle.hxx)
- methods implementing move semantics are excluded for VC9 compiler (which does not support && syntax)
- support of vc9 compiler is restored in build procedures and environment scripts
- check of type of the current class in macros DEFINE_STANDARD_RTTI* is refactored

VS 2008 is restored in the list of supported platforms on Overview / System Requirements.
2017-09-22 11:52:00 +03:00
abv
3ba79772a0 0028660: Documentation - describe how to fulfill LGPL terms in OCCT-based applications
Points considered as necessary to fulfill requirements of LGPL when OCCT is used in proprietary applications are described in Overview.
2017-09-22 11:51:31 +03:00
abv
4eb6e8f464 0029077: Tests - improve command testfile
Command testfile is improved to be more usable by developers for checking data files used by the new test cases before their integration to the test data base:

1. Do not check and do not report problems found in the repo when checking new files -- this check is done only when argument is "-check"

2. Can check a file located in a directory listed in CSF_TestDataPath as new one without it being considered as already in the data base

3. For new BREP files, reports warning if the file contains triangulation, suggesting that it can be removed to minimize the size

4. Can identify the same (by content) file in the data base for the new files in DOS encoding (less than 1 MB)

5. Can detect duplicates among the input files

6. Outputs result in more clear form

7. When loading STL files, uses option "triangulation" to be efficient

Automated Testing System guide is updated to describe command testfile.

Added test demo testsystem testfile
2017-09-22 11:51:25 +03:00
nds
d2c909178e 0029018: Documentation - Provide user guide for Qt browser
Documentation is added in a new "Inspector" page of "User Guides".
Inspector plugins has some improvements by the documentation needs.
New DRAW scripts are implemented for 'tinspector' command.
2017-08-31 15:47:56 +03:00
abv
434098193a Update of title page of documentation (overview)
- Copyright year is updated
- Links to 3rd-party libraries and their licenses are actualized
- Description and snapshot of iOS sample added
- Visual Studio 2017 is mentioned among supported compilers
2017-08-31 15:47:41 +03:00
snn
024d6f7775 0028985: XCAF data structures for generic text annotations linked to GD&T annotations and saved views
1. A tool to annotate items in the hierarchical product structure was added. The tool is located under
   fixed label 0:1:9. It operates two basic entities: notes and annotations located under 0:1:9:1 and 0:1:9:2
   hives correspondingly. A note is an attribute derived from base class XCAFDoc_Note that is attached to a separate
   label under the notes hive. An annotated item is represented by XCAFDoc_AssemblyItemRef attribute
   attached to a separate label under the annotated items hive. Notes are linked to annotated items by means of
   XCAFDoc_GraphNode attribute, where notes play parent roles and annotated items - child roles.
2. XCAFDoc_AssemblyItemRef defines a weak reference to a label with optional attribute GUID or sub-shape index.
3. A capability to store note/annotation labels in XCAFDoc_ViewTool was added.
4. XDE User guide was updated
2017-08-30 13:52:39 +03:00
abv
4bcc20301e 0029047: Upgrade guide -- some changes in OCCT 7.2.0 are not described
Upgrade Guide is updated to describe:
- Removal of typedefs to double in Quantity and V3d
- Removal of support of orientation in classes BRepTools_ReShape and ShapeBuild_ReShape
- Removal of AIS methods taking/returning Quantity_NameOfColor instead of Quantity_Color
- Removal of active texture state from OpenGl_Workspace
2017-08-29 11:28:27 +03:00
ysn
a41ccd91d9 0027018: Documentation - blockquotes are incorrectly formatted in PDF
Trailing space is removed after ">" to avoid breaking the quote block in PDF output.

A section about quotes are added in the documentation guide.
2017-08-24 19:12:57 +03:00
kgv
7c42f3f48d 0028997: Documentation - Visual3d_Layer removed, but still in the documentation
The User Guide has been checked for presence of removed functionality.
2017-08-24 19:12:22 +03:00
emv
a743814be9 0029000: Update documentation of Boolean operations according to the new Error/Warning reporting system
The documentation of Boolean Component has been updated - calls to ErrorStatus() method have been replaced with calls to HasErrors() method.
2017-08-17 22:21:30 +03:00
abv
efe9d99730 0029009: Configuration - provide a way to get visual dif of SVG images
New helper script svgdiff.bat is added in adm folder.
It can be used for enabling visual diff for SVG images in TortouseGit; see Git guide for details.
2017-08-17 22:21:29 +03:00
abv
471a2ca0bf 0028959: Configuration, genproj - provide warning on update of scripts in root folder (msvc.bat etc.)
When updating files msvc.bat and draw.bat/sh in the root folder by copying template from adm/templates, procedure genproj will give a warning (unless the files are already the same); if the target file is newer, its copy is saved with additional extension .bak.
2017-08-17 22:21:16 +03:00
abv
0ef598d064 0028249: Upgrade Guide - mention need to use option -std=c++0x when using GCC 2017-08-17 15:48:29 +03:00
kgv
cee2b5567d 0028323: Documentation - explain highlighting logic of AIS_InteractiveObject in the upgrade guide 2017-08-17 15:48:04 +03:00
emv
9d8e074451 0027876: Draw mkoffset does not work
Updating the documentation for the Draw command *mkoffset*.
2017-08-08 18:17:41 +03:00
aml
4178b3531b 0028840: Data Exchange - rewrite the STL Reader/Writer
STL Reader and Writer tools have been refactored to improve performance and usability:
- Basic reading of STL file is separated to abstract class RWStl_Reader which is not bound to particular data structures; the target data model can be bound via inheritance.
- RWStl package uses class Poly_Triangulation to represent triangular mesh.
- Obsolete data structures and tools (packages StlMesh and StlTransfer) are removed.
2017-08-01 23:48:15 +03:00
kgv
08f8a1854d 0025382: Visualization, TKOpenGl - improved video recording capability
Image_VideoRecorder - added new class for video recording using FFmpeg framework.
Draw Harness command vanimation has been extended with new options for video recording.
New optional dependency has been introduced - CSF_FFmpeg.
2017-07-31 17:37:07 +03:00
nds
948c552acd 0028850: Visualization - Length dimension along Horizontal/Vertical axes
AIS_LengthDimension interface was extended to allow setting a custom dimension direction.
The value of dimension in this case is equal to projection of the distance between dimension attributes(points) to this direction.

vlengthparam command is implemented to set custom length direction in DRAW.
2017-07-28 15:34:51 +03:00
abv
cdec5927b3 0028950: Generation of draw_test_harness and upgrade pdf files is crashed
Template for LaTeX header used in generation of PDF manuals is corrected to avoid multiple errors during processing by LaTeX (which can eventually lead to LaTeX aborting if their count exceeds 100).

Names of log files generated by gendoc command are made dependent on target format and (for PDF output) document name.

Formatting bug is fixed in DRAW User Guide
2017-07-27 14:00:03 +03:00
apn
bbf03a4e8e 0028951: MathJax CDN shutting down
Correct all links using old MathJax version.
2017-07-27 13:59:47 +03:00
kgv
a6dee93dfa 0028811: Visualization - merge texturing support into AIS_Shape class and get rid of AIS_TexturedShape
AIS_Shape and AIS_ColoredShape now computes Shaded presentation
with UV coordinates if texture mapping is enabled in Drawer.

OpenGl_Context::SetTextureMatrix() - fixed inconsistent handling
of texture cooridnates translation vector.

vtexture command has been extended to handle new arguments:
* -trsfTrans, -trsfScale, -trsfAngle defining transformation matrix
* -setFilter, -setAnisoFilter to setup texture filtering
2017-07-21 12:10:37 +03:00
abv
d6cda17a42 0028701: Configuration - add support of VS 2017
Added support of Visual Studio 2017 (15) in CMake build procedure.
CMake 3.7.2 or above is required to generate projects for VS 2017.

Since version of compiler and toolset remained at 14 (now they are 14.1), and they use the same run-time, the same third-party products as for VS 2015 (14) can be used.
Also the name of the folder for installation of OCCT binaries in OCCT-standard layout (default on Windows) remains "vc14".

Support of Visual Studio 2017 is added in genproj generator and relevant environment, with format specifier "vc141".

The syntax of the genproj command is revised:
- UWP is considered as separate platform ("uwp" alternative to "wnt"), not part of IDE specification
- Option "IDE" is renamed to "Format"
- Obsolete name of local variable "aWokStation" is replaced by equivalent "theFormat"

In environment scripts, additional variables are defined (derived from VCVER, see adm/vcver.bat):
- VCLIB defines name of the subdirectory specific to VS version; it is the same as VCVER except that for VCVER=vc141 VCLIB=vc14 and for VCVER=141-uwp VCLIB=vc14-uwp
- VCFMT is VCVER without optional suffix "-uwp"
- VCPROP is "NativeDesktop" for normal builds or "Universal" for UWP builds

Command genconf is amended to:
- Detect presence of VS 2017 (separately for desktop and UWP)
- Use only two first digits after "vc" in format specification for search of third-party libs
- Have more space in user interface for VS specification

All supported variants of VCVER variable are documented in dev guides / buiding / msvc
2017-07-13 17:29:45 +03:00
kgv
25e59720d6 0028832: MMgt_TShared can be replaced by Standard_Transient 2017-07-06 13:18:13 +03:00
kgv
e958a649c6 0028876: Tests, Image_Diff - the image difference is unavailable for test case bugs vis bug28205_1
Quantity_ColorRGBA - added method SetValues().
Image_PixMap::PixelColor() now returns Quantity_ColorRGBA instead of Quantity_Color.
Image_PixMap::SetPixelColor() now takes Quantity_ColorRGBA instead of NCollection_Vec4<float>.

Image_Diff has been improved to support Image_Format_Gray.
Image_Diff::SaveDiffImage() now saves image difference
in Image_Format_Gray format to reduce size of image file.

Image_Diff now uses TColStd_HPackedMapOfInteger instead of
TColStd_MapOfInteger with manual memory allocation.
2017-07-06 12:45:37 +03:00
emv
33ba856502 0028786: Refactoring of the Warning/Error reporting system of Boolean Operations Algorithm
0. Basic tools for defining classes representing alerts (errors, warnings etc.) and collecting them during execution of algorithms are added in Message package.

1. Refactoring of the Error/Warning reporting system of the algorithms in Boolean Component.
   To dump the description of the Error/Warning status of the algorithm the DumpErrors/DumpWarnings method should be called.
   Also, the methods GerErrorMsg(int Error) and GetWarningMsg(int Warning) have been implemented to get the description for the given Error/Warning.
   All Error/Warning statuses are now listed in the enumeration ErrorStatusEnum/WarningStatusEnum of the algorithm.
   It is also possible to get the shapes for which the warning has been set by using the method GetWarningShapes().

2. The new class BOPAlgo_Options has been created to unify the options of the BOPAlgo_* and BRepAlgoAPI* algorithms.

3. The new checks across the algorithms have been added to detect and report errors and warnings.

4. Test cases
  boolean bopcut_complex B9 E1 E5 E8
  boolean bopfuse_complex B4 B5 C9 D1 D4 D5 D6 D7
have been rewritten to use Cells Builder algorithm instead of Boolean Operations algorithm, because latter always returns error "Unsupported Boolean operation" for these cases.

5. New chapter has been added in the user guide for Boolean Operations - Error / Warning reporting system.

6. Added comment to NCollection_List::Remove(Iterator&)
2017-07-06 12:41:56 +03:00
abv
896faa7296 0028417: Using PRECOMPILED HEADER to speed up compilation time
Use of Cotire tool is introduced for acceleration of CMake builds, by usage of precompiled headers.
CMake option BUILD_USE_PCH is added to enable / disable use of precompiled headers

When precompiled headers are used, additional compiler macros are defined globally in the build system to avoid problems due to different order of included files:
- NOMINMAX is defined on Windows to prevent defining "min" and "max" as macros by windows.h
- STRSAFE_NO_DEPRECATE and _SCL_SECURE_NO_WARNINGS are defined on Windows to prevent declaring functions of standard C library as deprecated by #pragma, and other warnings in system headers
- GL_GLEXT_LEGACY and GLX_GLEXT_LEGACY are defined to ensure that only OCCT's own glext.h is used
- __STDC_FORMAT_MACROS is defined to have standard C print format macros always defined

Code is corrected to avoid conflicts with system headers and in case of compiling together as unity builds (partially):
- Some locally defined variables in TKV3d, TKHLR are renamed to be unique
- Duplicated definitions of macros and global functions are eliminated in TKSTEP
- Useless header WNT_UInt.hxx is removed
- Usage of local variables conflicting with X11 macro is avoided in Draw_Viewer.cxx
- Local variables in AIS_ConcentricRelation.cxx are renamed to avoid conflict with macros defined in windows.h
- HXX files containing code are renamed to PXX or merged with corresponding CXX files.

IVtkTools classes are corrected to avoid compiler warnings disabled in non-PCH builds by inclusion of VTK headers.

Useless pragmas disabling warnings on MSVC are removed
2017-07-06 12:41:41 +03:00
kgv
a2a6c87265 0028877: Documentation - fix unclosed tag in coding_rules.md 2017-06-29 14:24:12 +03:00
abk
654c48b2b9 0028710: Implement 'BRepTools_History' history for algorithm 'ShapeUpgrade_UnifySameDomain'
'BRepTools_History' history was implemented for algorithm
'ShapeUpgrade_UnifySameDomain'.

The history of the changing of the initial shape was corrected to consider all
shapes created by the algorithm as modified shapes instead of generated ones.

The old history interface was replaced by the new one:
- to get the modified shapes use: History()->Modified();
- to check if the shapes has been deleted use: History()->IsRemoved().
2017-06-29 14:24:05 +03:00
abk
98ffe9dfdf 0028709: Extend type 'BRepTools_ReShape' to support 'BRepTools_History' history
Type 'BRepTools_ReShape' was extended to:
- support the 'BRepTools_History' history;
- merge several shapes to a single shape that
  the history of the merged shapes is presented by equal ways.

Type 'ShapeBuild_ReShape' was changed to support 'BRepTools_History' history.
2017-06-29 14:23:56 +03:00
abv
21b1980f05 0028362: Documentation - Doxygen warnings
Formatting of user guide is corrected (code block properly closed)
2017-06-22 12:31:28 +03:00
jgv
2c26a53d85 0027079: Bad approximation of intersection curves with variable curvature
1. Method Approx_ComputeLine::Perform is modified: now it contains also recursive calls after new line computation made by new method ApproxInt_MultiLine::MakeMLOneMorePoint.
    2. New method MakeMLOneMorePoint is added to ApproxInt_MultiLine: it builds new sub-line as a part of main line with new point added into the middle of the longest interval between existing points.
    3. Method ShapeConstruct_ProjectCurveOnSurface::ApproxPCurve is modified to avoid regressions: now it takes care of the set of initial points to be enough close to each other so that an interval between two adjacent points is less than half-period of the surface.
    4. Modification in ShapeConstruct_ProjectCurveOnSurface: correction of pcurves of edges which extremities are in the singularities of surface.
2017-06-16 14:24:53 +03:00
kgv
f5b7241978 0028789: Visualization, TKV3d - extend API for accessing and assigning BVH builders
Several methods in Selection classes have been moved to header files for better inlining.

BVH_Constants - added new enumeration defining common constant values used with BVH trees.
BVH - replaced NCollection_Handle with Standard_Transient handle
in classes BVH_Properties, BVH_Builder, BVH_Tree, BVH_Object.

Defined global BVH-builders instead of allocating a new one for each object set.
SelectMgr_ViewerSelector - added new method ::SetEntitySetBuilder() defining
default BVH Tree builder for SelectMgr_SensitiveEntitySet.

Added new method SelectMgr_SensitiveEntitySet::SetBuilder()
for overriding default BVH tree builder.
2017-06-09 12:59:11 +03:00
kgv
26cfd29cde 0028787: Configuration, genproj - add option HAVE_RelWithDebInfo for generating VS project files with Debug info in Release mode 2017-06-09 12:59:06 +03:00
ysn
d6b4d3d0d5 0028654: Existed tool (gendoc) for generation documentation does not take into account size of images.
The parameter defining image width has been added to all figures to improve their layout in PDF documents and tweaked depending on the nature of each image.
Additionally, some minor changes improving image and text layout have been introduced.

Remove temporary added possibility for setting image width automatically for generation of pdf documentation.
2017-06-09 12:59:02 +03:00
kgv
d2e4d7b92d 0028814: Documentation - suggest using # instead of // for temporary comments in commit description 2017-06-09 12:58:58 +03:00
ifv
f6b08ecf71 0028346: Function ProjectOnSegments of ShapeAnalysis_Curve returns only single solution leading to projection result far from optimal
Subdivision of curve parametric interval based on deflection criteria is added for curve type OtherCurve in
Extrema_GExtPC.gxx. Algorithm of subdivision is implemented in Extrema_Curve(2d)Tool.cxx

New Draw command projpcurve for projection of point on CurveOnSurface is added in SWDRAW_ShapeAnalysis.cxx
projpcurve is modified to reflect "start parameter" in usage message and Draw help.
2017-06-01 13:55:22 +03:00