MantisBT - Open CASCADE
View Issue Details
0027130Open CASCADE[OCCT] OCCT:Visualizationpublic2016-02-05 10:432020-11-21 13:27
kgv 
bugmaster 
normalminor 
verifiedfixed 
[OCCT] 7.0.0 
[OCCT] 7.6.0* 
v3d/raytrace/bug27130
0027130: Visualization, Ray tracing - skip structures with transformation persistence flag
Transformation persistence is not supported by Ray Tracing core. Thus, such structures should not be identified as ray-traceable and should be rendered using rasterization approach.
test bugs vis bug26719_1 1
vraytrace 1

No tags attached.
png zoompers_raytrace_KO.png (3,405) 2016-02-05 10:43
https://tracker.dev.opencascade.org/
png zoompers_raster_OK.png (19,942) 2016-02-05 10:43
https://tracker.dev.opencascade.org/
Issue History
2016-02-05 10:43kgvNew Issue
2016-02-05 10:43kgvAssigned To => kgv
2016-02-05 10:43kgvFile Added: zoompers_raytrace_KO.png
2016-02-05 10:43kgvFile Added: zoompers_raster_OK.png
2016-10-25 09:41kgvTarget Version7.1.0 => 7.2.0
2017-07-20 10:52kgvTarget Version7.2.0 => 7.4.0
2019-09-04 12:48abvTarget Version7.4.0 => 7.5.0
2020-07-02 10:09kgvAssigned Tokgv => mzernova
2020-07-02 10:09kgvStatusnew => assigned
2020-07-09 11:33gitNote Added: 0093055
2020-07-09 14:17mzernovaNote Added: 0093061
2020-07-09 18:27kgvNote Added: 0093071
2020-09-21 17:42kgvTarget Version7.5.0 => 7.6.0*
2020-11-17 18:02gitNote Added: 0096838
2020-11-17 18:03gitNote Added: 0096839
2020-11-17 18:06mzernovaNote Added: 0096840
2020-11-17 23:04gitNote Added: 0096854
2020-11-17 23:05gitNote Added: 0096855
2020-11-18 08:35mzernovaAssigned Tomzernova => kgv
2020-11-18 08:35mzernovaStatusassigned => resolved
2020-11-18 08:43gitNote Added: 0096859
2020-11-18 08:44gitNote Added: 0096860
2020-11-18 09:58kgvNote Added: 0096861
2020-11-18 09:59kgvAssigned Tokgv => mzernova
2020-11-18 09:59kgvStatusresolved => assigned
2020-11-18 11:57gitNote Added: 0096875
2020-11-18 11:57gitNote Added: 0096876
2020-11-18 15:40mzernovaAssigned Tomzernova => kgv
2020-11-18 15:40mzernovaStatusassigned => resolved
2020-11-18 15:59kgvAssigned Tokgv => mzernova
2020-11-18 15:59kgvStatusresolved => assigned
2020-11-18 17:11gitNote Added: 0096886
2020-11-18 17:11gitNote Added: 0096887
2020-11-18 17:12mzernovaAssigned Tomzernova => kgv
2020-11-18 17:12mzernovaStatusassigned => resolved
2020-11-19 09:59kgvAssigned Tokgv => mzernova
2020-11-19 09:59kgvStatusresolved => assigned
2020-11-19 11:16gitNote Added: 0096894
2020-11-19 11:17gitNote Added: 0096895
2020-11-19 11:18mzernovaAssigned Tomzernova => kgv
2020-11-19 11:18mzernovaStatusassigned => resolved
2020-11-19 11:31gitNote Added: 0096896
2020-11-19 11:31kgvNote Added: 0096897
2020-11-19 11:31kgvAssigned Tokgv => bugmaster
2020-11-19 11:31kgvStatusresolved => reviewed
2020-11-21 12:39bugmasterChangeset attached => occt master 4552cb85
2020-11-21 12:39bugmasterStatusreviewed => verified
2020-11-21 12:39bugmasterResolutionopen => fixed
2020-11-21 12:42bugmasterNote Added: 0096927
2020-11-21 12:44bugmasterTest case number => v3d/raytrace/bug27130
2020-11-21 13:27gitNote Added: 0096945
2020-11-21 13:27gitNote Added: 0096946

Notes
(0093055)
git   
2020-07-09 11:33   
Branch CR27130 has been created by mzernova.

SHA-1: 0e53cca0a4c70160baefcf63a5539a61c6c3b883


Detailed log of new commits:

Author: mzernova
Date: Thu Jul 9 11:32:40 2020 +0300

    0027130: Visualization, Ray tracing - skip structures with transformation persistence flag
    
    Added myHasPersistence flag into Graphic3d_PrimitiveArray and Graphic3d_Group
    It is allows to determine objects with transform persistence as non ray-traceable
    and render them using the rasterization approach
(0093061)
mzernova   
2020-07-09 14:17   
http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR27130-master-mzernova [^]
(0093071)
kgv   
2020-07-09 18:27   
OpenGl_Structure::SetTransformPersistence() is not handled by the patch.

   OpenGl_PrimitiveArray* anArray = new OpenGl_PrimitiveArray (aDriver, theType, theIndices, theAttribs, 
theBounds);
+  anArray->SetPersistence (HasPersistence());

There is no reason for OpenGl_PrimitiveArray or OpenGl_Group to be aware of transformation persistence assigned to entire structure.

--- a/tests/bugs/vis/bug26719_1
+++ b/tests/bugs/vis/bug26719_1

+vraytrace 1
+vdump ${imagedir}/${casename}_raytrace.png

