View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0024224 | Open CASCADE | OCCT:Visualization | public | 2013-10-04 19:04 | 2013-12-19 13:58 |
Reporter | Assigned To | bugmaster | |||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Platform | A | OS | L | ||
Product Version | 6.7.0 | ||||
Target Version | 6.7.0 | Fixed in Version | 6.7.0 | ||
Summary | 0024224: Suspicious logics in changing clipping planes at OpenGl_Structure | ||||
Description | The following piece of code seems to produce bugs for crossing lists of clippings between view and structure: void OpenGl_Structure::Render(..) { .. // Collect planes which should be turned on for structure Graphic3d_SetOfHClipPlane aPlanesOn; Graphic3d_SetOfHClipPlane::Iterator aPlaneIt (myClipPlanes); for (; aPlaneIt.More(); aPlaneIt.Next()) { const Handle(Graphic3d_ClipPlane)& aUserPln = aPlaneIt.Value(); if (aUserPln->IsOn()) aPlanesOn.Add (aUserPln); } // Set structure clipping planes if (aPlanesOn.Size() > 0) { aContext->ChangeClipping().Set (aPlanesOn, AWorkspace->ViewMatrix()); } ... unset would remove the planes in case of crossing lists // unset structure clipping planes if (aPlanesOn.Size() > 0) { aContext->ChangeClipping().Unset (aPlanesOn); } ... } Provide stencil buffer for 3D viewer image dump functionality. | ||||
Steps To Reproduce | pload AISV MODELING vinit box b1 0 0 0 10 10 10 box b2 30 0 0 10 40 10 box b3 -30 0 0 20 20 20 vsetdispmode 1 vdisplay b1 b2 b3 ## test view-level clipping vclipplane create pln1 vclipplane change pln1 equation 0 1 0 -5 vclipplane change pln1 capping on vclipplane change pln1 capping color 0.9 0.9 0.9 vclipplane set pln1 view Driver1/Viewer1/View1 ## test sharing of planes between view and object vclipplane set pln1 object b1 ## test object-level clipping vclipplane create pln2 vclipplane change pln2 equation -0.707 0.707 0 -25 vclipplane change pln2 capping on vclipplane change pln2 capping color 0.5 0.5 0.9 vclipplane change pln2 capping hatch on vclipplane set pln2 object b3 vfit | ||||
Additional information and documentation updates | This patch contains solution for several issues: 1) The reported problem dedicated to suspicious operations which activating/deactivating list of clip planes during rendering. Due to logical mistake a set of clip planes, shared between view and more than one structure, was not applied completely for second and the latter structures (numeration here corresponds to position of structures in rendering pipeline) - the clip planes of view were not accounted for these structures. 2) The patch contains solution for issues 0024189, 0024229. All these issues are interrelated and have cross-dependencies. 3) Missed test case for checking OpenGl-rendered cappings (issue #0024070) is added by this patch. Changes: - No changes to public API. - Internal changes: a) Added support for stencil buffer OpenGl_FrameBuffer.hxx OpenGl_FrameBuffer.cxx OpenGl_FrameBuffer::Init (...) b) Improved interface of clip plane state management to avoid performance regressions; fixed code remarks. c) Problem with clip planes sharing between view and structures has been fixed OpenGl_ClipPlaneState.cxx OpenGl_ClipPlaneState.hxx OpenGl_Structure.cxx OpenGl_Structure::Render (...) | ||||
Tags | No tags attached. | ||||
Test case number | bugs vis bug24224 | ||||
related to | 0024189 | closed | Open CASCADE | Rendering performance regression after implementation of per-object clipping | |
related to | 0024229 | closed | Open CASCADE | Test case for 0024070 bug has not been integrated | |
related to | 0024253 | closed | bugmaster | Open CASCADE | FBO: Improper deletion of combined Stencil+Depth RenderBuffer |
|
Dear apl, Could you please check this issue? |
2013-10-08 14:32 developer |
24224.png (62,784 bytes) |
|
Dear kgv, Branch CR24224 is ready for review. Could you please have a look at it? |
|
This fix introduces solution for issue 24189. The results prior to patch with capping & clipping (0024070): Highest CPU performance: FPS: 57.575139198577126 CPU: 16.380105 msec Lowest CPU performance: FPS: 57.685042823789502 CPU: 16.692107000000007 msec The results after patch: Highest CPU performance: FPS: 58.110396973959986 CPU: 16.380105 msec Lowest CPU performance: FPS: 57.958128763574308 CPU: 16.848108000000011 msec Performance compared on card: NVIDIA Quadro K4000, CPU: Core i5-3450 |
|
Patch has been reviewed without remarks and ready for testing. |
|
Dear BugMaster, Branch CR24224 (and products from GIT master) was compiled on Linux and Windows platforms and tested. SHA-1: a481bc96baeed9a47018a608753dd26970f7d345 Number of compiler warnings: occt component : Linux: 424 (424 on master) Windows: 9 (9 on master) products component : Linux: 189 (189 on master) Windows: 287 (287 on master) Regressions/Differences: No regressions/differences Testing cases: bugs vis bug24224 - OK Testing on Linux: Total MEMORY difference: 367428100 / 367264668 Total CPU difference: 43704.150000001275 / 44590.37000000126 Testing on Windows: Total MEMORY difference: 431925044 / 433307988 Total CPU difference: 51473.28125 / 41888.375 There are not differences in images found by testdiff. |
|
+ if (!theGlContext.IsNull() && theGlContext->extFBO != NULL) + { + theGlContext->extFBO->glDeleteRenderbuffersEXT (1, &myGlStencilRBId); + myGlStencilRBId = NO_RENDERBUFFER; + } Deletion of combined Stencil+Depth RenderBuffer will be performed twice which might lead to issues within some OpenGL implementations. |
occt: master b859a34d 2013-10-10 13:14:52
Committer: bugmaster Details Diff |
0024224: Suspicious logics in changing clipping planes at OpenGl_Structure 1) Resolved buggy situation of shared clip planes between view and structure; 2) Added clipping plane equation space identification - to be used with shaders; 3) Code refactoring to resolve performance issue reported by 0024189; 4) Attachment of stencil buffer to FBO. Added test case bugs/vis/bug24224 |
Affected Issues 0024224 |
|
mod - src/Graphic3d/FILES | Diff File | ||
mod - src/Graphic3d/Graphic3d_ClipPlane.hxx | Diff File | ||
add - src/Graphic3d/Graphic3d_SetOfHClipPlane_Handle.hxx | Diff File | ||
mod - src/OpenGl/OpenGl_CappingAlgo.cxx | Diff File | ||
mod - src/OpenGl/OpenGl_ClippingState.cxx | Diff File | ||
mod - src/OpenGl/OpenGl_ClippingState.hxx | Diff File | ||
mod - src/OpenGl/OpenGl_Context.cxx | Diff File | ||
mod - src/OpenGl/OpenGl_Context.hxx | Diff File | ||
mod - src/OpenGl/OpenGl_FrameBuffer.cxx | Diff File | ||
mod - src/OpenGl/OpenGl_FrameBuffer.hxx | Diff File | ||
mod - src/OpenGl/OpenGl_Structure.cxx | Diff File | ||
mod - src/OpenGl/OpenGl_Structure.hxx | Diff File | ||
mod - src/OpenGl/OpenGl_View_2.cxx | Diff File | ||
add - tests/bugs/vis/bug24224 | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-10-04 19:04 |
|
New Issue | |
2013-10-04 19:04 |
|
Assigned To | => apl |
2013-10-04 19:04 |
|
Note Added: 0025911 | |
2013-10-04 19:04 |
|
Status | new => assigned |
2013-10-07 09:00 |
|
Relationship added | related to 0024189 |
2013-10-08 12:26 |
|
Steps to Reproduce Updated | |
2013-10-08 14:01 |
|
Relationship added | related to 0024229 |
2013-10-08 14:03 |
|
Steps to Reproduce Updated | |
2013-10-08 14:32 |
|
File Added: 24224.png | |
2013-10-08 14:42 |
|
Note Added: 0025957 | |
2013-10-08 14:42 |
|
Assigned To | apl => kgv |
2013-10-08 14:42 |
|
Status | assigned => resolved |
2013-10-08 16:22 |
|
Note Added: 0025969 | |
2013-10-08 17:16 | kgv | Note Added: 0025974 | |
2013-10-08 17:16 | kgv | Assigned To | kgv => bugmaster |
2013-10-08 17:16 | kgv | Status | resolved => reviewed |
2013-10-09 07:35 |
|
Assigned To | bugmaster => mkv |
2013-10-09 08:24 | kgv | Additional Information Updated | |
2013-10-10 10:31 | apn | Note Added: 0026010 | |
2013-10-10 10:31 | apn | Test case number | => bugs vis bug24224 |
2013-10-10 10:31 | apn | Assigned To | mkv => bugmaster |
2013-10-10 10:31 | apn | Status | reviewed => tested |
2013-10-11 10:39 | kgv | Note Added: 0026040 | |
2013-10-11 11:06 |
|
Relationship added | related to 0024253 |
2013-10-11 13:35 | bugmaster | Changeset attached | => occt master b859a34d |
2013-10-11 13:35 | bugmaster | Status | tested => verified |
2013-10-11 13:35 | bugmaster | Resolution | open => fixed |
2013-10-17 11:18 |
|
Description Updated | |
2013-10-17 11:18 |
|
Additional Information Updated | |
2013-10-17 11:23 |
|
Additional Information Updated | |
2013-10-17 11:23 |
|
Additional Information Updated | |
2013-10-17 11:27 |
|
Additional Information Updated | |
2013-10-19 21:46 |
|
Additional Information Updated | |
2013-10-19 21:46 |
|
Additional Information Updated | |
2013-12-19 13:51 | bugmaster | Status | verified => closed |
2013-12-19 13:58 | bugmaster | Fixed in Version | => 6.7.0 |