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

Draw command 'EnsureTolRule' was replaced by command 'updatetolerance' in

tests.

Draw command 'EnsureTolRule' was removed.
This commit is contained in:
abk 2013-02-14 21:33:15 +04:00
parent 6e1764d5d8
commit 4c8d711eb1
46 changed files with 48 additions and 71 deletions

View File

@ -800,27 +800,6 @@ static Standard_Integer scalexyz(Draw_Interpretor& di, Standard_Integer n, const
return 0; return 0;
} }
static Standard_Integer EnsureTolRule(
Draw_Interpretor & theDI, Standard_Integer theC, const char ** theAs)
{
if (theC != 3)
{
return 1;
}
//
TopoDS_Shape aS = DBRep::Get(theAs[2]);
if (aS.IsNull())
{
return 1;
}
//
TopoDS_Shape aRes = BRepBuilderAPI_Copy(aS);
BRepLib::UpdateTolerances(aRes);
//
DBRep::Set(theAs[1], aRes);
return 0;
}
void BRepTest::BasicCommands(Draw_Interpretor& theCommands) void BRepTest::BasicCommands(Draw_Interpretor& theCommands)
{ {
static Standard_Boolean done = Standard_False; static Standard_Boolean done = Standard_False;
@ -952,6 +931,4 @@ void BRepTest::BasicCommands(Draw_Interpretor& theCommands)
"scalexyz res shape factor_x factor_y factor_z", "scalexyz res shape factor_x factor_y factor_z",
__FILE__, __FILE__,
scalexyz, g); scalexyz, g);
theCommands.Add("EnsureTolRule", "res shape", __FILE__, EnsureTolRule, g);
} }

View File

