View Issue Details

IDProjectCategoryView StatusLast Update
0031673Open CASCADEOCCT:DRAWpublic2020-12-02 17:13
Reporterkgv Assigned Tobugmaster  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version7.1.0 
Target Version7.5.0Fixed in Version7.5.0 
Summary0031673: Draw Harness, ViewerTest - command vlocation applies transformation in opposite order
DescriptionWithin the sequence of commands vlocation -rotate applied to the same object, the next call is expected to apply transformation relative to previous step. But actual result is opposite - the next call is pre-multiplied making difficult to encode result transformation.
Steps To Reproduce
pload MODELING VISUALIZATION
box b -1 -1 -1 2 2 2
explode b F
vclear
vinit View1
vdisplay -dispMode 0 b_1 b_3 b_4 b_6
vdisplay -dispMode 1 b_2 b_5
vfit
vzoom 0.4
vlocation b_2 -reset
vlocation b_5 -reset
vlocation b_2 -rotate  1 -1 -1 0 1 0 90
vlocation b_2 -rotate -1 -1 -1 0 1 0 90
vlocation b_5 -rotate -1 -1 -1 0 1 0 90
if { [vreadpixel 170 380 -rgb -name] == "BLACK" } { puts "Error" }


Full case:
pload MODELING VISUALIZATION
vclear
vinit View1
vzbufftrihedron
box b -1 -1 -1 2 2 2
explode b F
text2brep tnx nx -pos -1  0  0 -halign center -valign center -height 0.2 -plane  1  0  0  0  1 0
text2brep tpx px -pos  1  0  0 -halign center -valign center -height 0.2 -plane -1  0  0  0 -1 0
text2brep tny ny -pos  0 -1  0 -halign center -valign center -height 0.2 -plane  0  1  0 -1  0 0
text2brep tpy py -pos  0  1  0 -halign center -valign center -height 0.2 -plane  0 -1  0  1  0 0
text2brep tnz nz -pos  0  0 -1 -halign center -valign center -height 0.2 -plane  0  0  1  1  0 0
text2brep tpz pz -pos  0  0  1 -halign center -valign center -height 0.2 -plane  0  0 -1  1  0 0
compound b_1 tnx nx
compound b_2 tpx px
compound b_3 tny ny
compound b_4 tpy py
compound b_5 tnz nz
compound b_6 tpz pz

vdisplay -top nx px ny py nz pz

proc anim_py  {theP} { vlocation py -reset -rotate -1  1  0 0 0 1 [expr  90*$theP] }
proc anim_ny  {theP} { vlocation ny -reset -rotate -1 -1  0 0 0 1 [expr -90*$theP] }
proc anim_pz  {theP} { vlocation pz -reset -rotate -1 -1  1 0 1 0 [expr -90*$theP] }
proc anim_px1 {theP} { vlocation px -reset -rotate  1 -1 -1 0 1 0 [expr  90*$theP] }
proc anim_px2 {theP} { anim_px1 1; vlocation px -rotate -1 -1 -1 0 1 0 [expr  90*$theP] }
proc anim_nz  {theP} { vlocation nz -reset -rotate -1 -1 -1 0 1 0 [expr  90*$theP] }
vanimation -clear
vanimation anim/py  -start 0  -dur 2 -cmd "anim_py  %localNormalized"
vanimation anim/ny  -start 0  -dur 2 -cmd "anim_ny  %localNormalized"
vanimation anim/pz  -start 0  -dur 2 -cmd "anim_pz  %localNormalized"
vanimation anim/px1 -start 0  -dur 2 -cmd "anim_px1 %localNormalized"
vanimation anim/px2 -start 2  -dur 2 -cmd "anim_px2 %localNormalized"
vanimation anim/nz  -start 2  -dur 2 -cmd "anim_nz  %localNormalized"

vanimation anim -play -playSpeed 1
TagsNo tags attached.
Test case numberpointcloud/transformation/bug30162

Attached Files

  • rotate_OK.png (2,165 bytes)
  • rotate_KO.png (2,090 bytes)

Relationships

child of 0027764 closedapn Visualization - add functionality for animation of 3D camera and interactive objects 

Activities

kgv

2020-07-19 00:28

developer  

rotate_OK.png (2,165 bytes)

kgv

2020-07-19 00:28

developer  

rotate_KO.png (2,090 bytes)

git

2020-07-19 00:33

administrator   ~0093188

Branch CR31673 has been created by kgv.

SHA-1: 6d825cd8032d183d6e933e5459a95f3ecb51c7b1


Detailed log of new commits:

Author: kgv
Date: Sun Jul 19 00:36:04 2020 +0300

    0031673: Draw Harness, ViewerTest - vlocation -rotate is applied in opposite order
    
    Transformation multiplication order has been fixed for vlocation -location and -translate commands.

