NPAL16568: Added Approximation parameter in MakeFilling algorithm.

This commit is contained in:
vtn 2008-02-04 13:58:23 +00:00
parent bf97bbaa21
commit 7ac24e7592
28 changed files with 705 additions and 35 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -5,8 +5,8 @@
<ul> <ul>
<li>\subpage create_extrusion_page</li> <li>\subpage create_extrusion_page</li>
<li>\subpage create_revolution_page</li> <li>\subpage create_revolution_page</li>
<li>\subpage creaet_filling_page</li> <li>\subpage create_filling_page</li>
<li>\subpage create_extrusion_alongpath_page</li> <li>\subpage create_extrusion_alongpath_page</li>
</ul> </ul>
*/ */

View File

@ -1,18 +1,20 @@
/*! /*!
\page creaet_filling_page Filling Surface with Edges \page create_filling_page Filling Surface with Edges
To generate a \b Filling in the <b>Main Menu</b> select <b>New Entity - > Generation - > Filling</b> To generate a \b Filling in the <b>Main Menu</b> select <b>New Entity - > Generation - > Filling</b>
\n To create a curving face using several edges you need to define the \n To create a curving face using several edges you need to define the
<b>Edges Compound</b>, \b Minimum and <b>Maximum Degree</b>, \b <b>Edges Compound</b>, \b Minimum and <b>Maximum Degree</b>, \b
Tolerance for \b 2D and for \b 3D and the <b>Number of Iterations</b>. Tolerance for \b 2D and for \b 3D , the <b>Number of Iterations</b>
and <b>Approximation</b>.
\n The \b Result of the operation will be a GEOM_Object (face). \n The \b Result of the operation will be a GEOM_Object (face).
\n <b>TUI Command:</b> <em>geompy.MakeFilling(Edges, MinDegree, MaxDegree, Tol2D, Tol3D, NbIter)</em> \n <b>TUI Command:</b> <em>geompy.MakeFilling(Edges, MinDegree,
\n <b>Arguments:</b> Name + 1 List of edges + 5 Parameters MaxDegree, Tol2D, Tol3D, NbIter, isApprox)</em>
\n <b>Arguments:</b> Name + 1 List of edges + 6 Parameters
(Min. degree, Max. degree, Number of iterations, 2D tolerance, 3D (Min. degree, Max. degree, Number of iterations, 2D tolerance, 3D
tolerance, Number of iterations). tolerance, Number of iterations, Approximation).
\image html filling.png \image html filling.png

View File

@ -28,7 +28,7 @@
<ul> <ul>
<li>\ref create_extrusion_page</li> <li>\ref create_extrusion_page</li>
<li>\ref create_revolution_page</li> <li>\ref create_revolution_page</li>
<li>\ref creaet_filling_page</li> <li>\ref create_filling_page</li>
<li>\ref create_extrusion_alongpath_page</li> <li>\ref create_extrusion_alongpath_page</li>
</ul> </ul>
<li>\subpage work_with_groups_page</li> <li>\subpage work_with_groups_page</li>
@ -46,4 +46,4 @@
</ul> </ul>
</ul> </ul>
*/ */

View File

@ -32,7 +32,7 @@
<ul> <ul>
<li>\ref create_extrusion_page</li> <li>\ref create_extrusion_page</li>
<li>\ref create_revolution_page</li> <li>\ref create_revolution_page</li>
<li>\ref creaet_filling_page</li> <li>\ref create_filling_page</li>
<li>\ref create_extrusion_alongpath_page</li> <li>\ref create_extrusion_alongpath_page</li>
</ul> </ul>
<li>\ref work_with_groups_page</li> <li>\ref work_with_groups_page</li>
@ -134,4 +134,4 @@
</ul> </ul>
</ul> </ul>
*/ */

View File

@ -902,7 +902,7 @@ module GEOM
GEOM_Object MakeFilling (in GEOM_Object theShape, GEOM_Object MakeFilling (in GEOM_Object theShape,
in long theMinDeg, in long theMaxDeg, in long theMinDeg, in long theMaxDeg,
in double theTol2D, in double theTol3D, in double theTol2D, in double theTol3D,
in long theNbIter); in long theNbIter, in boolean theApprox);
/*! /*!
* Create a shell or solid passing through set of sections.Sections should be wires,edges or vertices. * Create a shell or solid passing through set of sections.Sections should be wires,edges or vertices.

View File

@ -176,7 +176,7 @@ module GEOM
GEOM_Object MakeFilling (in GEOM_Object theShape, GEOM_Object MakeFilling (in GEOM_Object theShape,
in long theMinDeg, in long theMaxDeg, in long theMinDeg, in long theMaxDeg,
in double theTol2D, in double theTol3D, in double theTol2D, in double theTol3D,
in long theNbIter) ; in long theNbIter, in boolean theApprox) ;
GEOM_Object MakeThruSections(in ListOfGO theSeqSections, GEOM_Object MakeThruSections(in ListOfGO theSeqSections,
in boolean theModeSolid, in boolean theModeSolid,
in double thePreci, in double thePreci,

View File

@ -0,0 +1,71 @@
// GEOM GEOMGUI : GUI for Geometry component
//
// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
//
//
// File : DlgRef_1Sel5Spin1Check.cxx
// Author : Vladimir TURIN
// Module : GEOM
// $Header:
#include "DlgRef_1Sel5Spin1Check.h"
#include <qlayout.h>
#include <qspinbox.h>
#include <qgroupbox.h>
/*
* Constructs a DlgRef_1Sel5Spin1Check which is a child of 'parent', with the
* name 'name' and widget flags set to 'f'
*/
DlgRef_1Sel5Spin1Check::DlgRef_1Sel5Spin1Check(QWidget* parent, const char* name, WFlags fl)
:DlgRef_1Sel5Spin1Check_QTD(parent, name, fl)
{
SpinBox1->close(TRUE);
SpinBox2->close(TRUE);
SpinBox3->close(TRUE);
SpinBox4->close(TRUE);
SpinBox5->close(TRUE);
SpinBox_1 = new DlgRef_SpinBox(GroupBox1, "SpinBox_1");
Layout2->addWidget(SpinBox_1, 0, 1);
SpinBox_2 = new DlgRef_SpinBox(GroupBox1, "SpinBox_2");
Layout2->addWidget(SpinBox_2, 0, 3);
SpinBox_3 = new DlgRef_SpinBox(GroupBox1, "SpinBox_3");
Layout2->addWidget(SpinBox_3, 2, 1);
SpinBox_4 = new DlgRef_SpinBox(GroupBox1, "SpinBox_4");
Layout2->addWidget(SpinBox_4, 1, 1);
SpinBox_5 = new DlgRef_SpinBox(GroupBox1, "SpinBox_5");
Layout2->addWidget(SpinBox_5, 1, 3);
}
/*
* Destroys the object and frees any allocated resources
*/
DlgRef_1Sel5Spin1Check::~DlgRef_1Sel5Spin1Check()
{
// no need to delete child widgets, Qt does it all for us
}

