mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-09-08 14:17:06 +03:00
Compare commits
11 Commits
CR31373
...
IR-2020-03
Author | SHA1 | Date | |
---|---|---|---|
|
d6e18114eb | ||
|
e5c11edd7b | ||
|
fffc249f21 | ||
|
739c7e5968 | ||
|
f732ea1ab5 | ||
|
ae87bb87d0 | ||
|
3d60d73f76 | ||
|
0950253ca6 | ||
|
f6d8ca74d5 | ||
|
00cdefc7a2 | ||
|
d850414af1 |
20
adm/UDLIST
20
adm/UDLIST
@@ -444,3 +444,23 @@ t TKRWMesh
|
||||
n RWGltf
|
||||
n RWMesh
|
||||
n RWObj
|
||||
n DFBrowser
|
||||
n DFBrowserPane
|
||||
n DFBrowserPaneXDE
|
||||
n ShapeView
|
||||
n TInspector
|
||||
n TInspectorAPI
|
||||
x TInspectorEXE
|
||||
t TKDFBrowser
|
||||
t TKShapeView
|
||||
t TKTInspector
|
||||
t TKTInspectorAPI
|
||||
t TKToolsDraw
|
||||
t TKTreeModel
|
||||
t TKView
|
||||
t TKVInspector
|
||||
n ToolsDraw
|
||||
n TreeModel
|
||||
n View
|
||||
n ViewControl
|
||||
n VInspector
|
||||
|
@@ -223,9 +223,14 @@ proc wokdep:gui:UpdateList {} {
|
||||
wokdep:SearchRapidJson anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||
}
|
||||
|
||||
if { "$::CHECK_QT4" == "true" } {
|
||||
wokdep:SearchQt4 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||
if {"$::BUILD_Inspector" == "true" } {
|
||||
set ::CHECK_QT "true"
|
||||
}
|
||||
|
||||
if { "$::CHECK_QT" == "true" } {
|
||||
wokdep:SearchQt anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||
}
|
||||
|
||||
if { "$::CHECK_JDK" == "true" } {
|
||||
wokdep:SearchJDK anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||
}
|
||||
@@ -494,11 +499,16 @@ ttk::label .myFrame.myChecks.myLzmaLbl -text "Use liblzma"
|
||||
checkbutton .myFrame.myChecks.myE57Check -offvalue "false" -onvalue "true" -variable HAVE_E57 -command wokdep:gui:UpdateList
|
||||
ttk::label .myFrame.myChecks.myE57Lbl -text "Use E57"
|
||||
|
||||
checkbutton .myFrame.myChecks.myQt4Check -offvalue "false" -onvalue "true" -variable CHECK_QT4 -command wokdep:gui:UpdateList
|
||||
ttk::label .myFrame.myChecks.myQt4Lbl -text "Search Qt4"
|
||||
checkbutton .myFrame.myChecks.myQtCheck -offvalue "false" -onvalue "true" -variable CHECK_QT -command wokdep:gui:UpdateList
|
||||
ttk::label .myFrame.myChecks.myQtLbl -text "Search Qt"
|
||||
checkbutton .myFrame.myChecks.myJDKCheck -offvalue "false" -onvalue "true" -variable CHECK_JDK -command wokdep:gui:UpdateList
|
||||
ttk::label .myFrame.myChecks.myJDKLbl -text "Search JDK"
|
||||
|
||||
if { "$::tcl_platform(platform)" == "windows" } {
|
||||
checkbutton .myFrame.myChecks.myInspectorBuild -offvalue "false" -onvalue "true" -variable BUILD_Inspector -command wokdep:gui:UpdateList
|
||||
ttk::label .myFrame.myChecks.myInspectorLbl -text "Build Inspector"
|
||||
}
|
||||
|
||||
# Additional headers search paths
|
||||
ttk::label .myFrame.myIncLbl -text "Additional headers search paths:" -padding {5 5 80 5}
|
||||
scrollbar .myFrame.myIncScrl -command ".myFrame.myIncList yview"
|
||||
@@ -602,8 +612,8 @@ if { "$::tcl_platform(os)" != "Darwin" } {
|
||||
grid .myFrame.myChecks.myZLibCheck -row $aCheckRowIter -column 6 -sticky e
|
||||
grid .myFrame.myChecks.myZLibLbl -row $aCheckRowIter -column 7 -sticky w
|
||||
|
||||
grid .myFrame.myChecks.myQt4Check -row $aCheckRowIter -column 12 -sticky e
|
||||
grid .myFrame.myChecks.myQt4Lbl -row $aCheckRowIter -column 13 -sticky w
|
||||
grid .myFrame.myChecks.myQtCheck -row $aCheckRowIter -column 12 -sticky e
|
||||
grid .myFrame.myChecks.myQtLbl -row $aCheckRowIter -column 13 -sticky w
|
||||
|
||||
incr aCheckRowIter
|
||||
grid .myFrame.myChecks.myFFmpegCheck -row $aCheckRowIter -column 0 -sticky e
|
||||
@@ -628,6 +638,11 @@ grid .myFrame.myChecks.myRapidJsonLbl -row $aCheckRowIter -column 1 -sticky w
|
||||
grid .myFrame.myChecks.myE57Check -row $aCheckRowIter -column 6 -sticky e
|
||||
grid .myFrame.myChecks.myE57Lbl -row $aCheckRowIter -column 7 -sticky w
|
||||
|
||||
if { "$::tcl_platform(platform)" == "windows" } {
|
||||
grid .myFrame.myChecks.myInspectorBuild -row $aCheckRowIter -column 12 -sticky e
|
||||
grid .myFrame.myChecks.myInspectorLbl -row $aCheckRowIter -column 13 -sticky w
|
||||
}
|
||||
|
||||
incr aCheckRowIter
|
||||
|
||||
# Additional headers search paths
|
||||
|
@@ -68,7 +68,7 @@ if { [info exists ::env(SHORTCUT_HEADERS)] } {
|
||||
}
|
||||
|
||||
# fetch environment variables (e.g. set by custom.sh or custom.bat) and set them as tcl variables with the same name
|
||||
set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_ZLIB HAVE_LIBLZMA HAVE_E57 HAVE_RAPIDJSON HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX HAVE_RelWithDebInfo}
|
||||
set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_ZLIB HAVE_LIBLZMA HAVE_E57 HAVE_RAPIDJSON HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX HAVE_RelWithDebInfo BUILD_Inspector}
|
||||
foreach anEnvIter $THE_ENV_VARIABLES {
|
||||
set ${anEnvIter} "false"
|
||||
if { [info exists ::env(${anEnvIter})] } {
|
||||
@@ -1022,8 +1022,8 @@ proc wokdep:SearchVTK {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64
|
||||
return "$isFound"
|
||||
}
|
||||
|
||||
# Search Qt4 libraries placement
|
||||
proc wokdep:SearchQt4 {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||
# Search Qt libraries placement
|
||||
proc wokdep:SearchQt {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||
upvar $theErrInc anErrInc
|
||||
upvar $theErrLib32 anErrLib32
|
||||
upvar $theErrLib64 anErrLib64
|
||||
@@ -1031,53 +1031,46 @@ proc wokdep:SearchQt4 {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64
|
||||
upvar $theErrBin64 anErrBin64
|
||||
|
||||
set isFound "true"
|
||||
set aQMsgBoxHPath [wokdep:SearchHeader "QtGui/qmessagebox.h"]
|
||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt}*] "$::VCVER" "$::ARCH" ]
|
||||
set aQMsgBoxHPath [wokdep:SearchHeader "QtGui/qguiapplication.h"]
|
||||
if { "$aQMsgBoxHPath" == "" } {
|
||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$::ARCH" ]
|
||||
if { "$aPath" != "" && [file exists "$aPath/include/QtGui/qmessagebox.h"] } {
|
||||
if { "$aPath" != "" && [file exists "$aPath/include/QtGui/qguiapplication.h"] } {
|
||||
lappend ::CSF_OPT_INC "$aPath/include"
|
||||
lappend ::CSF_OPT_INC "$aPath/include/Qt"
|
||||
lappend ::CSF_OPT_INC "$aPath/include/QtGui"
|
||||
lappend ::CSF_OPT_INC "$aPath/include/QtCore"
|
||||
lappend ::CSF_OPT_INC "$aPath/include/QtWidgets"
|
||||
lappend ::CSF_OPT_INC "$aPath/include/QtXml"
|
||||
} else {
|
||||
if { [file exists "/usr/include/qt4/QtGui/qmessagebox.h"] } {
|
||||
lappend ::CSF_OPT_INC "/usr/include/qt4"
|
||||
lappend ::CSF_OPT_INC "/usr/include/qt4/Qt"
|
||||
lappend ::CSF_OPT_INC "/usr/include/qt4/QtGui"
|
||||
lappend ::CSF_OPT_INC "/usr/include/qt4/QtCore"
|
||||
} else {
|
||||
lappend anErrInc "Error: 'QtGui/qmessagebox.h' not found (Qt4)"
|
||||
lappend anErrInc "Error: 'QtGui/qguiapplication.h' not found"
|
||||
set isFound "false"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
set aQtGuiLibName "QtGui"
|
||||
if { "$::tcl_platform(platform)" == "windows" } {
|
||||
set aQtGuiLibName "QtGui4"
|
||||
set aQtGuiLibName "Qt5Gui"
|
||||
}
|
||||
|
||||
foreach anArchIter {64 32} {
|
||||
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter"]
|
||||
if { "$aQMsgBoxLibPath" == "" } {
|
||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$anArchIter" ]
|
||||
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter" "$aPath/lib"]
|
||||
if { "$aQMsgBoxLibPath" != "" } {
|
||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||
} else {
|
||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aQtGuiLibName}.${::SYS_LIB_SUFFIX}' not found (Qt4)"
|
||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aQtGuiLibName}.${::SYS_LIB_SUFFIX}' not found (Qt)"
|
||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||
}
|
||||
}
|
||||
if { "$::tcl_platform(platform)" == "windows" } {
|
||||
set aQMsgBoxDllPath [wokdep:SearchBin "QtGui4.dll" "$anArchIter"]
|
||||
set aQMsgBoxDllPath [wokdep:SearchBin "${aQtGuiLibName}.dll" "$anArchIter"]
|
||||
if { "$aQMsgBoxDllPath" == "" } {
|
||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$anArchIter" ]
|
||||
set aQMsgBoxDllPath [wokdep:SearchBin "QtGui4.dll" "$anArchIter" "$aPath/bin"]
|
||||
set aQMsgBoxDllPath [wokdep:SearchBin "${aQtGuiLibName}.dll" "$anArchIter" "$aPath/bin"]
|
||||
if { "$aQMsgBoxDllPath" != "" } {
|
||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||
} else {
|
||||
lappend anErrBin$anArchIter "Error: 'QtGui4.dll' not found (Qt4)"
|
||||
lappend anErrBin$anArchIter "Error: '${aQtGuiLibName}.dll' not found (Qt)"
|
||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||
}
|
||||
}
|
||||
|
511
adm/genproj.tcl
511
adm/genproj.tcl
File diff suppressed because it is too large
Load Diff
@@ -159,7 +159,7 @@
|
||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
||||
<OutputFile>.\..\..\..\win32\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
@@ -255,7 +255,7 @@
|
||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
||||
<OutputFile>.\..\..\..\win64\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
|
@@ -149,7 +149,7 @@
|
||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
@@ -238,7 +238,7 @@
|
||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
|
@@ -1892,3 +1892,13 @@ Enumeration BRepOffset_Type is renamed to ChFiDS_TypeOfConcavity.
|
||||
@subsection upgrade_750_sensitiveEntity Select3D_SensitiveEntity interface change
|
||||
|
||||
The method Select3D_SensitiveEntity::NbSubElements() has been changed to be constant. Select3D_SensitiveEntity subclasses at application level should be updated accordingly.
|
||||
|
||||
|
||||
@subsection upgrade_750_Booleans Changes in Boolean operations algorithm
|
||||
|
||||
* TreatCompound method has been moved from *BOPAlgo_Tools* to *BOPTools_AlgoTools*. Additionally, the map parameter became optional:
|
||||
~~~~
|
||||
void BOPTools_AlgoTools::TreatCompound (const TopoDS_Shape& theS,
|
||||
TopTools_ListOfShape& theLS,
|
||||
TopTools_MapOfShape* theMap = NULL);
|
||||
~~~~
|
||||
|
@@ -52,14 +52,6 @@ namespace
|
||||
return aDevicePixelRatio;
|
||||
});
|
||||
|
||||
/*EM_JS(void, jsSetOcctCamera, (float theFOV, float theAspect, float theNear, float theFar), {
|
||||
setOcctCamera();
|
||||
});*/
|
||||
|
||||
EM_JS(void, jsPostFrameRender, (), {
|
||||
postFrameRender();
|
||||
});
|
||||
|
||||
//! Return cavas size in pixels.
|
||||
static Graphic3d_Vec2i jsCanvasSize()
|
||||
{
|
||||
@@ -344,13 +336,7 @@ void WasmOcctView::handleViewRedraw (const Handle(AIS_InteractiveContext)& theCt
|
||||
const Handle(V3d_View)& theView)
|
||||
{
|
||||
myUpdateRequests = 0;
|
||||
|
||||
theView->Invalidate(); /// Three.js cannot be rendered properly without full redraw
|
||||
glEnable (GL_POLYGON_OFFSET_FILL); /// reset defaults Graphic3d_PolygonOffset after Three.js
|
||||
glPolygonOffset (1.0f, 1.0f);
|
||||
|
||||
AIS_ViewController::handleViewRedraw (theCtx, theView);
|
||||
jsPostFrameRender();
|
||||
if (myToAskNextFrame)
|
||||
{
|
||||
// ask more frames
|
||||
|
@@ -16,7 +16,6 @@
|
||||
<div><label for="fileInput">Choose BREP file to upload: </label><input type="file" id="fileInput" accept=".brep"></div>
|
||||
<h4>Console output:</h4>
|
||||
<p id="output"></p>
|
||||
<script src="three.min.js"></script>
|
||||
<script>
|
||||
//! Resize canvas to fit into window.
|
||||
function updateCanvasSize()
|
||||
@@ -58,7 +57,6 @@ if (!isWasmSupported())
|
||||
{
|
||||
var anElement = document.getElementById('output');
|
||||
anElement.innerHTML += "Browser is too old - WebAssembly support is missing!<br>Please check updates or install a modern browser.<br>";
|
||||
throw new Error();
|
||||
}
|
||||
|
||||
//! Define OCCT WebGL Viewer module.
|
||||
@@ -78,44 +76,6 @@ var Module =
|
||||
})()
|
||||
};
|
||||
|
||||
var aCanvas = document.getElementById ('canvas');
|
||||
var aGlCtx = aCanvas.getContext ('webgl2', { alpha: false, depth: true, antialias: false, preserveDrawingBuffer: true } );
|
||||
if (aGlCtx == null)
|
||||
{
|
||||
aGlCtx = aCanvas.getContext ('webgl', { alpha: false, depth: true, antialias: false, preserveDrawingBuffer: true } );
|
||||
}
|
||||
var aScene = new THREE.Scene();
|
||||
var aCamera = new THREE.PerspectiveCamera (75, window.innerWidth / window.innerHeight);
|
||||
//var aRenderer = new THREE.WebGLRenderer ({antialias: true});
|
||||
var aRenderer = new THREE.WebGLRenderer ({antialias: false, canvas: aCanvas, context: aGlCtx});
|
||||
aRenderer.autoClear = false;
|
||||
aRenderer.autoClearColor = false;
|
||||
aRenderer.autoClearDepth = false;
|
||||
aRenderer.autoClearStencil = false;
|
||||
aRenderer.setSize (window.innerWidth,window.innerHeight);
|
||||
//document.body.appendChild (aRenderer.domElement);
|
||||
var aGeom = new THREE.BoxGeometry (1,1,1);
|
||||
var aMat = new THREE.MeshBasicMaterial ({color: 0xff0000});
|
||||
var aCube = new THREE.Mesh (aGeom, aMat);
|
||||
aScene.add (aCube);
|
||||
aCube.position.z = -5; aCube.rotation.x = 10; aCube.rotation.y = 5;
|
||||
/*aRenderer.render (aScene, aCamera);
|
||||
var anAnimate = function(){
|
||||
aCube.rotation.x += 0.01;
|
||||
aRenderer.state.reset();
|
||||
aRenderer.render (aScene, aCamera);
|
||||
requestAnimationFrame (anAnimate);
|
||||
}
|
||||
anAnimate();*/
|
||||
|
||||
function postFrameRender()
|
||||
{
|
||||
//console.log("postFrameRender()"); ///
|
||||
//aCamera.
|
||||
aRenderer.state.reset();
|
||||
aRenderer.render (aScene, aCamera)
|
||||
}
|
||||
|
||||
//! Handle file uploading.
|
||||
fileInput.onchange = function()
|
||||
{
|
||||
|
@@ -933,6 +933,7 @@ void Adaptor3d_TopolTool::BSplSamplePnts(const Standard_Real theDefl,
|
||||
const Standard_Integer theNUmin,
|
||||
const Standard_Integer theNVmin)
|
||||
{
|
||||
const Standard_Integer aMaxPnts = 1001;
|
||||
const Handle(Geom_BSplineSurface)& aBS = myS->BSpline();
|
||||
Standard_Real uinf,usup,vinf,vsup;
|
||||
uinf = myS->FirstUParameter(); usup = myS->LastUParameter();
|
||||
@@ -999,11 +1000,20 @@ void Adaptor3d_TopolTool::BSplSamplePnts(const Standard_Real theDefl,
|
||||
nbsu = theNUmin;
|
||||
bUuniform = Standard_True;
|
||||
}
|
||||
|
||||
else if (nbsu > aMaxPnts)
|
||||
{
|
||||
nbsu = aMaxPnts;
|
||||
bUuniform = Standard_True;
|
||||
}
|
||||
if(nbsv < theNVmin) {
|
||||
nbsv = theNVmin;
|
||||
bVuniform = Standard_True;
|
||||
}
|
||||
else if (nbsv > aMaxPnts)
|
||||
{
|
||||
nbsv = aMaxPnts;
|
||||
bVuniform = Standard_True;
|
||||
}
|
||||
|
||||
TColStd_Array1OfReal anUPars(1, nbsu);
|
||||
TColStd_Array1OfBoolean anUFlg(1, nbsu);
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -20,21 +20,17 @@
|
||||
#include <Standard.hxx>
|
||||
#include <Standard_DefineAlloc.hxx>
|
||||
#include <Standard_Handle.hxx>
|
||||
|
||||
#include <Adaptor3d_CurveOnSurface.hxx>
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <Standard_Real.hxx>
|
||||
class Geom2d_BSplineCurve;
|
||||
class Adaptor2d_HCurve2d;
|
||||
class Adaptor3d_HCurve;
|
||||
class Adaptor3d_HSurface;
|
||||
class Standard_OutOfRange;
|
||||
class Standard_ConstructionError;
|
||||
class Geom_Curve;
|
||||
class Geom2d_Curve;
|
||||
class Geom_Surface;
|
||||
|
||||
|
||||
//! Approximation of a PCurve on a surface to make its
|
||||
//! Approximation of a PCurve on a surface to make its
|
||||
//! parameter be the same that the parameter of a given 3d
|
||||
//! reference curve.
|
||||
class Approx_SameParameter
|
||||
@@ -43,63 +39,149 @@ public:
|
||||
|
||||
DEFINE_STANDARD_ALLOC
|
||||
|
||||
|
||||
//! Warning: the C3D and C2D must have the same parametric domain.
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Geom_Curve)& C3D,
|
||||
const Handle(Geom2d_Curve)& C2D,
|
||||
const Handle(Geom_Surface)& S,
|
||||
const Standard_Real Tol);
|
||||
|
||||
//! Warning: the C3D and C2D must have the same parametric domain.
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Geom_Curve)& C3D, const Handle(Geom2d_Curve)& C2D, const Handle(Geom_Surface)& S, const Standard_Real Tol);
|
||||
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Adaptor3d_HCurve)& C3D, const Handle(Geom2d_Curve)& C2D, const Handle(Adaptor3d_HSurface)& S, const Standard_Real Tol);
|
||||
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Adaptor3d_HCurve)& C3D,
|
||||
const Handle(Geom2d_Curve)& C2D,
|
||||
const Handle(Adaptor3d_HSurface)& S,
|
||||
const Standard_Real Tol);
|
||||
|
||||
//! Warning: the C3D and C2D must have the same parametric domain.
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Adaptor3d_HCurve)& C3D, const Handle(Adaptor2d_HCurve2d)& C2D, const Handle(Adaptor3d_HSurface)& S, const Standard_Real Tol);
|
||||
|
||||
Standard_Boolean IsDone() const;
|
||||
|
||||
Standard_Real TolReached() const;
|
||||
|
||||
//! Tells whether the original data had already the same
|
||||
//! parameter up to the tolerance : in that case nothing
|
||||
Standard_EXPORT Approx_SameParameter(const Handle(Adaptor3d_HCurve)& C3D,
|
||||
const Handle(Adaptor2d_HCurve2d)& C2D,
|
||||
const Handle(Adaptor3d_HSurface)& S,
|
||||
const Standard_Real Tol);
|
||||
|
||||
//!@Returns .false. if calculations failed,
|
||||
//! .true. if calculations succeed
|
||||
Standard_Boolean IsDone() const
|
||||
{
|
||||
return myDone;
|
||||
}
|
||||
|
||||
//!@Returns tolerance (maximal distance) between 3d curve
|
||||
//! and curve on surface, generated by 2d curve and surface.
|
||||
Standard_Real TolReached() const
|
||||
{
|
||||
return myTolReached;
|
||||
}
|
||||
|
||||
//! Tells whether the original data had already the same
|
||||
//! parameter up to the tolerance : in that case nothing
|
||||
//! is done.
|
||||
Standard_Boolean IsSameParameter() const;
|
||||
|
||||
//! Returns the 2D curve that has the same parameter as
|
||||
//! the 3D curve once evaluated on the surface up to the
|
||||
//! specified tolerance
|
||||
Handle(Geom2d_BSplineCurve) Curve2d() const;
|
||||
|
||||
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
|
||||
Standard_Boolean IsSameParameter() const
|
||||
{
|
||||
return mySameParameter;
|
||||
}
|
||||
|
||||
//! Returns the 2D curve that has the same parameter as
|
||||
//! the 3D curve once evaluated on the surface up to the
|
||||
//! specified tolerance.
|
||||
Handle(Geom2d_Curve) Curve2d() const
|
||||
{
|
||||
return myCurve2d;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
|
||||
//! Compute the Pcurve (internal use only).
|
||||
//! Internal data structure to unify access to the most actively used data.
|
||||
//! This structure is not intended to be class field since
|
||||
//! a lot of memory is used in intermediate computations.
|
||||
struct Approx_SameParameter_Data
|
||||
{
|
||||
Adaptor3d_CurveOnSurface myCOnS; // Curve on surface.
|
||||
Standard_Integer myNbPnt; // Number of points.
|
||||
Standard_Real *myPC3d; // Parameters on 3d curve.
|
||||
Standard_Real *myPC2d; // Parameters on 2d curve.
|
||||
|
||||
// Second data arrays. Used in loop over poles.
|
||||
Standard_Real *myNewPC3d; // Parameters on 3d curve.
|
||||
Standard_Real *myNewPC2d; // Parameters on 2d curve.
|
||||
|
||||
// Parameters ranges.
|
||||
Standard_Real myC3dPF; // Curve 3d Parameter First.
|
||||
Standard_Real myC3dPL; // Curve 3d Parameter Last.
|
||||
Standard_Real myC2dPF; // Curve 2d Parameter First.
|
||||
Standard_Real myC2dPL; // Curve 2d Parameter Last.
|
||||
|
||||
Standard_Real myTol; // Working tolerance.
|
||||
|
||||
// Swap data arrays and update number of points.
|
||||
void Swap(const Standard_Integer theNewNbPoints)
|
||||
{
|
||||
myNbPnt = theNewNbPoints;
|
||||
Standard_Real * temp;
|
||||
|
||||
// 3-D
|
||||
temp = myPC3d;
|
||||
myPC3d = myNewPC3d;
|
||||
myNewPC3d = temp;
|
||||
|
||||
// 2-D
|
||||
temp = myPC2d;
|
||||
myPC2d = myNewPC2d;
|
||||
myNewPC2d = temp;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Approx_SameParameter(const Approx_SameParameter &);
|
||||
Approx_SameParameter& operator=(const Approx_SameParameter &);
|
||||
|
||||
//! Computes the pcurve (internal use only).
|
||||
Standard_EXPORT void Build (const Standard_Real Tol);
|
||||
|
||||
//! Computes initial point distribution.
|
||||
Standard_Boolean BuildInitialDistribution(Approx_SameParameter_Data &theData) const;
|
||||
|
||||
//! Increases initial number of samples in case of the C0 continuity.
|
||||
//! Return new number of points and corresponding data arrays.
|
||||
//@return true if new number of samples is good and false otherwise.
|
||||
Standard_Boolean IncreaseInitialNbSamples(Approx_SameParameter_Data &theData) const;
|
||||
|
||||
//! Computes tangents on boundary points.
|
||||
//@return true if tangents are not null and false otherwise.
|
||||
Standard_Boolean ComputeTangents(const Adaptor3d_CurveOnSurface & theCOnS,
|
||||
Standard_Real &theFirstTangent,
|
||||
Standard_Real &theLastTangent) const;
|
||||
|
||||
//! Method to check same parameter state
|
||||
//! and build dependency between 2d and 3d curves.
|
||||
//@return true if 2d and 3d curves have same parameter state and false otherwise.
|
||||
Standard_Boolean CheckSameParameter(Approx_SameParameter_Data &theData,
|
||||
Standard_Real &theSqDist) const;
|
||||
|
||||
//! Computes interpolated values.
|
||||
//!@Returns .false. if computations failed;
|
||||
Standard_Boolean Interpolate(const Approx_SameParameter_Data & theData,
|
||||
const Standard_Real aTangFirst,
|
||||
const Standard_Real aTangLast,
|
||||
TColStd_Array1OfReal & thePoles,
|
||||
TColStd_Array1OfReal & theFlatKnots) const;
|
||||
|
||||
//! Increases number of poles in poles loop.
|
||||
//@return true if poles is changed and false otherwise.
|
||||
Standard_Boolean IncreaseNbPoles(const TColStd_Array1OfReal & thePoles,
|
||||
const TColStd_Array1OfReal & theFlatKnots,
|
||||
Approx_SameParameter_Data & theData,
|
||||
Standard_Real &theBestSqTol) const;
|
||||
|
||||
static const Standard_Integer myNbSamples = 22; // To be consistent with "checkshape".
|
||||
static const Standard_Integer myMaxArraySize = 1000;
|
||||
const Standard_Real myDeltaMin; // Initialization is allowed only for integral types.
|
||||
|
||||
Standard_Boolean mySameParameter;
|
||||
Standard_Boolean myDone;
|
||||
Standard_Real myTolReached;
|
||||
Handle(Geom2d_BSplineCurve) myCurve2d;
|
||||
Handle(Geom2d_Curve) myCurve2d;
|
||||
Handle(Adaptor2d_HCurve2d) myHCurve2d;
|
||||
Handle(Adaptor3d_HCurve) myC3d;
|
||||
Handle(Adaptor3d_HSurface) mySurf;
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
#include <Approx_SameParameter.lxx>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // _Approx_SameParameter_HeaderFile
|
||||
|
@@ -1,44 +0,0 @@
|
||||
// Created on: 1995-06-06
|
||||
// Created by: Modelistation
|
||||
// Copyright (c) 1995-1999 Matra Datavision
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
//=======================================================================
|
||||
//function : IsDone
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
inline Standard_Boolean Approx_SameParameter::IsDone() const
|
||||
{ return myDone ; }
|
||||
//=======================================================================
|
||||
//function : TolReached
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
inline Standard_Real Approx_SameParameter::TolReached() const
|
||||
{ return myTolReached; }
|
||||
//=======================================================================
|
||||
//function : IsSameParameter
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
inline Standard_Boolean Approx_SameParameter::IsSameParameter() const
|
||||
{ return mySameParameter ; }
|
||||
//=======================================================================
|
||||
//function : Curve2d
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
inline Handle(Geom2d_BSplineCurve) Approx_SameParameter::Curve2d() const
|
||||
{ return myCurve2d ; }
|
@@ -24,7 +24,6 @@ Approx_MCurvesToBSpCurve.hxx
|
||||
Approx_ParametrizationType.hxx
|
||||
Approx_SameParameter.cxx
|
||||
Approx_SameParameter.hxx
|
||||
Approx_SameParameter.lxx
|
||||
Approx_SequenceOfHArray1OfReal.hxx
|
||||
Approx_Status.hxx
|
||||
Approx_SweepApproximation.cxx
|
||||
|
@@ -305,30 +305,27 @@ void BOPAlgo_ArgumentAnalyzer::TestTypes()
|
||||
return;
|
||||
}
|
||||
//
|
||||
Standard_Integer aDim1, aDim2;
|
||||
Standard_Boolean bBadTypes = Standard_False;
|
||||
//
|
||||
aDim1 = BOPTools_AlgoTools::Dimension(myShape1);
|
||||
aDim2 = BOPTools_AlgoTools::Dimension(myShape2);
|
||||
if (aDim1 < aDim2) {
|
||||
if (myOperation == BOPAlgo_FUSE ||
|
||||
myOperation == BOPAlgo_CUT21) {
|
||||
bBadTypes = Standard_True;
|
||||
if (myOperation != BOPAlgo_UNKNOWN &&
|
||||
myOperation != BOPAlgo_COMMON)
|
||||
{
|
||||
Standard_Integer iDimMin[2], iDimMax[2];
|
||||
BOPTools_AlgoTools::Dimensions(myShape1, iDimMin[0], iDimMax[0]);
|
||||
BOPTools_AlgoTools::Dimensions(myShape2, iDimMin[1], iDimMax[1]);
|
||||
|
||||
Standard_Boolean bBadTypes =
|
||||
((myOperation == BOPAlgo_FUSE) &&
|
||||
(iDimMin[0] != iDimMax[0] || iDimMin[1] != iDimMax[1] || iDimMin[0] != iDimMin[1])) ||
|
||||
((myOperation == BOPAlgo_CUT) && (iDimMax[0] > iDimMin[1])) ||
|
||||
((myOperation == BOPAlgo_CUT21) && (iDimMin[0] < iDimMax[1]));
|
||||
|
||||
if (bBadTypes) {
|
||||
BOPAlgo_CheckResult aResult;
|
||||
aResult.SetShape1(myShape1);
|
||||
aResult.SetShape2(myShape2);
|
||||
aResult.SetCheckStatus(BOPAlgo_BadType);
|
||||
myResult.Append(aResult);
|
||||
}
|
||||
}
|
||||
else if (aDim1 > aDim2) {
|
||||
if (myOperation == BOPAlgo_FUSE ||
|
||||
myOperation == BOPAlgo_CUT) {
|
||||
bBadTypes = Standard_True;
|
||||
}
|
||||
}
|
||||
if (bBadTypes) {
|
||||
BOPAlgo_CheckResult aResult;
|
||||
aResult.SetShape1(myShape1);
|
||||
aResult.SetShape2(myShape2);
|
||||
aResult.SetCheckStatus(BOPAlgo_BadType);
|
||||
myResult.Append(aResult);
|
||||
}
|
||||
}
|
||||
}
|
||||
//=======================================================================
|
||||
|
@@ -122,7 +122,7 @@ BOPAlgo_Operation BOPAlgo_BOP::Operation()const
|
||||
//=======================================================================
|
||||
void BOPAlgo_BOP::CheckData()
|
||||
{
|
||||
Standard_Integer i, j, iDim, aNbArgs, aNbTools;
|
||||
Standard_Integer i, j, aNbArgs, aNbTools;
|
||||
Standard_Boolean bFuse;
|
||||
TopTools_ListIteratorOfListOfShape aItLS;
|
||||
//
|
||||
@@ -164,7 +164,8 @@ void BOPAlgo_BOP::CheckData()
|
||||
// or equal to the MAXIMAL dimension of the TOOLS;
|
||||
// 4. COMMON: The arguments and tools could have any dimensions.
|
||||
//
|
||||
Standard_Integer iDimMin[2] = { 0, 0 }, iDimMax[2] = { 0, 0 };
|
||||
Standard_Integer iDimMin[2] = { 3, 3 },
|
||||
iDimMax[2] = { 0, 0 };
|
||||
Standard_Boolean bHasValid[2] = {Standard_False, Standard_False};
|
||||
//
|
||||
for (i=0; i<2; ++i) {
|
||||
@@ -173,38 +174,27 @@ void BOPAlgo_BOP::CheckData()
|
||||
for (j=0; aItLS.More(); aItLS.Next(), ++j) {
|
||||
const TopoDS_Shape& aS=aItLS.Value();
|
||||
Standard_Boolean bIsEmpty = BOPTools_AlgoTools3D::IsEmptyShape(aS);
|
||||
if (bIsEmpty) {
|
||||
if (bIsEmpty)
|
||||
{
|
||||
AddWarning(new BOPAlgo_AlertEmptyShape (aS));
|
||||
continue;
|
||||
}
|
||||
//
|
||||
iDim = BOPTools_AlgoTools::Dimension(aS);
|
||||
if (iDim < 0) {
|
||||
|
||||
Standard_Integer iDMin, iDMax;
|
||||
BOPTools_AlgoTools::Dimensions(aS, iDMin, iDMax);
|
||||
|
||||
if (iDMin < iDimMin[i])
|
||||
iDimMin[i] = iDMin;
|
||||
if (iDMax > iDimMax[i])
|
||||
iDimMax[i] = iDMax;
|
||||
|
||||
if (bFuse && (iDimMin[i] != iDimMax[i]))
|
||||
{
|
||||
// non-homogeneous argument
|
||||
AddError (new BOPAlgo_AlertBOPNotAllowed);
|
||||
return;
|
||||
}
|
||||
//
|
||||
bHasValid[i] = Standard_True;
|
||||
//
|
||||
if (!j) {
|
||||
iDimMin[i] = iDim;
|
||||
iDimMax[i] = iDim;
|
||||
continue;
|
||||
}
|
||||
//
|
||||
if (iDim < iDimMin[i]) {
|
||||
iDimMin[i] = iDim;
|
||||
}
|
||||
else if (iDim > iDimMax[i]) {
|
||||
iDimMax[i] = iDim;
|
||||
}
|
||||
//
|
||||
if (bFuse && (iDimMin[i] != iDimMax[i])) {
|
||||
// non-homogeneous argument
|
||||
AddError (new BOPAlgo_AlertBOPNotAllowed);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
//
|
||||
@@ -222,7 +212,7 @@ void BOPAlgo_BOP::CheckData()
|
||||
if (bHasValid[0] || bHasValid[1])
|
||||
{
|
||||
// In case of all empty shapes in one of the groups
|
||||
// this group aquires the dimension of other group
|
||||
// this group acquires the dimension of other group
|
||||
myDims[0] = bHasValid[0] ? iDimMin[0] : iDimMin[1];
|
||||
myDims[1] = bHasValid[1] ? iDimMin[1] : iDimMin[0];
|
||||
}
|
||||
@@ -583,12 +573,17 @@ void BOPAlgo_BOP::BuildRC()
|
||||
aItLS.Initialize(aLS);
|
||||
for (; aItLS.More(); aItLS.Next()) {
|
||||
const TopoDS_Shape& aS = aItLS.Value();
|
||||
iDim = BOPTools_AlgoTools::Dimension(aS);
|
||||
if (iDim < 0) {
|
||||
continue;
|
||||
TopTools_ListOfShape aList;
|
||||
BOPTools_AlgoTools::TreatCompound (aS, aList);
|
||||
for (TopTools_ListOfShape::Iterator itList (aList); itList.More(); itList.Next())
|
||||
{
|
||||
const TopoDS_Shape& aSS = itList.Value();
|
||||
iDim = BOPTools_AlgoTools::Dimension (aSS);
|
||||
if (iDim < 0)
|
||||
continue;
|
||||
aType = TypeToExplore (iDim);
|
||||
TopExp::MapShapes (aSS, aType, aMS);
|
||||
}
|
||||
aType = TypeToExplore(iDim);
|
||||
TopExp::MapShapes(aS, aType, aMS);
|
||||
}
|
||||
}
|
||||
//
|
||||
@@ -930,7 +925,7 @@ void BOPAlgo_BOP::BuildShape()
|
||||
for (; aItLS.More(); aItLS.Next())
|
||||
{
|
||||
const TopoDS_Shape& aS = aItLS.Value();
|
||||
BOPAlgo_Tools::TreatCompound(aS, aMInpFence, aLSNonCont);
|
||||
BOPTools_AlgoTools::TreatCompound(aS, aLSNonCont, &aMInpFence);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -441,7 +441,7 @@ void BOPAlgo_Builder::BuildBOP(const TopTools_ListOfShape& theObjects,
|
||||
{
|
||||
TopTools_ListOfShape aLS;
|
||||
TopTools_MapOfShape aMFence;
|
||||
BOPAlgo_Tools::TreatCompound(aS, aMFence, aLS);
|
||||
BOPTools_AlgoTools::TreatCompound(aS, aLS, &aMFence);
|
||||
|
||||
TopTools_ListOfShape::Iterator it(aLS);
|
||||
for (; it.More(); it.Next())
|
||||
|
@@ -550,7 +550,7 @@ void BOPAlgo_Builder::FillInternalShapes()
|
||||
aIt.Initialize(aArguments);
|
||||
for (; aIt.More(); aIt.Next()) {
|
||||
const TopoDS_Shape& aS=aIt.Value();
|
||||
BOPAlgo_Tools::TreatCompound(aS, aMFence, aLSC);
|
||||
BOPTools_AlgoTools::TreatCompound(aS, aLSC, &aMFence);
|
||||
}
|
||||
aIt.Initialize(aLSC);
|
||||
for (; aIt.More(); aIt.Next()) {
|
||||
|
@@ -141,44 +141,50 @@ void BOPAlgo_CellsBuilder::IndexParts()
|
||||
TopTools_ListIteratorOfListOfShape aIt(myArguments);
|
||||
for (; aIt.More(); aIt.Next()) {
|
||||
const TopoDS_Shape& aS = aIt.Value();
|
||||
//
|
||||
Standard_Integer iDim = BOPTools_AlgoTools::Dimension(aS);
|
||||
aMDims.Add(iDim);
|
||||
TopAbs_ShapeEnum aType = TypeToExplore(iDim);
|
||||
//
|
||||
TopExp_Explorer aExp(aS, aType);
|
||||
for (; aExp.More(); aExp.Next()) {
|
||||
const TopoDS_Shape& aST = aExp.Current();
|
||||
const TopTools_ListOfShape* pLSIm = myImages.Seek(aST);
|
||||
if (!pLSIm) {
|
||||
TopTools_ListOfShape* pLS = myIndex.ChangeSeek(aST);
|
||||
if (!pLS) {
|
||||
pLS = &myIndex(myIndex.Add(aST, TopTools_ListOfShape()));
|
||||
}
|
||||
pLS->Append(aS);
|
||||
//
|
||||
if (aMFence.Add(aST)) {
|
||||
aBB.Add(anAllParts, aST);
|
||||
|
||||
TopTools_ListOfShape aLSubS;
|
||||
BOPTools_AlgoTools::TreatCompound (aS, aLSubS);
|
||||
for (TopTools_ListOfShape::Iterator itSub (aLSubS); itSub.More(); itSub.Next())
|
||||
{
|
||||
const TopoDS_Shape& aSS = itSub.Value();
|
||||
Standard_Integer iDim = BOPTools_AlgoTools::Dimension (aSS);
|
||||
aMDims.Add(iDim);
|
||||
TopAbs_ShapeEnum aType = TypeToExplore (iDim);
|
||||
TopExp_Explorer aExp (aSS, aType);
|
||||
for (; aExp.More(); aExp.Next())
|
||||
{
|
||||
const TopoDS_Shape& aST = aExp.Current();
|
||||
const TopTools_ListOfShape* pLSIm = myImages.Seek(aST);
|
||||
if (!pLSIm) {
|
||||
TopTools_ListOfShape* pLS = myIndex.ChangeSeek(aST);
|
||||
if (!pLS) {
|
||||
pLS = &myIndex(myIndex.Add(aST, TopTools_ListOfShape()));
|
||||
}
|
||||
pLS->Append(aS);
|
||||
//
|
||||
if (aMFence.Add(aST)) {
|
||||
aBB.Add(anAllParts, aST);
|
||||
}
|
||||
//
|
||||
continue;
|
||||
}
|
||||
//
|
||||
continue;
|
||||
}
|
||||
//
|
||||
TopTools_ListIteratorOfListOfShape aItIm(*pLSIm);
|
||||
for (; aItIm.More(); aItIm.Next()) {
|
||||
const TopoDS_Shape& aSTIm = aItIm.Value();
|
||||
//
|
||||
TopTools_ListOfShape* pLS = myIndex.ChangeSeek(aSTIm);
|
||||
if (!pLS) {
|
||||
pLS = &myIndex(myIndex.Add(aSTIm, TopTools_ListOfShape()));
|
||||
}
|
||||
pLS->Append(aS);
|
||||
//
|
||||
if (aMFence.Add(aSTIm)) {
|
||||
aBB.Add(anAllParts, aSTIm);
|
||||
}
|
||||
} // for (; aItIm.More(); aItIm.Next()) {
|
||||
} // for (; aExp.More(); aExp.Next()) {
|
||||
TopTools_ListIteratorOfListOfShape aItIm(*pLSIm);
|
||||
for (; aItIm.More(); aItIm.Next()) {
|
||||
const TopoDS_Shape& aSTIm = aItIm.Value();
|
||||
//
|
||||
TopTools_ListOfShape* pLS = myIndex.ChangeSeek(aSTIm);
|
||||
if (!pLS) {
|
||||
pLS = &myIndex(myIndex.Add(aSTIm, TopTools_ListOfShape()));
|
||||
}
|
||||
pLS->Append(aS);
|
||||
//
|
||||
if (aMFence.Add(aSTIm)) {
|
||||
aBB.Add(anAllParts, aSTIm);
|
||||
}
|
||||
} // for (; aItIm.More(); aItIm.Next()) {
|
||||
} // for (; aExp.More(); aExp.Next()) {
|
||||
} // for (; itSub.More(); itSub.Next())
|
||||
} // for (; aIt.More(); aIt.Next()) {
|
||||
//
|
||||
myAllParts = anAllParts;
|
||||
|
@@ -75,7 +75,7 @@ void BOPAlgo_MakeConnected::CheckData()
|
||||
|
||||
TopTools_ListIteratorOfListOfShape itLA(myArguments);
|
||||
for (; itLA.More(); itLA.Next())
|
||||
BOPAlgo_Tools::TreatCompound(itLA.Value(), aMFence, aLA);
|
||||
BOPTools_AlgoTools::TreatCompound(itLA.Value(), aLA, &aMFence);
|
||||
|
||||
if (aLA.IsEmpty())
|
||||
{
|
||||
@@ -197,7 +197,7 @@ void BOPAlgo_MakeConnected::AssociateMaterials()
|
||||
// Extract all non-compound shapes from the result
|
||||
TopTools_ListOfShape aLShapes;
|
||||
TopTools_MapOfShape aMFence;
|
||||
BOPAlgo_Tools::TreatCompound(myShape, aMFence, aLShapes);
|
||||
BOPTools_AlgoTools::TreatCompound(myShape, aLShapes, &aMFence);
|
||||
|
||||
if (aLShapes.IsEmpty())
|
||||
return;
|
||||
|
@@ -342,7 +342,7 @@ void BOPAlgo_MakerVolume::FillInternalShapes(const TopTools_ListOfShape& theLSR)
|
||||
|
||||
TopTools_ListOfShape::Iterator itLA(myDS->Arguments());
|
||||
for (; itLA.More(); itLA.Next())
|
||||
BOPAlgo_Tools::TreatCompound(itLA.Value(), aMFence, aLSC);
|
||||
BOPTools_AlgoTools::TreatCompound(itLA.Value(), aLSC, &aMFence);
|
||||
|
||||
// Get only edges and vertices from arguments
|
||||
TopTools_ListOfShape aLVE;
|
||||
|
@@ -181,7 +181,7 @@ void BOPAlgo_RemoveFeatures::CheckData()
|
||||
TopTools_ListOfShape aShapes;
|
||||
TopTools_MapOfShape aMFence;
|
||||
// Extract all shapes from the compound
|
||||
BOPAlgo_Tools::TreatCompound(myInputShape, aMFence, aShapes);
|
||||
BOPTools_AlgoTools::TreatCompound(myInputShape, aShapes, &aMFence);
|
||||
if (aShapes.IsEmpty())
|
||||
{
|
||||
// Add error of empty input shape
|
||||
|
@@ -1103,29 +1103,6 @@ void BOPAlgo_Tools::IntersectVertices(const TopTools_IndexedDataMapOfShapeReal&
|
||||
}
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : TreatCompound
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void BOPAlgo_Tools::TreatCompound(const TopoDS_Shape& theS,
|
||||
TopTools_MapOfShape& aMFence,
|
||||
TopTools_ListOfShape& theLS)
|
||||
{
|
||||
TopAbs_ShapeEnum aType = theS.ShapeType();
|
||||
if (aType != TopAbs_COMPOUND)
|
||||
{
|
||||
if (aMFence.Add(theS))
|
||||
theLS.Append(theS);
|
||||
return;
|
||||
}
|
||||
TopoDS_Iterator aIt(theS);
|
||||
for (; aIt.More(); aIt.Next())
|
||||
{
|
||||
const TopoDS_Shape& aS = aIt.Value();
|
||||
TreatCompound(aS, aMFence, theLS);
|
||||
}
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
// Classification of the faces relatively solids
|
||||
//=======================================================================
|
||||
|
@@ -165,13 +165,6 @@ public:
|
||||
const Standard_Real theFuzzyValue,
|
||||
TopTools_ListOfListOfShape& theChains);
|
||||
|
||||
//! Collect in the output list recursively all non-compound subshapes of the first level
|
||||
//! of the given shape theS. If a shape presents in the map theMFence it is skipped.
|
||||
//! All shapes put in the output are also added into theMFence.
|
||||
Standard_EXPORT static void TreatCompound(const TopoDS_Shape& theS,
|
||||
TopTools_MapOfShape& theMFence,
|
||||
TopTools_ListOfShape& theLS);
|
||||
|
||||
//! Classifies the faces <theFaces> relatively solids <theSolids>.
|
||||
//! The IN faces for solids are stored into output data map <theInParts>.
|
||||
//!
|
||||
|
@@ -32,6 +32,7 @@
|
||||
#include <TopAbs_ShapeEnum.hxx>
|
||||
#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
|
||||
#include <TopTools_IndexedMapOfShape.hxx>
|
||||
#include <TopTools_MapOfShape.hxx>
|
||||
#include <TopTools_ListOfListOfShape.hxx>
|
||||
#include <TopTools_ListOfShape.hxx>
|
||||
#include <Precision.hxx>
|
||||
@@ -552,9 +553,22 @@ public: //! @name Other methods
|
||||
const TopoDS_Edge& aE,
|
||||
const Handle(IntTools_Context)& aContext);
|
||||
|
||||
//! Retutns dimension of the shape <theS>.
|
||||
//! Returns the min and max dimensions of the shape <theS>.
|
||||
Standard_EXPORT static void Dimensions (const TopoDS_Shape& theS,
|
||||
Standard_Integer& theDMin,
|
||||
Standard_Integer& theDMax);
|
||||
|
||||
//! Returns dimension of the shape <theS>.
|
||||
//! If the shape contains elements of different dimension, -1 is returned.
|
||||
Standard_EXPORT static Standard_Integer Dimension(const TopoDS_Shape& theS);
|
||||
|
||||
//! Collects in the output list recursively all non-compound sub-shapes of the first level
|
||||
//! of the given shape theS. The optional map theMap is used to avoid the duplicates in the
|
||||
//! output list, so it will also contain all non-compound sub-shapes.
|
||||
Standard_EXPORT static void TreatCompound (const TopoDS_Shape& theS,
|
||||
TopTools_ListOfShape& theList,
|
||||
TopTools_MapOfShape* theMap = NULL);
|
||||
|
||||
//! Returns true if the shell <theShell> is open
|
||||
Standard_EXPORT static Standard_Boolean IsOpenShell(const TopoDS_Shell& theShell);
|
||||
|
||||
|
@@ -34,10 +34,6 @@
|
||||
#include <TopoDS_Solid.hxx>
|
||||
#include <TopoDS_Vertex.hxx>
|
||||
|
||||
static
|
||||
void TreatCompound(const TopoDS_Shape& theC1,
|
||||
TopTools_ListOfShape& theLSX);
|
||||
|
||||
//=======================================================================
|
||||
// function: UpdateVertex
|
||||
// purpose:
|
||||
@@ -437,103 +433,101 @@ void BOPTools_AlgoTools::CorrectRange(const TopoDS_Edge& aE,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
namespace
|
||||
{
|
||||
|
||||
//=======================================================================
|
||||
//function : dimension
|
||||
//purpose : returns dimension of elementary shape
|
||||
//=======================================================================
|
||||
static Standard_Integer dimension (const TopoDS_Shape& theS)
|
||||
{
|
||||
switch (theS.ShapeType())
|
||||
{
|
||||
case TopAbs_VERTEX:
|
||||
return 0;
|
||||
case TopAbs_EDGE:
|
||||
case TopAbs_WIRE:
|
||||
return 1;
|
||||
case TopAbs_FACE:
|
||||
case TopAbs_SHELL:
|
||||
return 2;
|
||||
case TopAbs_SOLID:
|
||||
case TopAbs_COMPSOLID:
|
||||
return 3;
|
||||
default:
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : Dimensions
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void BOPTools_AlgoTools::Dimensions (const TopoDS_Shape& theS,
|
||||
Standard_Integer& theDMin,
|
||||
Standard_Integer& theDMax)
|
||||
{
|
||||
theDMin = theDMax = dimension (theS);
|
||||
if (theDMax >= 0)
|
||||
return;
|
||||
|
||||
TopTools_ListOfShape aLS;
|
||||
TopTools_MapOfShape aMFence;
|
||||
TreatCompound (theS, aLS, &aMFence);
|
||||
if (aLS.IsEmpty())
|
||||
{
|
||||
// empty shape
|
||||
theDMin = theDMax = -1;
|
||||
return;
|
||||
}
|
||||
|
||||
theDMin = 3;
|
||||
theDMax = 0;
|
||||
for (TopTools_ListOfShape::Iterator it (aLS); it.More(); it.Next())
|
||||
{
|
||||
Standard_Integer aDim = dimension (it.Value());
|
||||
if (aDim < theDMin)
|
||||
theDMin = aDim;
|
||||
if (aDim > theDMax)
|
||||
theDMax = aDim;
|
||||
}
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : Dimension
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
Standard_Integer BOPTools_AlgoTools::Dimension(const TopoDS_Shape& theS)
|
||||
{
|
||||
Standard_Integer i, iRet, iRx0 = 0, iRx = 0;
|
||||
TopAbs_ShapeEnum aTS;
|
||||
TopTools_ListOfShape aLS;
|
||||
TopTools_ListIteratorOfListOfShape aIt;
|
||||
//
|
||||
aTS=theS.ShapeType();
|
||||
if (aTS!=TopAbs_COMPOUND) {
|
||||
switch (aTS) {
|
||||
case TopAbs_EDGE:
|
||||
case TopAbs_WIRE:
|
||||
iRet=1;
|
||||
break;
|
||||
case TopAbs_FACE:
|
||||
case TopAbs_SHELL:
|
||||
iRet=2;
|
||||
break;
|
||||
case TopAbs_SOLID:
|
||||
case TopAbs_COMPSOLID:
|
||||
iRet=3;
|
||||
break;
|
||||
default:
|
||||
iRet=0;
|
||||
}
|
||||
return iRet;
|
||||
}
|
||||
//
|
||||
iRet=-1;
|
||||
TreatCompound(theS, aLS);
|
||||
if(aLS.IsEmpty()) {
|
||||
iRet = -2; //empty compound
|
||||
return iRet;
|
||||
}
|
||||
aIt.Initialize(aLS);
|
||||
for (i=0; aIt.More(); aIt.Next()) {
|
||||
const TopoDS_Shape& aSx=aIt.Value();
|
||||
iRx=Dimension(aSx);
|
||||
if (!i) {
|
||||
iRx0=iRx;
|
||||
i=1;
|
||||
continue;
|
||||
}
|
||||
if (iRx!=iRx0) {
|
||||
return iRet;// -1
|
||||
}
|
||||
}
|
||||
return iRx;
|
||||
Standard_Integer aDMin, aDMax;
|
||||
Dimensions (theS, aDMin, aDMax);
|
||||
return (aDMin == aDMax) ? aDMin : -1;
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : TreatCompound
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void TreatCompound(const TopoDS_Shape& theC1,
|
||||
TopTools_ListOfShape& theLSX)
|
||||
void BOPTools_AlgoTools::TreatCompound (const TopoDS_Shape& theS,
|
||||
TopTools_ListOfShape& theLS,
|
||||
TopTools_MapOfShape* theMFence)
|
||||
{
|
||||
Standard_Integer aNbC1;
|
||||
TopAbs_ShapeEnum aType;
|
||||
TopTools_ListOfShape aLC, aLC1;
|
||||
TopTools_ListIteratorOfListOfShape aIt, aIt1;
|
||||
TopoDS_Iterator aItC;
|
||||
//
|
||||
aLC.Append (theC1);
|
||||
for(;;) {
|
||||
aLC1.Clear();
|
||||
aIt.Initialize(aLC);
|
||||
for (; aIt.More(); aIt.Next()) {
|
||||
const TopoDS_Shape& aC=aIt.Value(); //C is compound
|
||||
//
|
||||
aItC.Initialize(aC);
|
||||
for (; aItC.More(); aItC.Next()) {
|
||||
const TopoDS_Shape& aS=aItC.Value();
|
||||
aType=aS.ShapeType();
|
||||
if (aType==TopAbs_COMPOUND) {
|
||||
aLC1.Append(aS);
|
||||
}
|
||||
else {
|
||||
theLSX.Append(aS);
|
||||
}
|
||||
}
|
||||
TopAbs_ShapeEnum aType = theS.ShapeType();
|
||||
if (aType != TopAbs_COMPOUND)
|
||||
{
|
||||
if (!theMFence || theMFence->Add (theS))
|
||||
{
|
||||
theLS.Append (theS);
|
||||
}
|
||||
//
|
||||
aNbC1=aLC1.Extent();
|
||||
if (!aNbC1) {
|
||||
break;
|
||||
}
|
||||
//
|
||||
aLC.Clear();
|
||||
aIt.Initialize(aLC1);
|
||||
for (; aIt.More(); aIt.Next()) {
|
||||
const TopoDS_Shape& aSC=aIt.Value();
|
||||
aLC.Append(aSC);
|
||||
}
|
||||
}// while(1)
|
||||
return;
|
||||
}
|
||||
|
||||
for (TopoDS_Iterator it (theS); it.More(); it.Next())
|
||||
{
|
||||
TreatCompound (it.Value(), theLS, theMFence);
|
||||
}
|
||||
}
|
||||
|
@@ -111,7 +111,7 @@ void BSplCLib_Cache::CalculateDerivative(const Standard_Real& theParameter,
|
||||
// When the degree of curve is lesser than the requested derivative,
|
||||
// nullify array cells corresponding to greater derivatives
|
||||
Standard_Integer aDerivative = theDerivative;
|
||||
if (myParams.Degree < theDerivative)
|
||||
if (!myIsRational && myParams.Degree < theDerivative)
|
||||
{
|
||||
aDerivative = myParams.Degree;
|
||||
for (Standard_Integer ind = myParams.Degree * aDimension; ind < (theDerivative + 1) * aDimension; ind++)
|
||||
|
@@ -34,7 +34,8 @@ D3DHost_FrameBuffer::D3DHost_FrameBuffer()
|
||||
myGlD3dDevice (NULL),
|
||||
myGlD3dSurf (NULL),
|
||||
myLockCount (0),
|
||||
myD3dFallback (Standard_False)
|
||||
myD3dFallback (Standard_False),
|
||||
myIsSRGBReady (Standard_False)
|
||||
{
|
||||
//
|
||||
}
|
||||
@@ -277,6 +278,7 @@ void D3DHost_FrameBuffer::BindBuffer (const Handle(OpenGl_Context)& theCtx)
|
||||
}
|
||||
|
||||
OpenGl_FrameBuffer::BindBuffer (theCtx);
|
||||
theCtx->SetFrameBufferSRGB (true, myIsSRGBReady);
|
||||
if (myD3dFallback)
|
||||
{
|
||||
return;
|
||||
|
@@ -103,6 +103,13 @@ public:
|
||||
//! Returns TRUE if FBO has been initialized without WGL/D3D interop.
|
||||
Standard_Boolean D3dFallback() const { return myD3dFallback; }
|
||||
|
||||
//! Returns TRUE if color buffer is sRGB ready; FALSE by default.
|
||||
//! Requires D3DSAMP_SRGBTEXTURE sampler parameter being set on D3D level for rendering D3D surface.
|
||||
Standard_Boolean IsSRGBReady() const { return myIsSRGBReady; }
|
||||
|
||||
//! Set if color buffer is sRGB ready.
|
||||
void SetSRGBReady (Standard_Boolean theIsReady) { myIsSRGBReady = theIsReady; }
|
||||
|
||||
protected:
|
||||
|
||||
using OpenGl_FrameBuffer::Init;
|
||||
@@ -115,6 +122,7 @@ protected:
|
||||
void* myGlD3dSurf; //!< WGL/D3D surface handle
|
||||
Standard_Integer myLockCount; //!< locking counter
|
||||
Standard_Boolean myD3dFallback; //!< indicates that FBO has been initialized without WGL/D3D interop
|
||||
Standard_Boolean myIsSRGBReady; //!< indicates that color buffer is sRGB ready
|
||||
|
||||
public:
|
||||
|
||||
|
@@ -553,7 +553,7 @@ void Extrema_ExtCC::PrepareParallelResult(const Standard_Real theUt11,
|
||||
if ((aRange.Delta() > Precision::Angular()) &&
|
||||
((aPar2 - aPar1) < Precision::Angular()))
|
||||
{
|
||||
aPar1 -= aPeriod;
|
||||
aPar2 += aPeriod;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -562,11 +562,13 @@ void Extrema_ExtCC::PrepareParallelResult(const Standard_Real theUt11,
|
||||
|
||||
Standard_Real aMinSquareDist = RealLast();
|
||||
|
||||
aProjRng1.Add(aPar1 - M_PI);
|
||||
aProjRng1.Add(aPar2 - M_PI);
|
||||
for (Standard_Integer i = 0; i < 2; i++)
|
||||
aProjRng1.Add(aPar1 - aPeriod);
|
||||
aProjRng1.Add(aPar2 - aPeriod);
|
||||
for (Standard_Integer i = 0; i < 3; i++)
|
||||
{
|
||||
// Repeat computation twice
|
||||
// Repeat computation three times, shifting the range to PI on each step,
|
||||
// to be able to find if the concentric arcs ranges are intersected in just one parameter
|
||||
// (lower or upper boundary).
|
||||
|
||||
Bnd_Range aRng = aProjRng1;
|
||||
aRng.Common(aRange);
|
||||
|
@@ -16,6 +16,7 @@
|
||||
|
||||
|
||||
#include <Adaptor2d_Curve2d.hxx>
|
||||
#include <Geom2dAdaptor_Curve.hxx>
|
||||
#include <Geom2d_BezierCurve.hxx>
|
||||
#include <Geom2d_BSplineCurve.hxx>
|
||||
#include <Geom2d_Circle.hxx>
|
||||
@@ -88,7 +89,21 @@ Handle(Geom2d_Curve) Geom2dAdaptor::MakeCurve
|
||||
C2D = HC.BSpline();
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
case GeomAbs_OffsetCurve:
|
||||
{
|
||||
const Geom2dAdaptor_Curve* pGAC = dynamic_cast<const Geom2dAdaptor_Curve*>(&HC);
|
||||
if (pGAC != 0)
|
||||
{
|
||||
C2D = pGAC->Curve();
|
||||
}
|
||||
else
|
||||
{
|
||||
Standard_DomainError::Raise("Geom2dAdaptor::MakeCurve, Not Geom2dAdaptor_Curve");
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
throw Standard_DomainError("Geom2dAdaptor::MakeCurve, OtherCurve");
|
||||
|
||||
@@ -99,8 +114,19 @@ Handle(Geom2d_Curve) Geom2dAdaptor::MakeCurve
|
||||
((HC.FirstParameter() != C2D->FirstParameter()) ||
|
||||
(HC.LastParameter() != C2D->LastParameter()))) {
|
||||
|
||||
C2D = new Geom2d_TrimmedCurve
|
||||
(C2D,HC.FirstParameter(),HC.LastParameter());
|
||||
if (C2D->IsPeriodic() ||
|
||||
(HC.FirstParameter() >= C2D->FirstParameter() &&
|
||||
HC.LastParameter() <= C2D->LastParameter()))
|
||||
{
|
||||
C2D = new Geom2d_TrimmedCurve
|
||||
(C2D, HC.FirstParameter(), HC.LastParameter());
|
||||
}
|
||||
else
|
||||
{
|
||||
Standard_Real tf = Max(HC.FirstParameter(), C2D->FirstParameter());
|
||||
Standard_Real tl = Min(HC.LastParameter(), C2D->LastParameter());
|
||||
C2D = new Geom2d_TrimmedCurve(C2D, tf, tl);
|
||||
}
|
||||
}
|
||||
|
||||
return C2D;
|
||||
|
@@ -58,10 +58,6 @@ proc ApplicationFramework:depends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc ApplicationFramework:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -56,10 +56,6 @@ proc DataExchange:depends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc DataExchange:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -58,10 +58,6 @@ proc Draw:acdepends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc Draw:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -52,10 +52,6 @@ proc FoundationClasses:depends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc FoundationClasses:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -50,10 +50,6 @@ proc ModelingAlgorithms:depends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc ModelingAlgorithms:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -42,10 +42,6 @@ proc ModelingData:depends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc ModelingData:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
41
src/OS/TApplicationFramework.tcl
Normal file
41
src/OS/TApplicationFramework.tcl
Normal file
@@ -0,0 +1,41 @@
|
||||
# Copyright (c) 2020 OPEN CASCADE SAS
|
||||
#
|
||||
# This file is part of Open CASCADE Technology software library.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
# by the Free Software Foundation, with special exception defined in the file
|
||||
# OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
# distribution for complete text of the license and disclaimer of any warranty.
|
||||
#
|
||||
# Alternatively, this file may be used under the terms of Open CASCADE
|
||||
# commercial license or contractual agreement.
|
||||
|
||||
# List of toolkits
|
||||
proc TApplicationFramework:toolkits { } {
|
||||
return [list TKTreeModel TKTInspectorAPI TKDFBrowser]
|
||||
}
|
||||
|
||||
# List of non-toolkits (resource units, executables etc., with associated info)
|
||||
proc TApplicationFramework:ressources { } {
|
||||
}
|
||||
|
||||
# Module name
|
||||
proc TApplicationFramework:name { } {
|
||||
return TApplicationFramework
|
||||
}
|
||||
|
||||
# And short alias
|
||||
proc TApplicationFramework:alias { } {
|
||||
return TApplicationFramework
|
||||
}
|
||||
|
||||
# Dependency on other products
|
||||
proc TApplicationFramework:depends { } {
|
||||
return [list ApplicationFramework FoundationClasses DataExchange TModelingData Visualization]
|
||||
}
|
||||
|
||||
# Returns a list of exported features.
|
||||
proc TApplicationFramework:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
}
|
41
src/OS/TModelingData.tcl
Normal file
41
src/OS/TModelingData.tcl
Normal file
@@ -0,0 +1,41 @@
|
||||
# Copyright (c) 2020 OPEN CASCADE SAS
|
||||
#
|
||||
# This file is part of Open CASCADE Technology software library.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
# by the Free Software Foundation, with special exception defined in the file
|
||||
# OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
# distribution for complete text of the license and disclaimer of any warranty.
|
||||
#
|
||||
# Alternatively, this file may be used under the terms of Open CASCADE
|
||||
# commercial license or contractual agreement.
|
||||
|
||||
# List of toolkits
|
||||
proc TModelingData:toolkits { } {
|
||||
return [list TKShapeView]
|
||||
}
|
||||
|
||||
# List of non-toolkits (resource units, executables etc., with associated info)
|
||||
proc TModelingData:ressources { } {
|
||||
}
|
||||
|
||||
# Module name
|
||||
proc TModelingData:name { } {
|
||||
return TModelingData
|
||||
}
|
||||
|
||||
# And short alias
|
||||
proc TModelingData:alias { } {
|
||||
return TModelingData
|
||||
}
|
||||
|
||||
# Dependency on other products
|
||||
proc TModelingData:depends { } {
|
||||
return [list FoundationClasses ModelingData TVisualization]
|
||||
}
|
||||
|
||||
# Returns a list of exported features.
|
||||
proc TModelingData:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
}
|
44
src/OS/TTool.tcl
Normal file
44
src/OS/TTool.tcl
Normal file
@@ -0,0 +1,44 @@
|
||||
# Copyright (c) 2020 OPEN CASCADE SAS
|
||||
#
|
||||
# This file is part of Open CASCADE Technology software library.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
# by the Free Software Foundation, with special exception defined in the file
|
||||
# OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
# distribution for complete text of the license and disclaimer of any warranty.
|
||||
#
|
||||
# Alternatively, this file may be used under the terms of Open CASCADE
|
||||
# commercial license or contractual agreement.
|
||||
|
||||
# List of toolkits
|
||||
proc TTool:toolkits { } {
|
||||
return [list TKTInspector TKToolsDraw]
|
||||
}
|
||||
|
||||
# List of non-toolkits (resource units, executables etc., with associated info)
|
||||
proc TTool:ressources { } {
|
||||
return [list \
|
||||
[list both x TInspectorEXE {}] \
|
||||
]
|
||||
}
|
||||
|
||||
# Module name
|
||||
proc TTool:name { } {
|
||||
return TTool
|
||||
}
|
||||
|
||||
# And short alias
|
||||
proc TTool:alias { } {
|
||||
return TTool
|
||||
}
|
||||
|
||||
# Dependency on other products
|
||||
proc TTool:depends { } {
|
||||
return [list FoundationClasses Draw TApplicationFramework]
|
||||
}
|
||||
|
||||
# Returns a list of exported features.
|
||||
proc TTool:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
}
|
41
src/OS/TVisualization.tcl
Normal file
41
src/OS/TVisualization.tcl
Normal file
@@ -0,0 +1,41 @@
|
||||
# Copyright (c) 2020 OPEN CASCADE SAS
|
||||
#
|
||||
# This file is part of Open CASCADE Technology software library.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
# by the Free Software Foundation, with special exception defined in the file
|
||||
# OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
# distribution for complete text of the license and disclaimer of any warranty.
|
||||
#
|
||||
# Alternatively, this file may be used under the terms of Open CASCADE
|
||||
# commercial license or contractual agreement.
|
||||
|
||||
# List of toolkits
|
||||
proc TVisualization:toolkits { } {
|
||||
return [list TKView TKVInspector]
|
||||
}
|
||||
|
||||
# List of non-toolkits (resource units, executables etc., with associated info)
|
||||
proc TVisualization:ressources { } {
|
||||
}
|
||||
|
||||
# Module name
|
||||
proc TVisualization:name { } {
|
||||
return TVisualization
|
||||
}
|
||||
|
||||
# And short alias
|
||||
proc TVisualization:alias { } {
|
||||
return TVisualization
|
||||
}
|
||||
|
||||
# Dependency on other products
|
||||
proc TVisualization:depends { } {
|
||||
return [list FoundationClasses]
|
||||
}
|
||||
|
||||
# Returns a list of exported features.
|
||||
proc TVisualization:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
}
|
24
src/OS/Tools.tcl
Normal file
24
src/OS/Tools.tcl
Normal file
@@ -0,0 +1,24 @@
|
||||
# Copyright (c) 2020 OPEN CASCADE SAS
|
||||
#
|
||||
# This file is part of Open CASCADE Technology software library.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
# by the Free Software Foundation, with special exception defined in the file
|
||||
# OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
# distribution for complete text of the license and disclaimer of any warranty.
|
||||
#
|
||||
# Alternatively, this file may be used under the terms of Open CASCADE
|
||||
# commercial license or contractual agreement.
|
||||
|
||||
;#
|
||||
;# Returns an ordered list of module names
|
||||
;#
|
||||
proc OS:Modules { {plat ""} } {
|
||||
set ret [list TModelingData \
|
||||
TVisualization \
|
||||
TApplicationFramework \
|
||||
TTool \
|
||||
]
|
||||
return $ret
|
||||
}
|
@@ -70,10 +70,6 @@ proc Visualization:acdepends { } {
|
||||
|
||||
;#
|
||||
;# Returns a list of exported features.
|
||||
;# source : Source files
|
||||
;# runtime: Shareables
|
||||
;# wokadm : WOK admin files
|
||||
;# api : Public include files
|
||||
;#
|
||||
proc Visualization:Export { } {
|
||||
return [list source runtime wokadm api]
|
||||
|
@@ -517,7 +517,7 @@ void OpenGl_Context::SetDrawBuffers (const Standard_Integer theNb, const Standar
|
||||
// function : SetFrameBufferSRGB
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void OpenGl_Context::SetFrameBufferSRGB (bool theIsFbo)
|
||||
void OpenGl_Context::SetFrameBufferSRGB (bool theIsFbo, bool theIsFboSRgb)
|
||||
{
|
||||
if (!hasFboSRGB)
|
||||
{
|
||||
@@ -525,7 +525,8 @@ void OpenGl_Context::SetFrameBufferSRGB (bool theIsFbo)
|
||||
return;
|
||||
}
|
||||
myIsSRgbActive = ToRenderSRGB()
|
||||
&& (theIsFbo || myIsSRgbWindow);
|
||||
&& (theIsFbo || myIsSRgbWindow)
|
||||
&& theIsFboSRgb;
|
||||
if (!hasSRGBControl)
|
||||
{
|
||||
return;
|
||||
|
@@ -584,6 +584,9 @@ public:
|
||||
//! (GL_FRAMEBUFFER_SRGB can be considered as always tuned ON).
|
||||
bool IsWindowSRGB() const { return myIsSRgbWindow; }
|
||||
|
||||
//! Overrides if window/surface buffer is sRGB-ready or not (initialized with the context).
|
||||
void SetWindowSRGB (bool theIsSRgb) { myIsSRgbWindow = theIsSRgb; }
|
||||
|
||||
//! Convert Quantity_ColorRGBA into vec4
|
||||
//! with conversion or no conversion into non-linear sRGB
|
||||
//! basing on ToRenderSRGB() flag.
|
||||
@@ -794,7 +797,8 @@ public: //! @name methods to alter or retrieve current state
|
||||
//! - FALSE if sRGB rendering is not supported or sRGB-not-ready window buffer is used for drawing.
|
||||
//! @param theIsFbo [in] flag indicating writing into offscreen FBO (always expected sRGB-ready when sRGB FBO is supported)
|
||||
//! or into window buffer (FALSE, sRGB-readiness might vary).
|
||||
Standard_EXPORT void SetFrameBufferSRGB (bool theIsFbo);
|
||||
//! @param theIsSRgb [in] flag indicating off-screen FBO is sRGB-ready
|
||||
Standard_EXPORT void SetFrameBufferSRGB (bool theIsFbo, bool theIsFboSRgb = true);
|
||||
|
||||
//! Return cached flag indicating writing into color buffer is enabled or disabled (glColorMask).
|
||||
bool ColorMask() const { return myColorMask; }
|
||||
|
@@ -60,6 +60,9 @@ public:
|
||||
//! Return TRUE if primitive type generates shaded triangulation (to be used in filters).
|
||||
virtual Standard_Boolean IsFillDrawMode() const { return false; }
|
||||
|
||||
//! Returns estimated GPU memory usage for holding data without considering overheads and allocation alignment rules.
|
||||
virtual Standard_Size EstimatedDataSize() const { return 0; }
|
||||
|
||||
//! Update parameters of the drawable elements.
|
||||
virtual void SynchronizeAspects() {}
|
||||
|
||||
|
@@ -207,11 +207,7 @@ void OpenGl_FrameStats::updateStructures (Standard_Integer theViewId,
|
||||
const OpenGl_Group* aGroup = aGroupIter.Value();
|
||||
for (const OpenGl_ElementNode* aNodeIter = aGroup->FirstNode(); aNodeIter != NULL; aNodeIter = aNodeIter->next)
|
||||
{
|
||||
if (const OpenGl_PrimitiveArray* aPrim = dynamic_cast<const OpenGl_PrimitiveArray*> (aNodeIter->elem))
|
||||
{
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += estimatedDataSize (aPrim->AttributesVbo());
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += estimatedDataSize (aPrim->IndexVbo());
|
||||
}
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += aNodeIter->elem->EstimatedDataSize();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -229,15 +225,13 @@ void OpenGl_FrameStats::updateStructures (Standard_Integer theViewId,
|
||||
const OpenGl_Group* aGroup = aGroupIter.Value();
|
||||
for (const OpenGl_ElementNode* aNodeIter = aGroup->FirstNode(); aNodeIter != NULL; aNodeIter = aNodeIter->next)
|
||||
{
|
||||
if (theToCountMem)
|
||||
{
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += aNodeIter->elem->EstimatedDataSize();
|
||||
}
|
||||
if (const OpenGl_PrimitiveArray* aPrim = dynamic_cast<const OpenGl_PrimitiveArray*> (aNodeIter->elem))
|
||||
{
|
||||
++myCountersTmp[Graphic3d_FrameStatsCounter_NbElemsNotCulled];
|
||||
if (theToCountMem)
|
||||
{
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += estimatedDataSize (aPrim->AttributesVbo());
|
||||
myCountersTmp[Graphic3d_FrameStatsCounter_EstimatedBytesGeom] += estimatedDataSize (aPrim->IndexVbo());
|
||||
}
|
||||
|
||||
if (aPrim->IsFillDrawMode())
|
||||
{
|
||||
++myCountersTmp[Graphic3d_FrameStatsCounter_NbElemsFillNotCulled];
|
||||
|
@@ -758,6 +758,24 @@ void OpenGl_PrimitiveArray::Release (OpenGl_Context* theContext)
|
||||
}
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : EstimatedDataSize
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
Standard_Size OpenGl_PrimitiveArray::EstimatedDataSize() const
|
||||
{
|
||||
Standard_Size aSize = 0;
|
||||
if (!myVboAttribs.IsNull())
|
||||
{
|
||||
aSize += myVboAttribs->EstimatedDataSize();
|
||||
}
|
||||
if (!myVboIndices.IsNull())
|
||||
{
|
||||
aSize += myVboIndices->EstimatedDataSize();
|
||||
}
|
||||
return aSize;
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : Render
|
||||
// purpose :
|
||||
|
@@ -58,6 +58,9 @@ public:
|
||||
//! Release OpenGL resources (VBOs)
|
||||
Standard_EXPORT virtual void Release (OpenGl_Context* theContext) Standard_OVERRIDE;
|
||||
|
||||
//! Returns estimated GPU memory usage for holding data without considering overheads and allocation alignment rules.
|
||||
Standard_EXPORT virtual Standard_Size EstimatedDataSize() const Standard_OVERRIDE;
|
||||
|
||||
//! Return true if VBOs initialization has been performed.
|
||||
//! VBO initialization is performed during first Render() call.
|
||||
//! Notice that this flag does not indicate VBOs validity.
|
||||
|
@@ -206,6 +206,31 @@ void OpenGl_Text::Release (OpenGl_Context* theCtx)
|
||||
}
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : EstimatedDataSize
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
Standard_Size OpenGl_Text::EstimatedDataSize() const
|
||||
{
|
||||
Standard_Size aSize = 0;
|
||||
for (Standard_Integer anIter = myVertsVbo.Lower(); anIter <= myVertsVbo.Upper(); ++anIter)
|
||||
{
|
||||
if (const Handle(OpenGl_VertexBuffer)& aVerts = myVertsVbo.Value (anIter))
|
||||
{
|
||||
aSize += aVerts->EstimatedDataSize();
|
||||
}
|
||||
if (const Handle(OpenGl_VertexBuffer)& aTCrds = myTCrdsVbo.Value (anIter))
|
||||
{
|
||||
aSize += aTCrds->EstimatedDataSize();
|
||||
}
|
||||
}
|
||||
if (!myBndVertsVbo.IsNull())
|
||||
{
|
||||
aSize += myBndVertsVbo->EstimatedDataSize();
|
||||
}
|
||||
return aSize;
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : StringSize
|
||||
// purpose :
|
||||
|
@@ -68,6 +68,9 @@ public:
|
||||
Standard_EXPORT virtual void Render (const Handle(OpenGl_Workspace)& theWorkspace) const Standard_OVERRIDE;
|
||||
Standard_EXPORT virtual void Release (OpenGl_Context* theContext) Standard_OVERRIDE;
|
||||
|
||||
//! Returns estimated GPU memory usage for holding data without considering overheads and allocation alignment rules.
|
||||
Standard_EXPORT virtual Standard_Size EstimatedDataSize() const Standard_OVERRIDE;
|
||||
|
||||
public: //! @name methods for compatibility with layers
|
||||
|
||||
//! Empty constructor
|
||||
|
@@ -214,18 +214,17 @@ public:
|
||||
//! @return text presentation
|
||||
Standard_EXPORT static TCollection_AsciiString FormatJson (const Standard_SStream& theStream, const Standard_Integer theIndent = 3);
|
||||
|
||||
//! Converts stream into map of values. Values are not empty if the stream contains at least two values.
|
||||
//! Converts stream into map of values.
|
||||
//!
|
||||
//! The one level stream example: <class_name>key_1\value_1\key_2\value_2</class_name>
|
||||
//! In output: theStreamKey equals class_name, theValues contains key_1, value_1, key_2, and value_2.
|
||||
//! The one level stream example: 'key_1: value_1, key_2: value_2'
|
||||
//! In output: values contain 'key_1: value_1' and 'key_2: value_2'.
|
||||
//!
|
||||
//! Two level stream example: <class_name>key_1\value_1\key_2\value_2\key_3<subclass_name>subclass_key_1\subclass_value1</subclass_name></class_name>
|
||||
//! In output: theStreamKey equals class_name, theValues contains key_1, value_1, key_2, and value_2, key_3 and
|
||||
//! <subclass_name>subclass_key_1\subclass_value1</subclass_name>.
|
||||
//! The last value might be processed later using the same method.
|
||||
//! The two level stream example: 'key_1: value_1, key_2: value_2, key_3: {sublevel_key_1: sublevel_value_1}, key_4: value_4'
|
||||
//! In output values contain 'key_1: value_1', 'key_2: value_2', 'key_3: {sublevel_key_1: sublevel_value_1}' and 'key_4: value_4'.
|
||||
//! The sublevel value might be processed later using the same method.
|
||||
//!
|
||||
//! @param theStream stream value
|
||||
//! @param theKeyToValues [out] container of split values
|
||||
//! @param theStreamStr stream value
|
||||
//! @param theKeyToValues [out] container of split values. It contains key to value and position of the value in the stream text
|
||||
Standard_EXPORT static Standard_Boolean SplitJson (const TCollection_AsciiString& theStreamStr,
|
||||
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue>& theKeyToValues);
|
||||
|
||||
|
@@ -1052,7 +1052,7 @@ void TPrsStd_AISPresentation::ActivateSelectionMode()
|
||||
}
|
||||
}
|
||||
if (!isActivated)
|
||||
aContext->Activate(myAIS, aSelectionMode, Standard_False);
|
||||
aContext->SetSelectionModeActive(myAIS, aSelectionMode, Standard_True, AIS_SelectionModesConcurrency_Multiple);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -1061,7 +1061,7 @@ void TPrsStd_AISPresentation::ActivateSelectionMode()
|
||||
{
|
||||
const Standard_Integer aSelectionMode = SelectionMode (iSelMode);
|
||||
aContext->SetSelectionModeActive (myAIS, aSelectionMode, Standard_True/*activate*/,
|
||||
iSelMode == 1 ? AIS_SelectionModesConcurrency_Single : AIS_SelectionModesConcurrency_GlobalOrLocal);
|
||||
iSelMode == 1 ? AIS_SelectionModesConcurrency_Single : AIS_SelectionModesConcurrency_Multiple);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -128,8 +128,12 @@ Standard_Boolean XmlMDataStd_RealArrayDriver::Paste
|
||||
" for RealArray attribute as \"")
|
||||
+ aValueStr + "\"";
|
||||
myMessageDriver->Send (aMessageString, Message_Warning);
|
||||
// skip the first space, if exists
|
||||
while (*aValueStr != 0 && IsSpace (*aValueStr))
|
||||
++aValueStr;
|
||||
// skip to the next space separator
|
||||
while (*aValueStr != 0 && ! IsSpace (*aValueStr)) ++aValueStr;
|
||||
while (*aValueStr != 0 && ! IsSpace (*aValueStr))
|
||||
++aValueStr;
|
||||
}
|
||||
aRealArray->SetValue(ind, aValue);
|
||||
}
|
||||
|
@@ -126,8 +126,12 @@ Standard_Boolean XmlMDataStd_RealListDriver::Paste(const XmlObjMgt_Persistent&
|
||||
" for RealList attribute as \"")
|
||||
+ aValueStr + "\"";
|
||||
myMessageDriver->Send(aMessageString, Message_Warning);
|
||||
// skip the first space, if exists
|
||||
while (*aValueStr != 0 && IsSpace (*aValueStr))
|
||||
++aValueStr;
|
||||
// skip to the next space separator
|
||||
while (*aValueStr != 0 && ! IsSpace (*aValueStr)) ++aValueStr;
|
||||
while (*aValueStr != 0 && !IsSpace (*aValueStr))
|
||||
++aValueStr;
|
||||
}
|
||||
aRealList->Append(aValue);
|
||||
}
|
||||
|
@@ -1,4 +1,4 @@
|
||||
puts "TODO #OCC26740 ALL: Faulty shapes in variables faulty_1 to faulty_2"
|
||||
#puts "TODO #OCC26740 ALL: Faulty shapes in variables faulty_1 to faulty_2"
|
||||
|
||||
## ===========================================
|
||||
## Grid : CCV001
|
||||
|
@@ -18,6 +18,7 @@ set res [Open $file D]
|
||||
set real [GetReal D 0:1]
|
||||
set rlst [GetRealList D 0:1]
|
||||
set rarr [GetRealArray D 0:1]
|
||||
set rarr2 [GetRealArray D 0:2]
|
||||
|
||||
# Check for read values
|
||||
checkreal "Real value" [lindex $rlst 0] 1.1 0 1e-15
|
||||
@@ -25,6 +26,9 @@ checkreal "Real value" [lindex $rlst 2] 3.3 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr 0] 0.111 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr 3] 123. 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr 4] 3.14e12 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr2 0] 2 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr2 1] 2.1219957909652723e-314 0 1e-15
|
||||
checkreal "Real value" [lindex $rarr2 2] 5 0 1e-15
|
||||
foreach inf [list $real [lindex $rlst 3]] {
|
||||
if { [string compare "$inf" "inf"] &&
|
||||
[string compare "$inf" "infinity"] &&
|
||||
|
15
tests/bugs/fclasses/bug31381
Normal file
15
tests/bugs/fclasses/bug31381
Normal file
@@ -0,0 +1,15 @@
|
||||
puts "# ============"
|
||||
puts "# 0031381: Foundation Classes - wrong evaluations for rational BSpline curves using Adaptor curves "
|
||||
puts "# ============"
|
||||
puts ""
|
||||
puts "Eliminate output of approxcurve command"
|
||||
puts "REQUIRED ALL: Error 4.32754e-05"
|
||||
|
||||
circle c 0 0 1
|
||||
puts "Get rational BSpline curve of degree 2"
|
||||
convert c c
|
||||
puts "Get offset curve to force calculation of D3 for base curve when algorithm needs D2 for offset"
|
||||
offset oc c -.5
|
||||
puts "Approximate offset curve with continuity C2"
|
||||
approxcurve ac oc 1.e-4 2 5 25
|
||||
checklength ac -l 3.1415850499856011
|
@@ -20,7 +20,7 @@ vsetdispmode result 1
|
||||
vdisplay result
|
||||
vfit
|
||||
|
||||
checktrinfo result -tri 5814 -nod 5811
|
||||
checktrinfo result -tri 5812 -nod 5809
|
||||
|
||||
checkmaxtol result -ref 0.92213088179312575
|
||||
checknbshapes result -shell 1
|
||||
|
@@ -20,7 +20,7 @@ vdisplay result
|
||||
|
||||
# checkshape res
|
||||
|
||||
checkmaxtol result -ref 1.56901e+001
|
||||
checkmaxtol result -ref 1.098308e+001
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 115
|
||||
|
||||
|
@@ -14,7 +14,7 @@ sewing result +t 0.01 a b +mint 0.01 -a
|
||||
|
||||
set nbshapes_expected "
|
||||
Number of shapes in shape
|
||||
VERTEX : 479
|
||||
VERTEX : 480
|
||||
EDGE : 748
|
||||
WIRE : 273
|
||||
FACE : 259
|
||||
@@ -22,11 +22,11 @@ Number of shapes in shape
|
||||
SOLID : 0
|
||||
COMPSOLID : 0
|
||||
COMPOUND : 1
|
||||
SHAPE : 1762
|
||||
SHAPE : 1763
|
||||
"
|
||||
checknbshapes result -ref ${nbshapes_expected} -t -m "sewing result"
|
||||
checkmaxtol result -ref 0.066338232054955981
|
||||
checkfreebounds result 12
|
||||
checkmaxtol result -ref 0.04656161000546645
|
||||
checkfreebounds result 14
|
||||
|
||||
checkprops result -s 1.8847e+07 -eps 0.1
|
||||
checkshape result
|
||||
|
@@ -16,7 +16,7 @@ checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 476 -edge 748 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1759
|
||||
checkmaxtol result -ref 0.066338232054955981
|
||||
checkmaxtol result -ref 0.04656161000546645
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 6
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -32,7 +32,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 964 -edge 1222 -wire 273 -face 259 -shell 18 -solid 0 -compsolid 0 -compound 1 -shape 2737
|
||||
checkmaxtol result -ref 0.046734236640099257
|
||||
checkmaxtol result -ref 0.0451323239933289
|
||||
checknbshapes result -shell 18
|
||||
checkfreebounds result 926
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -32,7 +32,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 964 -edge 1222 -wire 273 -face 259 -shell 18 -solid 0 -compsolid 0 -compound 1 -shape 2737
|
||||
checkmaxtol result -ref 0.046734236640099257
|
||||
checkmaxtol result -ref 0.0451323239933289
|
||||
checknbshapes result -shell 18
|
||||
checkfreebounds result 926
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -19,7 +19,7 @@ checkprops result -s 12
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 4 -edge 4 -wire 2 -face 2 -shell 1 -solid 0 -compsolid 0 -compound 0 -shape 13
|
||||
checkmaxtol result -ref 1.5
|
||||
checkmaxtol result -ref 1.05
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -19,7 +19,7 @@ checkprops result -s 12
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 4 -edge 4 -wire 2 -face 2 -shell 1 -solid 0 -compsolid 0 -compound 0 -shape 13
|
||||
checkmaxtol result -ref 1.5
|
||||
checkmaxtol result -ref 1.05
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -17,7 +17,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 480 -edge 741 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1756
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -19,7 +19,7 @@ checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 476 -edge 748 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1759
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -1,4 +1,4 @@
|
||||
puts "TODO OCC11111 ALL: Error : is WRONG because number of "
|
||||
#puts "TODO OCC11111 ALL: Error : is WRONG because number of "
|
||||
|
||||
puts "================"
|
||||
puts "OCC22770"
|
||||
@@ -18,8 +18,8 @@ sewing result 0.1 a b +mint 0.01 -a
|
||||
checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 478 -edge 748 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1761
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checknbshapes result -vertex 479 -edge 746 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1760
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 6
|
||||
checkfreebounds result 8
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -19,7 +19,7 @@ checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 476 -edge 748 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1759
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -17,7 +17,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 483 -edge 744 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1762
|
||||
checkmaxtol result -ref 0.080645000662448688
|
||||
checkmaxtol result -ref 0.083710669564248399
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 9
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -17,7 +17,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 480 -edge 741 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1756
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -25,7 +25,7 @@ sewing result +t 1.1 a_2 b_1
|
||||
checkprops result -s 12
|
||||
checkshape result
|
||||
checknbshapes result -vertex 4 -edge 4 -wire 2 -face 2 -shell 1 -solid 0 -compsolid 0 -compound 0 -shape 13
|
||||
checkmaxtol result -ref 1.5
|
||||
checkmaxtol result -ref 1.05
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -17,7 +17,7 @@ checkprops result -s 1.8847e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 480 -edge 741 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1756
|
||||
checkmaxtol result -ref 0.080878557461246572
|
||||
checkmaxtol result -ref 0.083903522096914374
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -17,7 +17,7 @@ sewing result +t 1.1 a_2 b_1 +f
|
||||
checkprops result -s 12
|
||||
checkshape result
|
||||
checknbshapes result -vertex 4 -edge 4 -wire 2 -face 2 -shell 1 -solid 0 -compsolid 0 -compound 0 -shape 13
|
||||
checkmaxtol result -ref 1.5
|
||||
checkmaxtol result -ref 1.05
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -18,7 +18,7 @@ checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 482 -edge 744 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1761
|
||||
checkmaxtol result -ref 0.066338232054955981
|
||||
checkmaxtol result -ref 0.04656161000546645
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 6
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -16,7 +16,7 @@ checkprops result -s 1.88469e+07
|
||||
checkshape result
|
||||
|
||||
checknbshapes result -vertex 476 -edge 748 -wire 273 -face 259 -shell 2 -solid 0 -compsolid 0 -compound 1 -shape 1759
|
||||
checkmaxtol result -ref 0.066338232054955981
|
||||
checkmaxtol result -ref 0.04656161000546645
|
||||
checknbshapes result -shell 2
|
||||
checkfreebounds result 6
|
||||
checkview -display result -3d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -28,7 +28,7 @@ if { ${minTolerance} > ${VertexTolerance} } {
|
||||
|
||||
|
||||
checkreal "Min tolerance" ${minTolerance} ${oTolerance} 0 0.001
|
||||
checkmaxtol result -ref 2352.4465999220711
|
||||
checkmaxtol result -ref 1699.9358291469857
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 5
|
||||
|
||||
|
@@ -29,7 +29,7 @@ if { $ve1 != $ve2 || $ed1 != $ed2 || $we1 != $we2} {
|
||||
puts "OK OCC714: SEWING operation was made PROPERLY"
|
||||
}
|
||||
|
||||
checkmaxtol result -ref 0.25619311354638169
|
||||
checkmaxtol result -ref 0.17933517948246736
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
|
||||
|
@@ -12,7 +12,7 @@ igesread [locate_data_file bug25175_3.igs] a *
|
||||
|
||||
sewing result 0.1 a
|
||||
|
||||
checkmaxtol result -ref 0.40493352048584974
|
||||
checkmaxtol result -ref 0.21794517334615857
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 0
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
puts "TODO OCC27531 ALL: Error: Max tolerance"
|
||||
#puts "TODO OCC27531 ALL: Error: Max tolerance"
|
||||
puts "========"
|
||||
puts "0027015: Sewing returns invalid shape if some faces are nearly plane cones"
|
||||
puts "========"
|
||||
@@ -14,4 +14,4 @@ checkshape result
|
||||
# Check tolerance of the result shape.
|
||||
# Currently same parameter algorithm can not interpolate pcurve.
|
||||
#"same parameter" state is obtained increasing tolerance to ~130.0 mm (max deviation between curves in 3d and 2d).
|
||||
checkmaxtol result -ref 1.0
|
||||
checkmaxtol result -ref 0.029697490042886372
|
||||
|
@@ -21,7 +21,7 @@ fixshape result rr
|
||||
checkshape result
|
||||
checkprops result -s 2.14316e+011
|
||||
|
||||
checkmaxtol result -ref 0.070055357229360987
|
||||
checkmaxtol result -ref 0.049038750060552701
|
||||
|
||||
checknbshapes result -shell 1 -face 201 -wire 201
|
||||
|
||||
|
30
tests/bugs/modalg_7/bug30386_1
Normal file
30
tests/bugs/modalg_7/bug30386_1
Normal file
@@ -0,0 +1,30 @@
|
||||
puts "======================================================="
|
||||
puts "0030386: Modeling Algorithms - Unable to perform Cut operation"
|
||||
puts "======================================================="
|
||||
puts ""
|
||||
|
||||
restore [locate_data_file bug30386_shapes.brep] s
|
||||
explode s
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects s_1
|
||||
baddtools s_2
|
||||
bfillds
|
||||
|
||||
bbop r0 0
|
||||
bbop r2 2
|
||||
|
||||
foreach r {r0 r2} {
|
||||
checkshape $r
|
||||
if {![regexp "OK" [bopcheck $r]]} {
|
||||
puts "Error: the $r is a self-interfering shape"
|
||||
}
|
||||
}
|
||||
|
||||
checknbshapes r0 -wire 6 -face 6 -shell 0 -solid 0 -t
|
||||
checkprops r0 -s 1.0852
|
||||
|
||||
checknbshapes r2 -wire 546 -face 533 -shell 12 -solid 12 -t
|
||||
checkprops r2 -s 223.275 -v 123.21
|
||||
|
||||
checkview -display r2 -2d -path ${imagedir}/${test_image}.png
|
18
tests/bugs/modalg_7/bug30386_2
Normal file
18
tests/bugs/modalg_7/bug30386_2
Normal file
@@ -0,0 +1,18 @@
|
||||
puts "REQUIRED All: Error: Boolean operation of the given type is not allowed on the given inputs"
|
||||
|
||||
puts "======================================================="
|
||||
puts "0030386: Modeling Algorithms - Unable to perform Cut operation"
|
||||
puts "======================================================="
|
||||
puts ""
|
||||
|
||||
restore [locate_data_file bug30386_shapes.brep] s
|
||||
explode s
|
||||
# just to avoid intersection
|
||||
ttranslate s_2 10 0 0
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects s_1
|
||||
baddtools s_2
|
||||
bfillds
|
||||
# try to perform fuse operation - error is expected
|
||||
bbop r1 1
|
18
tests/bugs/modalg_7/bug30386_3
Normal file
18
tests/bugs/modalg_7/bug30386_3
Normal file
@@ -0,0 +1,18 @@
|
||||
puts "REQUIRED All: Error: Boolean operation of the given type is not allowed on the given inputs"
|
||||
|
||||
puts "======================================================="
|
||||
puts "0030386: Modeling Algorithms - Unable to perform Cut operation"
|
||||
puts "======================================================="
|
||||
puts ""
|
||||
|
||||
restore [locate_data_file bug30386_shapes.brep] s
|
||||
explode s
|
||||
# just to avoid intersection
|
||||
ttranslate s_2 10 0 0
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects s_1
|
||||
baddtools s_2
|
||||
bfillds
|
||||
# try to perform CUT21 operation - error is expected
|
||||
bbop r3 3
|
50
tests/bugs/modalg_7/bug30386_4
Normal file
50
tests/bugs/modalg_7/bug30386_4
Normal file
@@ -0,0 +1,50 @@
|
||||
puts "======================================================="
|
||||
puts "0030386: Modeling Algorithms - Unable to perform Cut operation"
|
||||
puts "======================================================="
|
||||
puts ""
|
||||
|
||||
# prepare the first argument - compound of mutlti-dimensional shapes
|
||||
vertex v 0 0 2
|
||||
line l 5 5 0 0 0 1
|
||||
mkedge e l -10 10
|
||||
plane p 0 0 1 0 0 1
|
||||
mkface f p -15 15 -15 15
|
||||
box b 8 8 8 5 5 5
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects v e f b
|
||||
bfillds
|
||||
bbuild s1
|
||||
|
||||
# second argument - solid
|
||||
box s2 10 10 10
|
||||
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects s1
|
||||
baddtools s2
|
||||
bfillds
|
||||
|
||||
# it is allowed to perform only CUT and COMMON operations
|
||||
bbop r0 0
|
||||
bbop r2 2
|
||||
|
||||
|
||||
foreach r {r0 r2} {
|
||||
checkshape $r
|
||||
if {![regexp "OK" [bopcheck $r]]} {
|
||||
puts "Error: the $r is a self-interfering shape"
|
||||
}
|
||||
}
|
||||
|
||||
checknbshapes r0 -vertex 16 -edge 18 -wire 7 -face 7 -shell 1 -solid 1 -t
|
||||
checkprops r0 -s 124
|
||||
explode r0 so
|
||||
checkprops r0_1 -v 8
|
||||
|
||||
checknbshapes r2 -vertex 24 -edge 30 -wire 11 -face 10 -shell 1 -solid 1 -t
|
||||
checkprops r2 -s 950
|
||||
explode r2 so
|
||||
checkprops r2_1 -v 117
|
||||
|
||||
checkview -display r2 -2d -path ${imagedir}/${test_image}.png
|
46
tests/bugs/modalg_7/bug30386_5
Normal file
46
tests/bugs/modalg_7/bug30386_5
Normal file
@@ -0,0 +1,46 @@
|
||||
puts "REQUIRED All: Error: Boolean operation of the given type is not allowed on the given inputs"
|
||||
|
||||
puts "======================================================="
|
||||
puts "0030386: Modeling Algorithms - Unable to perform Cut operation"
|
||||
puts "======================================================="
|
||||
puts ""
|
||||
|
||||
# prepare the first argument - compound of mutlti-dimensional shapes
|
||||
vertex v 0 0 2
|
||||
line l 5 5 0 0 0 1
|
||||
mkedge e l -10 10
|
||||
plane p 0 0 1 0 0 1
|
||||
mkface f p -15 15 -15 15
|
||||
box b 8 8 8 5 5 5
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects v e f b
|
||||
bfillds
|
||||
bbuild s1
|
||||
|
||||
# second argument - compound of solid and face
|
||||
box b2 10 10 10
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects f
|
||||
baddtools b2
|
||||
bfillds
|
||||
bbuild s2
|
||||
|
||||
# only common operation should be allowed
|
||||
|
||||
bclearobjects
|
||||
bcleartools
|
||||
baddobjects s1
|
||||
baddtools s2
|
||||
bfillds
|
||||
|
||||
if {[regexp "Error: Boolean operation of the given type is not allowed on the given inputs" [bbop r 0]]} {
|
||||
puts "Error: COMMON Operation must be allowed on any types of arguments"
|
||||
}
|
||||
|
||||
foreach i {1 2 3} {
|
||||
if {![regexp "Error: Boolean operation of the given type is not allowed on the given inputs" [bbop r $i]]} {
|
||||
puts "Error: Operation must not be allowed"
|
||||
}
|
||||
}
|
13
tests/bugs/modalg_7/bug31407_1
Normal file
13
tests/bugs/modalg_7/bug31407_1
Normal file
@@ -0,0 +1,13 @@
|
||||
puts "========"
|
||||
puts "0031407: Extrema does not process parallel circles correctly"
|
||||
puts "========"
|
||||
puts ""
|
||||
|
||||
circle c1 0 0 0 0 0 1 5
|
||||
circle c2 0 0 0 0 0 1 10
|
||||
|
||||
if { [regexp "Infinite number of extremas" [extrema c1 c2]] == 1} {
|
||||
puts "OK : Circles are treated as concentric"
|
||||
} else {
|
||||
puts "Error : Extrema does not find the circles are parallel"
|
||||
}
|
13
tests/bugs/modalg_7/bug31407_2
Normal file
13
tests/bugs/modalg_7/bug31407_2
Normal file
@@ -0,0 +1,13 @@
|
||||
puts "========"
|
||||
puts "0031407: Extrema does not process parallel circles correctly"
|
||||
puts "========"
|
||||
puts ""
|
||||
|
||||
circle c1 0 0 0 0 0 -1 5
|
||||
circle c2 0 0 0 0 0 1 10
|
||||
|
||||
if { [regexp "Infinite number of extremas" [extrema c1 c2]] == 1} {
|
||||
puts "OK : Circles are treated as concentric"
|
||||
} else {
|
||||
puts "Error : Extrema does not find the circles are parallel"
|
||||
}
|
20
tests/bugs/modalg_7/bug31407_3
Normal file
20
tests/bugs/modalg_7/bug31407_3
Normal file
@@ -0,0 +1,20 @@
|
||||
puts "========"
|
||||
puts "0031407: Extrema does not process parallel circles correctly"
|
||||
puts "========"
|
||||
puts ""
|
||||
|
||||
circle c1 0 0 0 0 0 1 5
|
||||
circle c2 0 0 0 0 0 1 10
|
||||
|
||||
trim cc1 c1 0 2
|
||||
trim cc2 c2 2 4
|
||||
|
||||
set res_extrema [extrema cc1 cc2]
|
||||
|
||||
if { [regexp "Infinite number of extremas" $res_extrema] == 0} {
|
||||
if {[llength $res_extrema] != 1} {
|
||||
puts "Error : expected 1 extrema, but found [llength $res_extrema]"
|
||||
}
|
||||
} else {
|
||||
puts "Error : Infinite number of extremas is found"
|
||||
}
|
@@ -18,7 +18,7 @@ if [catch {igesbrep $filepath a *} catch_result] {
|
||||
#
|
||||
sewing result1 100. a
|
||||
|
||||
checkmaxtol result1 -ref 9.43897e+001
|
||||
checkmaxtol result1 -ref 66.0727572
|
||||
checknbshapes result1 -shell 1
|
||||
checkfreebounds result1 86
|
||||
|
||||
@@ -71,7 +71,7 @@ if [catch {igesbrep $filepath a *} catch_result] {
|
||||
tpcompound a
|
||||
sewing result2 100. a
|
||||
|
||||
checkmaxtol result2 -ref 9.43897e+001
|
||||
checkmaxtol result2 -ref 66.072757207851282
|
||||
checknbshapes result2 -shell 1
|
||||
checkfreebounds result2 86
|
||||
|
||||
|
@@ -34,7 +34,7 @@ if { [llength $closed_wires] != 1} {
|
||||
puts "Error : Amount of free closed wires is not equal 1"
|
||||
}
|
||||
|
||||
checkmaxtol result -ref 9.43897e+001
|
||||
checkmaxtol result -ref 66.072757207853044
|
||||
checknbshapes result -shell 1
|
||||
checkfreebounds result 86
|
||||
|
||||
|
@@ -15,7 +15,7 @@ set tolerance 1000
|
||||
sewing result ${tolerance} a
|
||||
|
||||
checknbshapes result -face 263 -shell 1
|
||||
checkmaxtol result -ref 185.91005891234283
|
||||
checkmaxtol result -ref 130.21536414731227
|
||||
checkfreebounds result 73
|
||||
|
||||
checkview -display result -2d -path ${imagedir}/${test_image}.png
|
||||
|
@@ -11,7 +11,7 @@ TPSTAT : Faulties = 0 ( 0 ) Warnings = 0 ( 7 ) Summary = 0 ( 7 )
|
||||
CHECKSHAPE : Wires = 0 ( 0 ) Faces = 0 ( 0 ) Shells = 0 ( 0 ) Solids = 0 ( 0 )
|
||||
NBSHAPES : Solid = 0 ( 0 ) Shell = 9 ( 0 ) Face = 9 ( 9 )
|
||||
STATSHAPE : Solid = 0 ( 0 ) Shell = 9 ( 0 ) Face = 9 ( 9 ) FreeWire = 0 ( 0 )
|
||||
TOLERANCE : MaxTol = 0.003863207397 ( 0.02717230043 ) AvgTol = 0.0004713629464 ( 0.003097464066 )
|
||||
TOLERANCE : MaxTol = 0.003863207397 ( 0.03790164928 ) AvgTol = 0.0004713629464 ( 0.003090287092 )
|
||||
LABELS : N0Labels = 1 ( 1 ) N1Labels = 5 ( 5 ) N2Labels = 0 ( 0 ) TotalLabels = 6 ( 6 ) NameLabels = 1 ( 1 ) ColorLabels = 0 ( 0 ) LayerLabels = 5 ( 5 )
|
||||
PROPS : Centroid = 0 ( 0 ) Volume = 0 ( 0 ) Area = 0 ( 0 )
|
||||
NCOLORS : NColors = 0 ( 0 )
|
||||
|
@@ -1,5 +1,5 @@
|
||||
if { [string compare $command "ShapeConvertRev"] == 0 } {
|
||||
puts "TODO OCC23127 ALL: Error : The area of the resulting shape is"
|
||||
}
|
||||
#if { [string compare $command "ShapeConvertRev"] == 0 } {
|
||||
#puts "TODO OCC23127 ALL: Error : The area of the resulting shape is"
|
||||
#}
|
||||
restore [locate_data_file CTO901_cts20172_base.rle] a
|
||||
|
||||
|
@@ -1,2 +1,5 @@
|
||||
if { [string compare $command "SplitAngle"] == 0 } {
|
||||
puts "REQUIRED All: Faulty shapes in variables faulty_1 to faulty_"
|
||||
}
|
||||
restore [locate_data_file ANSCHLUSS.brep] a
|
||||
|
||||
|
@@ -12,10 +12,10 @@ regexp {Number +of +other +pcurves +- +([-0-9.+eE]+)} $expsh full nb_pcurve
|
||||
if { $nb_plane != 0 || $nb_other_surf != 0 || $nb_curve != 0 || $nb_pcurve != 0} {
|
||||
puts "Error : The resulting shape is not correct"
|
||||
}
|
||||
regexp {Mass +: +([-0-9.+eE]+)} [sprops a] full mass
|
||||
regexp {Mass +: +([-0-9.+eE]+)} [sprops result] full m
|
||||
regexp {Mass +: +([-0-9.+eE]+)} [sprops a $rel_tol] full mass
|
||||
regexp {Mass +: +([-0-9.+eE]+)} [sprops result $rel_tol] full m
|
||||
|
||||
if { ($mass != 0 && [expr 1.*abs($mass - $m)/$mass] > $rel_tol) || ($mass == 0 && $m != 0) } {
|
||||
if { ($mass != 0 && [expr 1.*abs($mass - $m)/$mass] > 1.5*$rel_tol) || ($mass == 0 && $m != 0) } {
|
||||
puts "Error : The area of the resulting shape is $m"
|
||||
} else {
|
||||
puts "The areas of the initial and the resulting shape are equal"
|
||||
|
@@ -1,4 +1,5 @@
|
||||
puts "TODO OCC30286 Windows: Error : The length of result shape is 404.004, expected 404.386"
|
||||
puts "TODO OCC30286 Linux: Error : The length of result shape is 404.492, expected 404.386"
|
||||
|
||||
polyline f1 0 0 0 0 -10 0 100 -10 0 100 0 0 0 0 0
|
||||
polyline f2 100 0 0 110 0 0 110 100 0 100 100 0 100 0 0
|
||||
|
@@ -4,5 +4,5 @@ offset es_bspline_3d_p_nr_of es_bspline_3d_p_nr 1
|
||||
offset es_bspline_3d_p_nr_of_of es_bspline_3d_p_nr_of 1
|
||||
mkface result es_bspline_3d_p_nr_of_of 0 1 0 3
|
||||
set MaxFTol 9.9999999999999995e-08
|
||||
set MaxETol 3.0212868909361951e-07
|
||||
set MaxVTol 3.0212868909361962e-07
|
||||
set MaxETol 3.2685874571489216e-007
|
||||
set MaxVTol 3.2685874571489216e-007
|
||||
|
@@ -2,6 +2,7 @@ beziercurve beziercurve_nr 3 0 0 0 2 2 2 4 5 2
|
||||
extsurf es_beziercurve_nr beziercurve_nr 0 0 1
|
||||
offset es_beziercurve_nr_of es_beziercurve_nr 1
|
||||
puts "TODO #23133 ALL: Error : Incorrect input parameters are not processed correctly"
|
||||
puts "REQUIRED All: Faulty shapes in variables faulty_1 to faulty"
|
||||
if { [catch { mkface result es_beziercurve_nr_of 0 3 0 30 } out] == 0 } {
|
||||
puts "Error : Incorrect input parameters are not processed correctly."
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user