@ -1,7 +1,7 @@
if { [isdraw result] } { if { [isdraw result] } {
#check if result is valid #check if result is valid
EnsureTolRule result result updatetolerance result
puts "checkshape" puts "checkshape"
set ch [checkshape result] set ch [checkshape result]
puts $ch puts $ch

View File

@ -9,7 +9,7 @@ puts ""
########################################################### ###########################################################
restore [locate_data_file OCC329.brep] a restore [locate_data_file OCC329.brep] a
EnsureTolRule a a updatetolerance a
checkshape a checkshape a
set tol1 [maxtolerance a] set tol1 [maxtolerance a]

View File

@ -10,7 +10,7 @@ puts ""
restore [locate_data_file buc60462a.brep] a restore [locate_data_file buc60462a.brep] a
checkshape a checkshape a
restore [locate_data_file buc60462b.brep] b restore [locate_data_file buc60462b.brep] b
EnsureTolRule b b updatetolerance b
checkshape b checkshape b
bsection result a b bsection result a b

View File

@ -10,7 +10,7 @@ cpulimit 1400
restore [locate_data_file buc60463a.brep] a restore [locate_data_file buc60463a.brep] a
checkshape a checkshape a
restore [locate_data_file buc60463b.brep] b restore [locate_data_file buc60463b.brep] b
EnsureTolRule b b updatetolerance b
checkshape b checkshape b
bsection result a b bsection result a b

View File

@ -9,7 +9,7 @@ puts ""
################################################################# #################################################################
restore [locate_data_file OCC292.brep] result restore [locate_data_file OCC292.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -7,7 +7,7 @@ puts ""
################################################## ##################################################
restore [locate_data_file OCC317.brep] result restore [locate_data_file OCC317.brep] result
EnsureTolRule result result updatetolerance result
set che [checkshape result] set che [checkshape result]
if { [regexp {Faulty} $che] == 1} { if { [regexp {Faulty} $che] == 1} {

View File

@ -10,7 +10,7 @@ puts ""
################################################## ##################################################
restore [locate_data_file OCC330.brep] result restore [locate_data_file OCC330.brep] result
EnsureTolRule result result updatetolerance result
decho off decho off
set che [checkshape result] set che [checkshape result]

View File

@ -7,7 +7,7 @@ puts "========"
puts "" puts ""
restore [locate_data_file mds-part1.rle] a restore [locate_data_file mds-part1.rle] a
EnsureTolRule a a updatetolerance a
set che [checkshape a] set che [checkshape a]
if { [regexp {Faulty} $che ] == 1 } { if { [regexp {Faulty} $che ] == 1 } {
puts "Faulty OCC452 (shape 1): Source shape is invalid. It was detected by Checkshape command" puts "Faulty OCC452 (shape 1): Source shape is invalid. It was detected by Checkshape command"
@ -24,7 +24,7 @@ if { [regexp {Faulty} $che ] == 1 } {
} }
restore [locate_data_file CTO900_ger60239a.rle] c restore [locate_data_file CTO900_ger60239a.rle] c
EnsureTolRule c c updatetolerance c
set che [checkshape c] set che [checkshape c]
if { [regexp {Faulty} $che ] == 1 } { if { [regexp {Faulty} $che ] == 1 } {
puts "Faulty OCC452 (shape 3): Source shape is invalid. It was detected by Checkshape command" puts "Faulty OCC452 (shape 3): Source shape is invalid. It was detected by Checkshape command"
@ -33,7 +33,7 @@ if { [regexp {Faulty} $che ] == 1 } {
} }
restore [locate_data_file CTO900_ger60239b.rle] d restore [locate_data_file CTO900_ger60239b.rle] d
EnsureTolRule d d updatetolerance d
set che [checkshape d] set che [checkshape d]
if { [regexp {Faulty} $che ] == 1 } { if { [regexp {Faulty} $che ] == 1 } {
puts "Faulty OCC452 (shape 4): Source shape is invalid. It was detected by Checkshape command" puts "Faulty OCC452 (shape 4): Source shape is invalid. It was detected by Checkshape command"

View File

@ -7,7 +7,7 @@ puts "========"
puts "" puts ""
restore [locate_data_file CTO900_ger60239a.rle] a restore [locate_data_file CTO900_ger60239a.rle] a
EnsureTolRule a a updatetolerance a
set che [checkshape a] set che [checkshape a]
if { [regexp {Faulty} $che ] == 1 } { if { [regexp {Faulty} $che ] == 1 } {
puts "Faulty OCC452 (shape 5): Source shape is invalid. It was detected by Checkshape command" puts "Faulty OCC452 (shape 5): Source shape is invalid. It was detected by Checkshape command"
@ -16,7 +16,7 @@ if { [regexp {Faulty} $che ] == 1 } {
} }
restore [locate_data_file CTO900_ger60239b.rle] b restore [locate_data_file CTO900_ger60239b.rle] b
EnsureTolRule b b updatetolerance b
set che [checkshape b] set che [checkshape b]
if { [regexp {Faulty} $che ] == 1 } { if { [regexp {Faulty} $che ] == 1 } {
puts "Faulty OCC452 (shape 6): Source shape is invalid. It was detected by Checkshape command" puts "Faulty OCC452 (shape 6): Source shape is invalid. It was detected by Checkshape command"

View File

@ -7,7 +7,7 @@ cpulimit 10000
restore [locate_data_file OCC698_1.brep] b4 restore [locate_data_file OCC698_1.brep] b4
checkshape b4 checkshape b4
restore [locate_data_file OCC698_2.brep] b5 restore [locate_data_file OCC698_2.brep] b5
EnsureTolRule b5 b5 updatetolerance b5
checkshape b5 checkshape b5
bcut result b5 b4 bcut result b5 b4

View File

@ -10,7 +10,7 @@ puts ""
###################################################### ######################################################
restore [locate_data_file OCC697_1.brep] b1 restore [locate_data_file OCC697_1.brep] b1
EnsureTolRule b1 b1 updatetolerance b1
restore [locate_data_file OCC697_2.brep] b2 restore [locate_data_file OCC697_2.brep] b2
checkshape b1 checkshape b1

View File

@ -10,7 +10,7 @@ puts ""
################################# #################################
restore [locate_data_file OCC774.brep] a restore [locate_data_file OCC774.brep] a
EnsureTolRule a a updatetolerance a
explode a explode a
checkshape a_1 checkshape a_1
checkshape a_2 checkshape a_2

View File

@ -10,7 +10,7 @@ puts ""
########################################## ##########################################
restore [locate_data_file OCC776.brep] a restore [locate_data_file OCC776.brep] a
EnsureTolRule a a updatetolerance a
explode a explode a
checkshape a_1 checkshape a_1
checkshape a_2 checkshape a_2

View File

@ -10,7 +10,7 @@ puts ""
########################################## ##########################################
restore [locate_data_file OCC776.brep] a restore [locate_data_file OCC776.brep] a
EnsureTolRule a a updatetolerance a
explode a explode a
checkshape a_1 checkshape a_1
checkshape a_2 checkshape a_2

View File

@ -8,7 +8,7 @@ puts ""
########################################################## ##########################################################
restore [locate_data_file BUC60877_lh.brep] sh restore [locate_data_file BUC60877_lh.brep] sh
EnsureTolRule sh sh updatetolerance sh
checkshape sh checkshape sh
plane pl 820 198 140 -1e-06 0 1 plane pl 820 198 140 -1e-06 0 1

View File

@ -14,7 +14,7 @@ explode a
# See comment in CR23244: # See comment in CR23244:
restore [locate_data_file OCC919-PROC.brep] a_1 restore [locate_data_file OCC919-PROC.brep] a_1
EnsureTolRule a_1 a_1 updatetolerance a_1
# #
checkshape a_1 checkshape a_1

View File

@ -7,7 +7,7 @@ puts "=========="
pload QAcommands pload QAcommands
restore [locate_data_file buc60652b.brep] result restore [locate_data_file buc60652b.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
BUC60652 result BUC60652 result

View File

@ -7,7 +7,7 @@ puts "==========="
pload QAcommands pload QAcommands
restore [locate_data_file buc60652c.brep] result restore [locate_data_file buc60652c.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
BUC60652 result BUC60652 result

View File

@ -7,7 +7,7 @@ puts ""
## Fillets created in CasCade version 3 do not display as shaded surfaces. ## Fillets created in CasCade version 3 do not display as shaded surfaces.
################################################# #################################################
restore [locate_data_file buc60707a.brep] result restore [locate_data_file buc60707a.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -9,7 +9,7 @@ puts ""
############################################## ##############################################
restore [locate_data_file OCC368.brep] result restore [locate_data_file OCC368.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -8,7 +8,7 @@ puts "=================================="
puts "" puts ""
restore [locate_data_file fra62476b.brep] result restore [locate_data_file fra62476b.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -5,7 +5,7 @@ puts "==========="
restore [locate_data_file ger61235a.brep] tool restore [locate_data_file ger61235a.brep] tool
checkshape tool checkshape tool
restore [locate_data_file ger61235b.brep] object restore [locate_data_file ger61235b.brep] object
EnsureTolRule object object updatetolerance object
checkshape object checkshape object
bsection result object tool bsection result object tool

View File

@ -8,7 +8,7 @@ puts "It takes visual check for this BUG"
puts "==================================" puts "=================================="
restore [locate_data_file pro20333a.brep] result restore [locate_data_file pro20333a.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -5,7 +5,7 @@ puts "BUC60948"
puts "========================" puts "========================"
restore [locate_data_file pump4.brep] a_1 restore [locate_data_file pump4.brep] a_1
EnsureTolRule a_1 a_1 updatetolerance a_1
checkshape a_1 checkshape a_1
##################################################################### #####################################################################

View File

@ -7,7 +7,7 @@ puts ""
######################################################## ########################################################
restore [locate_data_file OCC630.brep] a1 restore [locate_data_file OCC630.brep] a1
EnsureTolRule a1 a1 updatetolerance a1
checkshape a1 checkshape a1
###################################################################### ######################################################################

View File

@ -13,7 +13,7 @@ pload XDE
################################################################## ##################################################################
restore [locate_data_file buc60661a.brep] buc60661 restore [locate_data_file buc60661a.brep] buc60661
EnsureTolRule buc60661 buc60661 updatetolerance buc60661
checkshape buc60661 checkshape buc60661
###################################################################### ######################################################################

View File

@ -4,7 +4,7 @@ puts "(case 1)"
puts "========================" puts "========================"
restore [locate_data_file shading_058.brep] result restore [locate_data_file shading_058.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -4,7 +4,7 @@ puts "(case 4)"
puts "========================" puts "========================"
restore [locate_data_file shading_151.brep] result restore [locate_data_file shading_151.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
tclean result tclean result

View File

@ -8,7 +8,7 @@ puts ""
##################### #####################
restore [locate_data_file OCC859.brep] a restore [locate_data_file OCC859.brep] a
EnsureTolRule a a updatetolerance a
checkshape a checkshape a
sewing result a sewing result a

View File

@ -8,7 +8,7 @@ puts ""
###################################################### ######################################################
restore [locate_data_file OCC859.brep] result restore [locate_data_file OCC859.brep] result
EnsureTolRule result result updatetolerance result
checkshape result checkshape result
freebounds result 0.1 freebounds result 0.1

View File

@ -2,7 +2,7 @@
# Date : 26 Nov 98 # Date : 26 Nov 98
restore [locate_data_file cts21832_base.brep] base restore [locate_data_file cts21832_base.brep] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file cts21832_cont.brep] cont restore [locate_data_file cts21832_cont.brep] cont
explode cont wire explode cont wire

View File

@ -2,7 +2,7 @@
# Date : 23mar98 # Date : 23mar98
restore [locate_data_file CTO900_ger60224-part.rle] base restore [locate_data_file CTO900_ger60224-part.rle] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file ger60224-tool.rle] wire restore [locate_data_file ger60224-tool.rle] wire
mkplane cont wire mkplane cont wire

View File

@ -2,7 +2,7 @@
# Date : 10 Sept 98 # Date : 10 Sept 98
restore [locate_data_file CTO900_pro12880c.rle] base restore [locate_data_file CTO900_pro12880c.rle] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file pro12880_face.rle] cont restore [locate_data_file pro12880_face.rle] cont
featprism base cont cont 0 1 0 1 1 featprism base cont cont 0 1 0 1 1

View File

@ -2,7 +2,7 @@
# Date : 15 Sept 98 # Date : 15 Sept 98
restore [locate_data_file CTO900_ger50084c.rle] base restore [locate_data_file CTO900_ger50084c.rle] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file ger50084_face.rle] wire restore [locate_data_file ger50084_face.rle] wire
## contour est un wire -> on en fait une face ## contour est un wire -> on en fait une face

View File

@ -7,7 +7,7 @@
cpulimit 2000 cpulimit 2000
restore [locate_data_file CFE900_cts20geq.rle] base restore [locate_data_file CFE900_cts20geq.rle] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file cts20960_face.brep] cont restore [locate_data_file cts20960_face.brep] cont
explode base face explode base face

View File

@ -2,7 +2,7 @@
# Date : 25 Nov 98 # Date : 25 Nov 98
restore [locate_data_file cts20088_base.brep] base restore [locate_data_file cts20088_base.brep] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file contour_pkv.rle] cont restore [locate_data_file contour_pkv.rle] cont
explode base face explode base face

View File

@ -2,7 +2,7 @@
# Date : 02 Dec 98 # Date : 02 Dec 98
restore [locate_data_file CFE900_pro16gff.rle] base restore [locate_data_file CFE900_pro16gff.rle] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file pro16769_face.brep] cont restore [locate_data_file pro16769_face.brep] cont
explode base face explode base face

View File

@ -1,7 +1,7 @@
# cts20088 # cts20088
restore [locate_data_file cts20088_base.brep] base restore [locate_data_file cts20088_base.brep] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file contour_pkv.rle] cont restore [locate_data_file contour_pkv.rle] cont
explode base face explode base face

View File

@ -2,7 +2,7 @@
puts "TODO OCC22810 ALL: Error : The area of the resulting shape is" puts "TODO OCC22810 ALL: Error : The area of the resulting shape is"
restore [locate_data_file cts20088_base.brep] base restore [locate_data_file cts20088_base.brep] base
EnsureTolRule base base updatetolerance base
restore [locate_data_file contour_pkv.rle] cont restore [locate_data_file contour_pkv.rle] cont
explode base face explode base face

View File

@ -1,5 +1,5 @@
puts [fixsmall result a 1] puts [fixsmall result a 1]
EnsureTolRule result result updatetolerance result
if { [isdraw result] } { if { [isdraw result] } {
puts [checkshape result] puts [checkshape result]
} }

View File

@ -1,3 +1,3 @@
puts [DT_ApplySeq result a MDTV ToV4] puts [DT_ApplySeq result a MDTV ToV4]
EnsureTolRule result result updatetolerance result
puts [checkshape result] puts [checkshape result]

View File

@ -1,3 +1,3 @@
fixwgaps result a 0.001 fixwgaps result a 0.001
EnsureTolRule result result updatetolerance result
puts [checkshape result] puts [checkshape result]

View File

@ -1,4 +1,4 @@
puts [DT_SplitAngle result a] puts [DT_SplitAngle result a]
EnsureTolRule result result updatetolerance result
puts [checkshape result] puts [checkshape result]

View File

@ -1,3 +1,3 @@
puts [DT_ToBspl result a] puts [DT_ToBspl result a]
EnsureTolRule result result updatetolerance result
puts [checkshape result] puts [checkshape result]

View File

@ -1,2 +1,2 @@
restore [locate_data_file CFE900_pro16gdo.rle] a restore [locate_data_file CFE900_pro16gdo.rle] a
EnsureTolRule a a updatetolerance a