View File

@ -0,0 +1,53 @@
// GEOM GEOMGUI : GUI for Geometry component
//
// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
//
//
// File : DlgRef_1Sel5Spin1Check.h
// Author : Vladimir TURIN
// Module : GEOM
// $Header:
#ifndef DLGREF_1SEL5SPIN_H
#define DLGREF_1SEL5SPIN_H
#include "GEOM_DlgRef.hxx"
#include "DlgRef_1Sel5Spin1Check_QTD.h"
#include "DlgRef_SpinBox.h"
class GEOM_DLGREF_EXPORT DlgRef_1Sel5Spin1Check : public DlgRef_1Sel5Spin1Check_QTD
{
Q_OBJECT
public:
DlgRef_1Sel5Spin1Check( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
~DlgRef_1Sel5Spin1Check();
DlgRef_SpinBox* SpinBox_1;
DlgRef_SpinBox* SpinBox_2;
DlgRef_SpinBox* SpinBox_3;
DlgRef_SpinBox* SpinBox_4;
DlgRef_SpinBox* SpinBox_5;
};
#endif // DLGREF_1SEL5SPIN_H

View File

@ -0,0 +1,150 @@
/****************************************************************************
** Form implementation generated from reading ui file 'DlgRef_1Sel5Spin1Check_QTD.ui'
**
** Created: Fri Feb 1 14:04:55 2008
** by: The User Interface Compiler ($Id$)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/
#include "DlgRef_1Sel5Spin1Check_QTD.h"
#include <qvariant.h>
#include <qpushbutton.h>
#include <qgroupbox.h>
#include <qlabel.h>
#include <qspinbox.h>
#include <qcheckbox.h>
#include <qlineedit.h>
#include <qlayout.h>
#include <qtooltip.h>
#include <qwhatsthis.h>
/*
* Constructs a DlgRef_1Sel5Spin1Check_QTD as a child of 'parent', with the
* name 'name' and widget flags set to 'f'.
*/
DlgRef_1Sel5Spin1Check_QTD::DlgRef_1Sel5Spin1Check_QTD( QWidget* parent, const char* name, WFlags fl )
: QWidget( parent, name, fl )
{
if ( !name )
setName( "DlgRef_1Sel5Spin1Check_QTD" );
DlgRef_1Sel5Spin1Check_QTDLayout = new QGridLayout( this, 1, 1, 0, 6, "DlgRef_1Sel5Spin1Check_QTDLayout");
GroupBox1 = new QGroupBox( this, "GroupBox1" );
GroupBox1->setColumnLayout(0, Qt::Vertical );
GroupBox1->layout()->setSpacing( 6 );
GroupBox1->layout()->setMargin( 11 );
GroupBox1Layout = new QGridLayout( GroupBox1->layout() );
GroupBox1Layout->setAlignment( Qt::AlignTop );
Layout1 = new QGridLayout( 0, 1, 1, 0, 6, "Layout1");
TextLabel1 = new QLabel( GroupBox1, "TextLabel1" );
TextLabel1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel1->sizePolicy().hasHeightForWidth() ) );
Layout1->addWidget( TextLabel1, 0, 0 );
PushButton1 = new QPushButton( GroupBox1, "PushButton1" );
PushButton1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, PushButton1->sizePolicy().hasHeightForWidth() ) );
Layout1->addWidget( PushButton1, 0, 1 );
Layout2 = new QGridLayout( 0, 1, 1, 0, 6, "Layout2");
SpinBox2 = new QSpinBox( GroupBox1, "SpinBox2" );
SpinBox2->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, SpinBox2->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( SpinBox2, 0, 3 );
SpinBox3 = new QSpinBox( GroupBox1, "SpinBox3" );
SpinBox3->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, SpinBox3->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( SpinBox3, 2, 1 );
TextLabel5 = new QLabel( GroupBox1, "TextLabel5" );
TextLabel5->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel5->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( TextLabel5, 1, 0 );
TextLabel3 = new QLabel( GroupBox1, "TextLabel3" );
TextLabel3->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel3->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( TextLabel3, 0, 2 );
TextLabel4 = new QLabel( GroupBox1, "TextLabel4" );
TextLabel4->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel4->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( TextLabel4, 2, 0 );
SpinBox4 = new QSpinBox( GroupBox1, "SpinBox4" );
SpinBox4->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, SpinBox4->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( SpinBox4, 1, 1 );
SpinBox1 = new QSpinBox( GroupBox1, "SpinBox1" );
SpinBox1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, SpinBox1->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( SpinBox1, 0, 1 );
TextLabel6 = new QLabel( GroupBox1, "TextLabel6" );
TextLabel6->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel6->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( TextLabel6, 1, 2 );
TextLabel2 = new QLabel( GroupBox1, "TextLabel2" );
TextLabel2->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)0, 0, 0, TextLabel2->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( TextLabel2, 0, 0 );
SpinBox5 = new QSpinBox( GroupBox1, "SpinBox5" );
SpinBox5->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, SpinBox5->sizePolicy().hasHeightForWidth() ) );
Layout2->addWidget( SpinBox5, 1, 3 );
CheckBox1 = new QCheckBox( GroupBox1, "CheckBox1" );
Layout2->addMultiCellWidget( CheckBox1, 2, 2, 2, 3 );
Layout1->addMultiCellLayout( Layout2, 1, 1, 0, 2 );
Spacer6 = new QSpacerItem( 0, 120, QSizePolicy::Minimum, QSizePolicy::Expanding );
Layout1->addItem( Spacer6, 2, 2 );
LineEdit1 = new QLineEdit( GroupBox1, "LineEdit1" );
Layout1->addWidget( LineEdit1, 0, 2 );
GroupBox1Layout->addLayout( Layout1, 0, 0 );
DlgRef_1Sel5Spin1Check_QTDLayout->addWidget( GroupBox1, 0, 0 );
languageChange();
resize( QSize(162, 143).expandedTo(minimumSizeHint()) );
clearWState( WState_Polished );
}
/*
* Destroys the object and frees any allocated resources
*/
DlgRef_1Sel5Spin1Check_QTD::~DlgRef_1Sel5Spin1Check_QTD()
{
// no need to delete child widgets, Qt does it all for us
}
/*
* Sets the strings of the subwidgets using the current
* language.
*/
void DlgRef_1Sel5Spin1Check_QTD::languageChange()
{
setCaption( tr( "DlgRef_1Sel5Spin1Check_QTD" ) );
GroupBox1->setTitle( QString::null );
TextLabel1->setText( tr( "TL1" ) );
PushButton1->setText( QString::null );
TextLabel5->setText( tr( "TL5" ) );
TextLabel3->setText( tr( "TL3" ) );
TextLabel4->setText( tr( "TL4" ) );
TextLabel6->setText( tr( "TL6" ) );
TextLabel2->setText( tr( "TL2" ) );
CheckBox1->setText( QString::null );
}