git

2020-07-20 12:06

administrator   ~0093194

Branch CR31673 has been updated forcibly by kgv.

SHA-1: 02a4746e1c7412f150bb49ec924185cf58d5a553

git

2020-07-20 12:08

administrator   ~0093195

Branch CR31673 has been updated forcibly by kgv.

SHA-1: 18bda493723e6a6a75fce90388c2178331134abb

kgv

2020-07-20 13:53

developer   ~0093199

Patch is ready for review in OCCT branch CR31673.

http://jenkins-test-12.nnov.opencascade.com:8080/view/CR31673-master-KGV/

osa

2020-07-21 09:24

developer   ~0093217

The patch was reviewed

kgv

2020-07-23 11:54

developer   ~0093259

Please also take CR31673 branch from OCC Products into IR.

bugmaster

2020-07-25 13:23

administrator   ~0093322

Combination -
OCCT branch : IR-2020-07-24
master SHA - 4c7a3faef5f292475c23ee615ad49d57fc039b58
a206de37fbfa0bf71bd534ae47192bbec23b8522
Products branch : IR-2020-07-24 SHA - be95aa91db3bd344c872901349e58022d3c687fc
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 17271.39000000011 / 17230.04000000007 [+0.24%]
Products
Total CPU difference: 800.6699999999917 / 791.7399999999936 [+1.13%]
Windows-64-VC14:
OCCT
Total CPU difference: 18742.140625 / 18745.390625 [-0.02%]
Products
Total CPU difference: 1329.234375 / 1321.390625 [+0.59%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2020-07-25 14:02

administrator   ~0093341

Branch CR31673 has been deleted by inv.

SHA-1: 18bda493723e6a6a75fce90388c2178331134abb

Related Changesets

occt: master dbc8becf

2020-07-18 21:36:04

kgv


Committer: bugmaster Details Diff
0031673: Draw Harness, ViewerTest - command vlocation applies transformation in opposite order

gp_Trsf::SetRotationPart() - added method replacing rotation matrix without reseting other components,
similar to existing SetTraslationPart() and SetScaleFactor().

Transformation multiplication order has been fixed
for vlocation arguments -rotate, -translate, -mirror and -scale.
Added -prerotate, -pretranslate, -premirror and -prescale options following previous behavior.

vlocation -setRotation now uses new method gp_Trsf::SetRotationPart()
for consistency with methods -setLocation and -setScale.
Affected Issues
0031673
mod - samples/tcl/pathtrace_cube.tcl Diff File
mod - src/gp/gp_Trsf.cxx Diff File
mod - src/gp/gp_Trsf.hxx Diff File
mod - src/ViewerTest/ViewerTest_ObjectCommands.cxx Diff File
mod - tests/bugs/vis/bug25276 Diff File
add - tests/bugs/vis/bug31673 Diff File
mod - tests/v3d/glsl/bndbox1 Diff File
mod - tests/v3d/raytrace/bug25221 Diff File

Issue History

Date Modified Username Field Change
2020-07-19 00:27 kgv New Issue
2020-07-19 00:27 kgv Assigned To => kgv
2020-07-19 00:28 kgv File Added: rotate_OK.png
2020-07-19 00:28 kgv File Added: rotate_KO.png
2020-07-19 00:33 git Note Added: 0093188
2020-07-20 12:06 git Note Added: 0093194
2020-07-20 12:08 kgv Summary Draw Harness, ViewerTest - vlocation -rotate is applied in opposite order => Draw Harness, ViewerTest - command vlocation applies transformation in opposite order
2020-07-20 12:08 git Note Added: 0093195
2020-07-20 13:53 kgv Note Added: 0093199
2020-07-20 13:53 kgv Assigned To kgv => osa
2020-07-20 13:53 kgv Status new => resolved
2020-07-20 13:56 kgv Relationship added child of 0027764
2020-07-20 13:56 kgv Product Version 7.4.0 => 7.1.0
2020-07-21 09:24 osa Note Added: 0093217
2020-07-21 09:24 osa Assigned To osa => bugmaster
2020-07-21 09:24 osa Status resolved => reviewed
2020-07-23 11:54 kgv Note Added: 0093259
2020-07-25 13:23 bugmaster Note Added: 0093322
2020-07-25 13:23 bugmaster Status reviewed => tested
2020-07-25 13:36 bugmaster Test case number => pointcloud/transformation/bug30162
2020-07-25 13:57 bugmaster Changeset attached => occt master dbc8becf
2020-07-25 13:57 bugmaster Status tested => verified
2020-07-25 13:57 bugmaster Resolution open => fixed
2020-07-25 14:02 git Note Added: 0093341
2020-12-02 16:43 emo Fixed in Version => 7.5.0
2020-12-02 17:13 emo Status verified => closed