This test case is dedicated to another issue.
Ray-Tracing test cases should be defined independently in v3d/raytrace test grid.
(0096838)
git   
2020-11-17 18:02   
Branch CR27130 has been updated forcibly by mzernova.

SHA-1: 0f3670e70e025655dedb8100c8c0293ab0ae9ec4
(0096839)
git   
2020-11-17 18:03   
Branch CR27130_1 has been created by mzernova.

SHA-1: 52e072eb4e3d9eced32add817efa424fb8bfbd51


Detailed log of new commits:

Author: mzernova
Date: Thu Jul 9 11:32:40 2020 +0300

    0027130: Visualization, Ray tracing - skip structures with transformation persistence flag
    
    Objects with transform persistence are detected as non ray-tracable and redered using the rasterization approach.
    The renderFiltered() method moved to the OpenGl_Group class.
    
    bugs/vis/bug27130: test case added
(0096840)
mzernova   
2020-11-17 18:06   
http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR27130_1-master-mzernova [^]
(0096854)
git   
2020-11-17 23:04   
Branch CR27130_1 has been updated forcibly by mzernova.

SHA-1: a4036c4443910d1d739ff108731d4dbce2bd5464
(0096855)
git   
2020-11-17 23:05   
Branch CR27130 has been updated forcibly by mzernova.

SHA-1: aadf293420af60cffd4e1d24a09393b5b4edeb68
(0096859)
git   
2020-11-18 08:43   
Branch CR27130 has been updated by mzernova.

SHA-1: 6d2496ffc3d105ef5a29e2ab8c676a5ce4ad1bee


Detailed log of new commits:

Author: mzernova
Date: Wed Nov 18 08:42:41 2020 +0300

    Test case was moved

(0096860)
git   
2020-11-18 08:44   
Branch CR27130_1 has been updated forcibly by mzernova.

SHA-1: 8739ee225c933dc616a29d5747a93af56743f605
(0096861)
kgv   
2020-11-18 09:58   
+Standard_Boolean OpenGl_Group::renderFiltered (const Handle(OpenGl_Workspace)& theWorkspace,
+                                               OpenGl_Element* theElement) const
+{
+  Standard_Boolean isNotRaytraced = (theWorkspace->RenderFilter() & OpenGl_RenderFilter_NonRaytraceableOnly) 
!= 0
+    && OpenGl_Raytrace::IsRaytracedElement (theElement)
+    && HasPersistence();
+
+  if (isNotRaytraced || theWorkspace->ShouldRender (theElement))
+  {
+    theElement->Render (theWorkspace);

Proposed logic spreads apart filtering into two places making it fragile and cumbersome. I propose keeping the logic within OpenGl_Workspace::ShouldRender() method, which could be extended with Groups/Structure parameters to take into account necessary context.
(0096875)
git   
2020-11-18 11:57   
Branch CR27130 has been updated by mzernova.

SHA-1: 550b4498b75f4fa65a4a3121e7cd2879590c3b10


Detailed log of new commits:

Author: mzernova
Date: Wed Nov 18 11:43:22 2020 +0300

    remarks from kgv

(0096876)
git   
2020-11-18 11:57   
Branch CR27130_1 has been updated forcibly by mzernova.

SHA-1: 6b5f74abde61e09df02ec056e10aecaf70a313fd
(0096886)
git   
2020-11-18 17:11   
Branch CR27130 has been updated by mzernova.

SHA-1: 77d30d5740a7903f897a6b43ad39710c85970552


Detailed log of new commits:

Author: mzernova
Date: Wed Nov 18 17:10:28 2020 +0300

    remarks from kgv

(0096887)
git   
2020-11-18 17:11   
Branch CR27130_1 has been updated forcibly by mzernova.

SHA-1: 3b3266bc5ad6c5fbfcfe51af6ea1b711d8d78dd9
(0096894)
git   
2020-11-19 11:16   
Branch CR27130_1 has been updated forcibly by mzernova.

SHA-1: 053fa0ebed2d574987862d313d7e8fd9e621ad56
(0096895)
git   
2020-11-19 11:17   
Branch CR27130 has been updated by mzernova.

SHA-1: 155dc4e4b1f0db2185cb0bf0845c51d00e392a3e


Detailed log of new commits:

Author: mzernova
Date: Thu Nov 19 11:16:26 2020 +0300

    remarks from kgv

(0096896)
git   
2020-11-19 11:31   
Branch CR27130_1 has been updated forcibly by kgv.

SHA-1: cf78965e03a6ca6b22f6ad45234752717d75f26a
(0096897)
kgv   
2020-11-19 11:31   
Please raise the patch
- OCCT branch: CR27130_1.
(0096927)
bugmaster   
2020-11-21 12:42   
Combination -
OCCT branch : IR-2020-11-20
master SHA - c5892d852bb462075f9db03f31085e35d7b59f35
a206de37fbfa0bf71bd534ae47192bbec23b8522
Products branch : IR-2020-11-20 SHA - a5d1f89f5fa83c955e6a604f57a5b590eb433b43
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: 18024.090000000127 / 17964.340000000077 [+0.33%]
Products
Total CPU difference: 12166.12000000011 / 12169.520000000111 [-0.03%]
Windows-64-VC14:
OCCT
Total CPU difference: 19696.90625 / 19723.125 [-0.13%]
Products
Total CPU difference: 13644.875 / 13567.078125 [+0.57%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0096945)
git   
2020-11-21 13:27   
Branch CR27130_1 has been deleted by inv.

SHA-1: cf78965e03a6ca6b22f6ad45234752717d75f26a
(0096946)
git   
2020-11-21 13:27   
Branch CR27130 has been deleted by inv.

SHA-1: 155dc4e4b1f0db2185cb0bf0845c51d00e392a3e