View File

@ -0,0 +1,63 @@
/****************************************************************************
** Form interface generated from reading ui file 'DlgRef_1Sel5Spin1Check_QTD.ui'
**
** Created: Fri Feb 1 14:04:51 2008
** by: The User Interface Compiler ($Id$)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/
#ifndef DLGREF_1SEL5SPIN1CHECK_QTD_H
#define DLGREF_1SEL5SPIN1CHECK_QTD_H
#include <qvariant.h>
#include <qwidget.h>
class QVBoxLayout;
class QHBoxLayout;
class QGridLayout;
class QSpacerItem;
class QGroupBox;
class QLabel;
class QPushButton;
class QSpinBox;
class QCheckBox;
class QLineEdit;
class DlgRef_1Sel5Spin1Check_QTD : public QWidget
{
Q_OBJECT
public:
DlgRef_1Sel5Spin1Check_QTD( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
~DlgRef_1Sel5Spin1Check_QTD();
QGroupBox* GroupBox1;
QLabel* TextLabel1;
QPushButton* PushButton1;
QSpinBox* SpinBox2;
QSpinBox* SpinBox3;
QLabel* TextLabel5;
QLabel* TextLabel3;
QLabel* TextLabel4;
QSpinBox* SpinBox4;
QSpinBox* SpinBox1;
QLabel* TextLabel6;
QLabel* TextLabel2;
QSpinBox* SpinBox5;
QCheckBox* CheckBox1;
QLineEdit* LineEdit1;
protected:
QGridLayout* DlgRef_1Sel5Spin1Check_QTDLayout;
QGridLayout* GroupBox1Layout;
QGridLayout* Layout1;
QSpacerItem* Spacer6;
QGridLayout* Layout2;
protected slots:
virtual void languageChange();
};
#endif // DLGREF_1SEL5SPIN1CHECK_QTD_H

View File

@ -46,6 +46,7 @@ dist_libDlgRef_la_SOURCES = \
DlgRef_1Sel3Spin_QTD.cxx \ DlgRef_1Sel3Spin_QTD.cxx \
DlgRef_1Sel4Spin_QTD.cxx \ DlgRef_1Sel4Spin_QTD.cxx \
DlgRef_1Sel5Spin_QTD.cxx \ DlgRef_1Sel5Spin_QTD.cxx \
DlgRef_1Sel5Spin1Check_QTD.cxx \
DlgRef_2Sel1Spin_QTD.cxx \ DlgRef_2Sel1Spin_QTD.cxx \
DlgRef_2Sel2Spin_QTD.cxx \ DlgRef_2Sel2Spin_QTD.cxx \
DlgRef_2Sel3Spin_QTD.cxx \ DlgRef_2Sel3Spin_QTD.cxx \
@ -73,6 +74,7 @@ dist_libDlgRef_la_SOURCES = \
DlgRef_1Sel3Spin.cxx \ DlgRef_1Sel3Spin.cxx \
DlgRef_1Sel4Spin.cxx \ DlgRef_1Sel4Spin.cxx \
DlgRef_1Sel5Spin.cxx \ DlgRef_1Sel5Spin.cxx \
DlgRef_1Sel5Spin1Check.cxx \
DlgRef_2Sel1Spin.cxx \ DlgRef_2Sel1Spin.cxx \
DlgRef_2Sel2Spin.cxx \ DlgRef_2Sel2Spin.cxx \
DlgRef_2Sel3Spin.cxx \ DlgRef_2Sel3Spin.cxx \
@ -105,6 +107,7 @@ MOC_FILES = \
DlgRef_1Sel3Spin_QTD_moc.cxx \ DlgRef_1Sel3Spin_QTD_moc.cxx \
DlgRef_1Sel4Spin_QTD_moc.cxx \ DlgRef_1Sel4Spin_QTD_moc.cxx \
DlgRef_1Sel5Spin_QTD_moc.cxx \ DlgRef_1Sel5Spin_QTD_moc.cxx \
DlgRef_1Sel5Spin1Check_QTD_moc.cxx \
DlgRef_2Sel1Spin_QTD_moc.cxx \ DlgRef_2Sel1Spin_QTD_moc.cxx \
DlgRef_2Sel2Spin_QTD_moc.cxx \ DlgRef_2Sel2Spin_QTD_moc.cxx \
DlgRef_2Sel3Spin_QTD_moc.cxx \ DlgRef_2Sel3Spin_QTD_moc.cxx \
@ -132,6 +135,7 @@ MOC_FILES = \
DlgRef_1Sel3Spin_moc.cxx \ DlgRef_1Sel3Spin_moc.cxx \
DlgRef_1Sel4Spin_moc.cxx \ DlgRef_1Sel4Spin_moc.cxx \
DlgRef_1Sel5Spin_moc.cxx \ DlgRef_1Sel5Spin_moc.cxx \
DlgRef_1Sel5Spin1Check_moc.cxx \
DlgRef_2Sel1Spin_moc.cxx \ DlgRef_2Sel1Spin_moc.cxx \
DlgRef_2Sel2Spin_moc.cxx \ DlgRef_2Sel2Spin_moc.cxx \
DlgRef_2Sel3Spin_moc.cxx \ DlgRef_2Sel3Spin_moc.cxx \
@ -166,6 +170,7 @@ salomeinclude_HEADERS = \
DlgRef_1Sel3Spin_QTD.h \ DlgRef_1Sel3Spin_QTD.h \
DlgRef_1Sel4Spin_QTD.h \ DlgRef_1Sel4Spin_QTD.h \
DlgRef_1Sel5Spin_QTD.h \ DlgRef_1Sel5Spin_QTD.h \
DlgRef_1Sel5Spin1Check_QTD.h \
DlgRef_2Sel1Spin_QTD.h \ DlgRef_2Sel1Spin_QTD.h \
DlgRef_2Sel2Spin_QTD.h \ DlgRef_2Sel2Spin_QTD.h \
DlgRef_2Sel3Spin_QTD.h \ DlgRef_2Sel3Spin_QTD.h \
@ -193,6 +198,7 @@ salomeinclude_HEADERS = \
DlgRef_1Sel3Spin.h \ DlgRef_1Sel3Spin.h \
DlgRef_1Sel4Spin.h \ DlgRef_1Sel4Spin.h \
DlgRef_1Sel5Spin.h \ DlgRef_1Sel5Spin.h \
DlgRef_1Sel5Spin1Check.h \
DlgRef_2Sel1Spin.h \ DlgRef_2Sel1Spin.h \
DlgRef_2Sel2Spin.h \ DlgRef_2Sel2Spin.h \
DlgRef_2Sel3Spin.h \ DlgRef_2Sel3Spin.h \

View File

@ -0,0 +1,290 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>DlgRef_1Sel5Spin1Check_QTD</class>
<widget class="QWidget">
<property name="name">
<cstring>DlgRef_1Sel5Spin1Check_QTD</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>162</width>
<height>143</height>
</rect>
</property>
<property name="caption">
<string>DlgRef_1Sel5Spin1Check_QTD</string>
</property>
<grid>
<property name="name">
<cstring>unnamed</cstring>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<widget class="QGroupBox" row="0" column="0">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
<property name="title">
<string></string>
</property>
<grid>
<property name="name">
<cstring>unnamed</cstring>
</property>
<property name="margin">
<number>11</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<widget class="QLayoutWidget" row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
<grid>
<property name="name">
<cstring>unnamed</cstring>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<widget class="QLabel" row="0" column="0">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL1</string>
</property>
</widget>
<widget class="QPushButton" row="0" column="1">
<property name="name">
<cstring>PushButton1</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string></string>
</property>
</widget>
<widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>Layout2</cstring>
</property>
<grid>
<property name="name">
<cstring>unnamed</cstring>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<widget class="QSpinBox" row="0" column="3">
<property name="name">
<cstring>SpinBox2</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
<widget class="QSpinBox" row="2" column="1">
<property name="name">
<cstring>SpinBox3</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<property name="name">
<cstring>TextLabel5</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL5</string>
</property>
</widget>
<widget class="QLabel" row="0" column="2">
<property name="name">
<cstring>TextLabel3</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL3</string>
</property>
</widget>
<widget class="QLabel" row="2" column="0">
<property name="name">
<cstring>TextLabel4</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL4</string>
</property>
</widget>
<widget class="QSpinBox" row="1" column="1">
<property name="name">
<cstring>SpinBox4</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
<widget class="QSpinBox" row="0" column="1">
<property name="name">
<cstring>SpinBox1</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
<widget class="QLabel" row="1" column="2">
<property name="name">
<cstring>TextLabel6</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL6</string>
</property>
</widget>
<widget class="QLabel" row="0" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>TL2</string>
</property>
</widget>
<widget class="QSpinBox" row="1" column="3">
<property name="name">
<cstring>SpinBox5</cstring>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
<widget class="QCheckBox" row="2"
column="2" rowspan="1" colspan="2">
<property name="name">
<cstring>CheckBox1</cstring>
</property>
<property name="text">
<string></string>
</property>
</widget>
</grid>
</widget>
<spacer row="2" column="2">
<property name="name">
<cstring>Spacer6</cstring>
</property>
<property name="orientation">
<enum>Vertical</enum>
</property>
<property name="sizeType">
<enum>Expanding</enum>
</property>
<property name="sizeHint">
<size>
<width>0</width>
<height>120</height>
</size>
</property>
</spacer>
<widget class="QLineEdit" row="0" column="2">
<property name="name">
<cstring>LineEdit1</cstring>
</property>
</widget>
</grid>
</widget>
</grid>
</widget>
</grid>
</widget>
<layoutdefaults spacing="6" margin="11"/>
</UI>

View File

@ -42,6 +42,9 @@
#uic -o DlgRef_1Sel5Spin_QTD.h DlgRef_1Sel5Spin_QTD.ui #uic -o DlgRef_1Sel5Spin_QTD.h DlgRef_1Sel5Spin_QTD.ui
#uic -o DlgRef_1Sel5Spin_QTD.cxx -impl DlgRef_1Sel5Spin_QTD.h DlgRef_1Sel5Spin_QTD.ui #uic -o DlgRef_1Sel5Spin_QTD.cxx -impl DlgRef_1Sel5Spin_QTD.h DlgRef_1Sel5Spin_QTD.ui
#uic -o DlgRef_1Sel5Spin1Check_QTD.h DlgRef_1Sel5Spin1Check_QTD.ui
#uic -o DlgRef_1Sel5Spin1Check_QTD.cxx -impl DlgRef_1Sel5Spin1Check_QTD.h DlgRef_1Sel5Spin1Check_QTD.ui
#uic -o DlgRef_1Sel1Check_QTD.h DlgRef_1Sel1Check_QTD.ui #uic -o DlgRef_1Sel1Check_QTD.h DlgRef_1Sel1Check_QTD.ui
#uic -o DlgRef_1Sel1Check_QTD.cxx -impl DlgRef_1Sel1Check_QTD.h DlgRef_1Sel1Check_QTD.ui #uic -o DlgRef_1Sel1Check_QTD.cxx -impl DlgRef_1Sel1Check_QTD.h DlgRef_1Sel1Check_QTD.ui

View File

@ -3014,7 +3014,8 @@ GEOM::GEOM_Shape_ptr GEOM_Gen_i::MakeFilling(GEOM::GEOM_Shape_ptr myShape,
CORBA::Short maxdeg, CORBA::Short maxdeg,
CORBA::Double tol3d, CORBA::Double tol3d,
CORBA::Double tol2d, CORBA::Double tol2d,
CORBA::Short nbiter) CORBA::Short nbiter,
CORBA::Boolean theApprox)
throw (SALOME::SALOME_Exception) throw (SALOME::SALOME_Exception)
{ {
Unexpect aCatch(SALOME_SalomeException); Unexpect aCatch(SALOME_SalomeException);
@ -3053,7 +3054,7 @@ GEOM::GEOM_Shape_ptr GEOM_Gen_i::MakeFilling(GEOM::GEOM_Shape_ptr myShape,
Handle(GeomFill_Line) Line = new GeomFill_Line(i) ; Handle(GeomFill_Line) Line = new GeomFill_Line(i) ;
GeomFill_AppSurf App(mindeg, maxdeg, tol3d, tol2d, nbiter) ; /* user parameters */ GeomFill_AppSurf App(mindeg, maxdeg, tol3d, tol2d, nbiter) ; /* user parameters */
App.Perform(Line, Section) ; App.Perform(Line, Section, theApprox) ;
if (!App.IsDone()) { if (!App.IsDone()) {
THROW_SALOME_CORBA_EXCEPTION("Filling aborted : non valid shape result", SALOME::BAD_PARAM); THROW_SALOME_CORBA_EXCEPTION("Filling aborted : non valid shape result", SALOME::BAD_PARAM);

View File

@ -1012,6 +1012,10 @@ msgstr "Tol. 3D :"
msgid "GEOM_FILLING_NB_ITER" msgid "GEOM_FILLING_NB_ITER"
msgstr "Nb. Iter :" msgstr "Nb. Iter :"
#: GeometryGUI_FillingDlg.cxx:84
msgid "GEOM_FILLING_APPROX"
msgstr "Approximation"
#: GeometryGUI_FuseDlg.cxx:48 #: GeometryGUI_FuseDlg.cxx:48
msgid "GEOM_FUSE_TITLE" msgid "GEOM_FUSE_TITLE"
msgstr "BOOLEAN : Fuse Two Objects" msgstr "BOOLEAN : Fuse Two Objects"

View File

@ -88,6 +88,7 @@ Standard_Integer GEOMImpl_FillingDriver::Execute(TFunction_Logbook& log) const
Standard_Real tol3d = IF.GetTol2D(); Standard_Real tol3d = IF.GetTol2D();
Standard_Real tol2d = IF.GetTol3D(); Standard_Real tol2d = IF.GetTol3D();
Standard_Integer nbiter = IF.GetNbIter(); Standard_Integer nbiter = IF.GetNbIter();
Standard_Boolean isApprox = IF.GetApprox();
if (mindeg > maxdeg) { if (mindeg > maxdeg) {
Standard_RangeError::Raise("Minimal degree can not be more than maximal degree"); Standard_RangeError::Raise("Minimal degree can not be more than maximal degree");
@ -115,7 +116,7 @@ Standard_Integer GEOMImpl_FillingDriver::Execute(TFunction_Logbook& log) const
Handle(GeomFill_Line) Line = new GeomFill_Line(i); Handle(GeomFill_Line) Line = new GeomFill_Line(i);
GeomFill_AppSurf App (mindeg, maxdeg, tol3d, tol2d, nbiter); /* user parameters */ GeomFill_AppSurf App (mindeg, maxdeg, tol3d, tol2d, nbiter); /* user parameters */
App.Perform(Line, Section); App.Perform(Line, Section, isApprox);
if (!App.IsDone()) return 0; if (!App.IsDone()) return 0;
Standard_Integer UDegree, VDegree, NbUPoles, NbVPoles, NbUKnots, NbVKnots; Standard_Integer UDegree, VDegree, NbUPoles, NbVPoles, NbUKnots, NbVKnots;

View File

@ -1110,7 +1110,7 @@ Handle(GEOM_Object) GEOMImpl_I3DPrimOperations::MakeSolidShell (Handle(GEOM_Obje
//============================================================================= //=============================================================================
Handle(GEOM_Object) GEOMImpl_I3DPrimOperations::MakeFilling Handle(GEOM_Object) GEOMImpl_I3DPrimOperations::MakeFilling
(Handle(GEOM_Object) theShape, int theMinDeg, int theMaxDeg, (Handle(GEOM_Object) theShape, int theMinDeg, int theMaxDeg,
double theTol2D, double theTol3D, int theNbIter) double theTol2D, double theTol3D, int theNbIter, bool isApprox)
{ {
SetErrorCode(KO); SetErrorCode(KO);
@ -1138,6 +1138,7 @@ Handle(GEOM_Object) GEOMImpl_I3DPrimOperations::MakeFilling
aFI.SetTol2D(theTol2D); aFI.SetTol2D(theTol2D);
aFI.SetTol3D(theTol3D); aFI.SetTol3D(theTol3D);
aFI.SetNbIter(theNbIter); aFI.SetNbIter(theNbIter);
aFI.SetApprox(isApprox);
//Compute the Solid value //Compute the Solid value
try { try {
@ -1159,9 +1160,13 @@ Handle(GEOM_Object) GEOMImpl_I3DPrimOperations::MakeFilling
} }
//Make a Python command //Make a Python command
GEOM::TPythonDump(aFunction) << aFilling << " = geompy.MakeFilling(" GEOM::TPythonDump pd (aFunction);
pd << aFilling << " = geompy.MakeFilling("
<< theShape << ", " << theMinDeg << ", " << theMaxDeg << ", " << theShape << ", " << theMinDeg << ", " << theMaxDeg << ", "
<< theTol2D << ", " << theTol3D << ", " << theNbIter << ")"; << theTol2D << ", " << theTol3D << ", " << theNbIter;
if(isApprox)
pd << ", " << isApprox;
pd << ")";
SetErrorCode(OK); SetErrorCode(OK);
return aFilling; return aFilling;

View File

@ -83,7 +83,7 @@ class GEOMImpl_I3DPrimOperations : public GEOM_IOperations {
Standard_EXPORT Handle(GEOM_Object) MakeSolidShell (Handle(GEOM_Object) theShell); Standard_EXPORT Handle(GEOM_Object) MakeSolidShell (Handle(GEOM_Object) theShell);
Standard_EXPORT Handle(GEOM_Object) MakeFilling (Handle(GEOM_Object) theShape, int theMinDeg, int theMaxDeg, double theTol2D, double theTol3D, int theNbIter); Standard_EXPORT Handle(GEOM_Object) MakeFilling (Handle(GEOM_Object) theShape, int theMinDeg, int theMaxDeg, double theTol2D, double theTol3D, int theNbIter, bool isApprox);
Standard_EXPORT Handle(GEOM_Object) MakeThruSections(const Handle(TColStd_HSequenceOfTransient)& theSeqSections, Standard_EXPORT Handle(GEOM_Object) MakeThruSections(const Handle(TColStd_HSequenceOfTransient)& theSeqSections,
bool theModeSolid, bool theModeSolid,

View File

@ -28,6 +28,7 @@
#define FILL_ARG_TOL3D 4 #define FILL_ARG_TOL3D 4
#define FILL_ARG_SHAPE 5 #define FILL_ARG_SHAPE 5
#define FILL_ARG_NBITER 6 #define FILL_ARG_NBITER 6
#define FILL_ARG_APPROX 7
class GEOMImpl_IFilling class GEOMImpl_IFilling
{ {
@ -47,6 +48,9 @@ class GEOMImpl_IFilling
void SetNbIter(int theNbIter) { _func->SetInteger(FILL_ARG_NBITER, theNbIter); } void SetNbIter(int theNbIter) { _func->SetInteger(FILL_ARG_NBITER, theNbIter); }
int GetNbIter() { return _func->GetInteger(FILL_ARG_NBITER); } int GetNbIter() { return _func->GetInteger(FILL_ARG_NBITER); }
void SetApprox(bool theApprox) { _func->SetInteger(FILL_ARG_APPROX, theApprox); }
bool GetApprox() { return _func->GetInteger(FILL_ARG_APPROX); }
void SetShape(Handle(GEOM_Function) theShape) { _func->SetReference(FILL_ARG_SHAPE, theShape); } void SetShape(Handle(GEOM_Function) theShape) { _func->SetReference(FILL_ARG_SHAPE, theShape); }
Handle(GEOM_Function) GetShape() { return _func->GetReference(FILL_ARG_SHAPE); } Handle(GEOM_Function) GetShape() { return _func->GetReference(FILL_ARG_SHAPE); }

View File

@ -567,7 +567,8 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeFilling(GEOM::GEOM_Object_pt
CORBA::Long theMaxDeg, CORBA::Long theMaxDeg,
CORBA::Double theTol2D, CORBA::Double theTol2D,
CORBA::Double theTol3D, CORBA::Double theTol3D,
CORBA::Long theNbIter) CORBA::Long theNbIter,
CORBA::Boolean theApprox)
{ {
GEOM::GEOM_Object_var aGEOMObject; GEOM::GEOM_Object_var aGEOMObject;
@ -583,7 +584,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeFilling(GEOM::GEOM_Object_pt
if (aShape.IsNull()) return aGEOMObject._retn(); if (aShape.IsNull()) return aGEOMObject._retn();
//Create the Solid //Create the Solid
Handle(GEOM_Object) anObject = GetOperations()->MakeFilling(aShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter); Handle(GEOM_Object) anObject = GetOperations()->MakeFilling(aShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter, theApprox);
if (!GetOperations()->IsDone() || anObject.IsNull()) if (!GetOperations()->IsDone() || anObject.IsNull())
return aGEOMObject._retn(); return aGEOMObject._retn();

View File

@ -105,7 +105,7 @@ class GEOM_I_EXPORT GEOM_I3DPrimOperations_i :
GEOM::GEOM_Object_ptr theAxis, GEOM::GEOM_Object_ptr theAxis,
CORBA::Double theAngle); CORBA::Double theAngle);
GEOM::GEOM_Object_ptr MakeFilling(GEOM::GEOM_Object_ptr theShape, CORBA::Long theMinDeg, CORBA::Long theMaxDeg, CORBA::Double theTol2D, CORBA::Double theTol3D, CORBA::Long theNbIter); GEOM::GEOM_Object_ptr MakeFilling(GEOM::GEOM_Object_ptr theShape, CORBA::Long theMinDeg, CORBA::Long theMaxDeg, CORBA::Double theTol2D, CORBA::Double theTol3D, CORBA::Long theNbIter, CORBA::Boolean theApprox);
GEOM::GEOM_Object_ptr MakeThruSections(const GEOM::ListOfGO& theSeqSections, GEOM::GEOM_Object_ptr MakeThruSections(const GEOM::ListOfGO& theSeqSections,
CORBA::Boolean theModeSolid, CORBA::Boolean theModeSolid,

View File

@ -1019,12 +1019,12 @@ GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeRevolutionAxisAngle2Ways (GEOM::GEOM_Ob
GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilling (GEOM::GEOM_Object_ptr theShape, GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilling (GEOM::GEOM_Object_ptr theShape,
CORBA::Long theMinDeg, CORBA::Long theMaxDeg, CORBA::Long theMinDeg, CORBA::Long theMaxDeg,
CORBA::Double theTol2D, CORBA::Double theTol3D, CORBA::Double theTol2D, CORBA::Double theTol3D,
CORBA::Long theNbIter) CORBA::Long theNbIter, CORBA::Boolean theApprox)
{ {
beginService( " GEOM_Superv_i::MakeFilling" ); beginService( " GEOM_Superv_i::MakeFilling" );
MESSAGE("GEOM_Superv_i::MakeFilling"); MESSAGE("GEOM_Superv_i::MakeFilling");
get3DPrimOp(); get3DPrimOp();
GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeFilling(theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter); GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeFilling(theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter, theApprox);
endService( " GEOM_Superv_i::MakeFilling" ); endService( " GEOM_Superv_i::MakeFilling" );
return anObj; return anObj;
} }

View File

@ -237,7 +237,7 @@ public:
GEOM::GEOM_Object_ptr MakeFilling (GEOM::GEOM_Object_ptr theShape, GEOM::GEOM_Object_ptr MakeFilling (GEOM::GEOM_Object_ptr theShape,
CORBA::Long theMinDeg, CORBA::Long theMaxDeg, CORBA::Long theMinDeg, CORBA::Long theMaxDeg,
CORBA::Double theTol2D, CORBA::Double theTol3D, CORBA::Double theTol2D, CORBA::Double theTol3D,
CORBA::Long theNbIter); CORBA::Long theNbIter, CORBA::Boolean theApprox);
GEOM::GEOM_Object_ptr MakeThruSections(const GEOM::ListOfGO& theSeqSections, GEOM::GEOM_Object_ptr MakeThruSections(const GEOM::ListOfGO& theSeqSections,
CORBA::Boolean theModeSolid, CORBA::Boolean theModeSolid,

View File

@ -700,8 +700,8 @@ def MakeCopy(aShape):
print "MakeCopy : ", InsertOp.GetErrorCode() print "MakeCopy : ", InsertOp.GetErrorCode()
return anObj return anObj
def MakeFilling(aShape,mindeg,maxdeg,tol2d,tol3d,nbiter): def MakeFilling(aShape,mindeg,maxdeg,tol2d,tol3d,nbiter,isApprox=0):
anObj = PrimOp.MakeFilling(aShape,mindeg,maxdeg,tol2d,tol3d,nbiter) anObj = PrimOp.MakeFilling(aShape,mindeg,maxdeg,tol2d,tol3d,nbiter,isApprox)
if PrimOp.IsDone() == 0: if PrimOp.IsDone() == 0:
print "MakeFilling : ", PrimOp.GetErrorCode() print "MakeFilling : ", PrimOp.GetErrorCode()
return anObj return anObj

View File

@ -1379,8 +1379,8 @@ class geompyDC(GEOM._objref_GEOM_Gen):
# @return New GEOM_Object, containing the created filling surface. # @return New GEOM_Object, containing the created filling surface.
# #
# Example: see GEOM_TestAll.py # Example: see GEOM_TestAll.py
def MakeFilling(self,theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter): def MakeFilling(self,theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter, isApprox=0):
anObj = self.PrimOp.MakeFilling(theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter) anObj = self.PrimOp.MakeFilling(theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter, isApprox)
RaiseIfFailed("MakeFilling", self.PrimOp) RaiseIfFailed("MakeFilling", self.PrimOp)
return anObj return anObj

View File

@ -46,6 +46,7 @@
#include "GEOMImpl_Types.hxx" #include "GEOMImpl_Types.hxx"
#include <qlabel.h> #include <qlabel.h>
#include <qcheckbox.h>
#include "utilities.h" #include "utilities.h"
@ -72,7 +73,7 @@ GenerationGUI_FillingDlg::GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI,
RadioButton2->close(TRUE); RadioButton2->close(TRUE);
RadioButton3->close(TRUE); RadioButton3->close(TRUE);
GroupPoints = new DlgRef_1Sel5Spin(this, "GroupPoints"); GroupPoints = new DlgRef_1Sel5Spin1Check(this, "GroupPoints");
GroupPoints->GroupBox1->setTitle(tr("GEOM_ARGUMENTS")); GroupPoints->GroupBox1->setTitle(tr("GEOM_ARGUMENTS"));
GroupPoints->TextLabel1->setText(tr("GEOM_FILLING_COMPOUND")); GroupPoints->TextLabel1->setText(tr("GEOM_FILLING_COMPOUND"));
GroupPoints->TextLabel2->setText(tr("GEOM_FILLING_MIN_DEG")); GroupPoints->TextLabel2->setText(tr("GEOM_FILLING_MIN_DEG"));
@ -80,13 +81,14 @@ GenerationGUI_FillingDlg::GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI,
GroupPoints->TextLabel4->setText(tr("GEOM_FILLING_NB_ITER")); GroupPoints->TextLabel4->setText(tr("GEOM_FILLING_NB_ITER"));
GroupPoints->TextLabel5->setText(tr("GEOM_FILLING_MAX_DEG")); GroupPoints->TextLabel5->setText(tr("GEOM_FILLING_MAX_DEG"));
GroupPoints->TextLabel6->setText(tr("GEOM_FILLING_TOL_3D")); GroupPoints->TextLabel6->setText(tr("GEOM_FILLING_TOL_3D"));
GroupPoints->CheckBox1->setText(tr("GEOM_FILLING_APPROX"));
GroupPoints->PushButton1->setPixmap(image1); GroupPoints->PushButton1->setPixmap(image1);
GroupPoints->LineEdit1->setReadOnly( true ); GroupPoints->LineEdit1->setReadOnly( true );
Layout1->addWidget(GroupPoints, 2, 0); Layout1->addWidget(GroupPoints, 2, 0);
/***************************************************************/ /***************************************************************/
setHelpFileName("creaet_filling_page.html"); setHelpFileName("create_filling_page.html");
/* Initialisations */ /* Initialisations */
Init(); Init();
@ -116,6 +118,7 @@ void GenerationGUI_FillingDlg::Init()
myTol3D = 0.0001; myTol3D = 0.0001;
myTol2D = 0.0001; myTol2D = 0.0001;
myNbIter = 5; myNbIter = 5;
myIsApprox = false;
myOkCompound = false; myOkCompound = false;
globalSelection( GEOM_COMPOUND ); globalSelection( GEOM_COMPOUND );
@ -147,6 +150,7 @@ void GenerationGUI_FillingDlg::Init()
connect(GroupPoints->SpinBox_3, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); connect(GroupPoints->SpinBox_3, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
connect(GroupPoints->SpinBox_4, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); connect(GroupPoints->SpinBox_4, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
connect(GroupPoints->SpinBox_5, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); connect(GroupPoints->SpinBox_5, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
connect(GroupPoints->CheckBox1, SIGNAL(stateChanged(int)), this, SLOT(ApproxChanged()));
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_1, SLOT(SetStep(double))); connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_1, SLOT(SetStep(double)));
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_2, SLOT(SetStep(double))); connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_2, SLOT(SetStep(double)));
@ -309,6 +313,16 @@ void GenerationGUI_FillingDlg::ValueChangedInSpinBox(double newValue)
displayPreview(); displayPreview();
} }
//=================================================================================
// function : ApproxChanged()
// purpose :
//=================================================================================
void GenerationGUI_FillingDlg::ApproxChanged()
{
myIsApprox = GroupPoints->CheckBox1->isChecked();
displayPreview();
}
//================================================================================= //=================================================================================
// function : createOperation // function : createOperation
// purpose : // purpose :
@ -336,7 +350,7 @@ bool GenerationGUI_FillingDlg::execute( ObjectList& objects )
GEOM::GEOM_Object_var anObj; GEOM::GEOM_Object_var anObj;
anObj = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation() )->MakeFilling( anObj = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation() )->MakeFilling(
myCompound, myMinDeg, myMaxDeg, myTol2D, myTol3D, myNbIter ); myCompound, myMinDeg, myMaxDeg, myTol2D, myTol3D, myNbIter, myIsApprox );
if ( !anObj->_is_nil() ) if ( !anObj->_is_nil() )
objects.push_back( anObj._retn() ); objects.push_back( anObj._retn() );

View File

@ -31,7 +31,7 @@
#include "GenerationGUI.h" #include "GenerationGUI.h"
#include "GEOMBase_Skeleton.h" #include "GEOMBase_Skeleton.h"
#include "DlgRef_1Sel5Spin.h" #include "DlgRef_1Sel5Spin1Check.h"
//================================================================================= //=================================================================================
// class : GenerationGUI_FillingDlg // class : GenerationGUI_FillingDlg
@ -62,9 +62,10 @@ private:
Standard_Real myTol3D; Standard_Real myTol3D;
Standard_Real myTol2D; Standard_Real myTol2D;
Standard_Integer myNbIter; Standard_Integer myNbIter;
bool myIsApprox;
bool myOkCompound; /* to check when curv. compound is defined */ bool myOkCompound; /* to check when curv. compound is defined */
DlgRef_1Sel5Spin* GroupPoints; DlgRef_1Sel5Spin1Check* GroupPoints;
private slots: private slots:
void ClickOnOk(); void ClickOnOk();
@ -74,6 +75,7 @@ private slots:
void SelectionIntoArgument(); void SelectionIntoArgument();
void SetEditCurrentArgument(); void SetEditCurrentArgument();
void ValueChangedInSpinBox(double newValue); void ValueChangedInSpinBox(double newValue);
void ApproxChanged();
}; };
#endif // DIALOGBOX_FILLING_H #endif // DIALOGBOX_FILLING_H