View Issue Details

IDProjectCategoryView StatusLast Update
0027264Open CASCADEOCCT:Modeling Datapublic2021-02-15 16:27
ReportersanAssigned Tobugmaster  
PrioritynormalSeveritytrivial 
Status closedResolutionfixed 
Target Version7.1.0Fixed in Version7.1.0 
Summary0027264: Weird difference between two BRepTools::Write() overloads
DescriptionBRepTools::Write() method that accepts a file name argument writes and extra header line to the output .brep file:

DBRep_DrawableShape

This line is important for DRAW for some reason, thus Write() overload that accepts a stream and does not add this header line produces .brep files that cannot be read by DRAW "restore" command.

It is proposed to stop checking this line in .brep files and stop writing this line to .brep files and ignore this line if it exists in older .brep files.
Steps To Reproduce.
TagsNo tags attached.
Test case numberbugs modalg_6 bug27264_1, bug27264_2, bug27264_3, bug27264_4, bug27264_5, bug27264_6

Attached Files

  • brep_cs.7z (1,025 bytes)

Relationships

related to 0031990 closedbugmaster Coding, Draw Harness - Replace C-like pointers to function in Draw_SaveAndRestore class to virtual function 

Activities

msv

2016-03-15 19:17

developer   ~0051674

BRep file can contain not only a shape, but other OCCT entities, like curves, surfaces, and even real variable. The kind of Drawable to create upon reading the file is defined in this header line.
Therefore we cannot totally remove support of this line.
However, we can suppose that the file contains a shape if the header is absent, and make such fix in 'restore'.

san

2016-03-15 19:19

developer   ~0051675

Yes, now I understand that the problem is a bit more complicated than it looked initially.
That is why this issue is re-scheduled to 7.1.0 - we need to analyze carefully the consequences of this modification to eliminate any impact on DRAW-based test system...

git

2016-07-11 12:52

administrator   ~0055811

Branch CR27264 has been created by isn.

SHA-1: 271c66e9ff10c60ae3b20ee4ad7a146f2024c38d


Detailed log of new commits:

Author: isn
Date: Mon Jul 11 12:52:59 2016 +0300

    0027264: Weird difference between two BRepTools::Write() overloads
    
    Assume that the brep file contains DBRep_DrawableShape variable if the file header is absent

git

2016-07-14 13:45

administrator   ~0055907

Branch CR27264 has been updated by isn.

SHA-1: df4ed076a785ddefbb00ebc95ccafcd8edd2a688


Detailed log of new commits:

Author: isn
Date: Thu Jul 14 13:45:18 2016 +0300

    test cases

isn

2016-07-14 13:47

developer  

brep_cs.7z (1,025 bytes)

msv

2016-07-14 15:42

developer   ~0055911

tests\bugs\modalg_6\bug27264_3
tests\bugs\modalg_6\bug27264_4
tests\bugs\modalg_6\bug27264_5
tests\bugs\modalg_6\bug27264_6

- Put more detailed message instead of "Error", something like "Error: null shape is expected"

git

2016-07-14 17:16

administrator   ~0055915

Branch CR27264 has been updated by isn.

SHA-1: d08bcc5314433b80abe06c54820f6e6838085cb7


Detailed log of new commits:

Author: isn
Date: Thu Jul 14 17:17:22 2016 +0300

    remark

msv

2016-07-14 17:33

developer   ~0055916

Reviewed.

git

2016-07-14 20:08

administrator   ~0055923

Branch CR27264 has been updated forcibly by mkv.

SHA-1: 7bbf29c1d0a1e31fef72d8fc1bf0fbb0c7a03c86

mkv

2016-07-15 15:54

tester   ~0055951

Dear BugMaster,
Branch CR27264 was rebased on IR-2016-07-14 of occt git-repository.
SHA-1: 7bbf29c1d0a1e31fef72d8fc1bf0fbb0c7a03c86

mkv

2016-07-15 15:54

tester   ~0055952

Dear BugMaster,
Branch CR27264 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested on Release mode.
SHA-1: 7bbf29c1d0a1e31fef72d8fc1bf0fbb0c7a03c86

Number of compiler warnings:

occt component :
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS : 0 (0 on master)

products component :
Linux: 64 (64 on master)
Windows: 0 (0 on master)
MacOS : 1148

Regressions/Differences/Improvements:
No regressions/differences

Testing cases:
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_1.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_1.html
bugs modalg_6 bug27264_1: OK
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_2.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_2.html
bugs modalg_6 bug27264_2: OK
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_3.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_3.html
bugs modalg_6 bug27264_3: OK
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_4.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_4.html
bugs modalg_6 bug27264_4: OK
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_5.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_5.html
bugs modalg_6 bug27264_5: OK
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Debian70-64/bugs/modalg_6/bug27264_6.html
http://occt-tests/CR27264-IR-2016-07-14-OCCT/Windows-64-VC10/bugs/modalg_6/bug27264_6.html
bugs modalg_6 bug27264_6: OK

Testing on Linux:
occt component :
Total MEMORY difference: 90159672 / 90007695 [+0.17%]
Total CPU difference: 19243.409999999967 / 19191.64999999992 [+0.27%]
products component :
Total MEMORY difference: 30068272 / 30103171 [-0.12%]
Total CPU difference: 5092.619999999982 / 5118.619999999969 [-0.51%]

Testing on Windows:
occt component :
Total MEMORY difference: 57439818 / 57431602 [+0.01%]
Total CPU difference: 18382.31543459899 / 18076.974677298753 [+1.69%]
products component :
Total MEMORY difference: 21262924 / 21224923 [+0.18%]
Total CPU difference: 4933.36002389996 / 4905.607445999939 [+0.57%]

There are no differences in images found by testdiff.

mkv

2016-07-15 15:55

tester   ~0055953

Dear BugMaster,
Branch CR27264 is TESTED.

git

2016-07-22 10:43

administrator   ~0056103

Branch CR27264 has been deleted by inv.

SHA-1: 7bbf29c1d0a1e31fef72d8fc1bf0fbb0c7a03c86

Related Changesets

occt: master 4aa09e31

2016-07-11 09:52:59

isn


Committer: bugmaster Details Diff
0027264: Weird difference between two BRepTools::Write() overloads

Assume that the brep file contains DBRep_DrawableShape variable if the file header is absent

test cases
Affected Issues
0027264
mod - src/Draw/Draw_VariableCommands.cxx Diff File
add - tests/bugs/modalg_6/bug27264_1 Diff File
add - tests/bugs/modalg_6/bug27264_2 Diff File
add - tests/bugs/modalg_6/bug27264_3 Diff File
add - tests/bugs/modalg_6/bug27264_4 Diff File
add - tests/bugs/modalg_6/bug27264_5 Diff File
add - tests/bugs/modalg_6/bug27264_6 Diff File

Issue History

Date Modified Username Field Change
2016-03-15 18:44 san New Issue
2016-03-15 18:44 san Assigned To => msv
2016-03-15 18:54 san Target Version 7.0.0 => 7.1.0
2016-03-15 19:17 msv Note Added: 0051674
2016-03-15 19:19 san Note Added: 0051675
2016-07-06 17:05 msv Assigned To msv => isn
2016-07-06 17:05 msv Status new => assigned
2016-07-11 12:52 git Note Added: 0055811
2016-07-14 13:45 git Note Added: 0055907
2016-07-14 13:47 isn File Added: brep_cs.7z
2016-07-14 13:48 isn Assigned To isn => msv
2016-07-14 13:48 isn Status assigned => resolved
2016-07-14 13:48 isn Steps to Reproduce Updated
2016-07-14 15:42 msv Note Added: 0055911
2016-07-14 15:42 msv Assigned To msv => isn
2016-07-14 15:42 msv Status resolved => assigned
2016-07-14 17:16 git Note Added: 0055915
2016-07-14 17:17 isn Assigned To isn => msv
2016-07-14 17:17 isn Status assigned => resolved
2016-07-14 17:33 msv Note Added: 0055916
2016-07-14 17:33 msv Assigned To msv => bugmaster
2016-07-14 17:33 msv Status resolved => reviewed
2016-07-14 20:08 git Note Added: 0055923
2016-07-14 20:10 mkv Assigned To bugmaster => mkv
2016-07-15 15:54 mkv Note Added: 0055951
2016-07-15 15:54 mkv Note Added: 0055952
2016-07-15 15:55 mkv Note Added: 0055953
2016-07-15 15:55 mkv Assigned To mkv => bugmaster
2016-07-15 15:55 mkv Status reviewed => tested
2016-07-15 15:55 mkv Test case number => bugs modalg_6 bug27264_1, bug27264_2, bug27264_3, bug27264_4, bug27264_5, bug27264_6
2016-07-22 10:23 bugmaster Changeset attached => occt master 4aa09e31
2016-07-22 10:23 bugmaster Status tested => verified
2016-07-22 10:23 bugmaster Resolution open => fixed
2016-07-22 10:43 git Note Added: 0056103
2016-12-09 16:31 aiv Status verified => closed
2016-12-09 16:38 aiv Fixed in Version => 7.1.0
2021-02-15 16:27 asuraven Relationship added related to 0031990