View Issue Details

IDProjectCategoryView StatusLast Update
0032039Open CASCADEOCCT:Visualizationpublic2021-12-30 20:16
Reporterkgv Assigned Tobugmaster  
PrioritynormalSeverityfeature 
Status closedResolutionfixed 
Target Version7.6.0Fixed in Version7.6.0 
Summary0032039: Visualization, TKOpenGl - implement simple shadow mapping for a direct light source
DescriptionIt is proposed extending real-time renderer with basic shadow mapping capabilities - as a first step implementation could be limited to a single directional light source.
TagsNo tags attached.
Test case numberv3d/shadows/buggy,dir1,dir2,dirhead

Attached Files

  • buggy_raytrace.png (35,965 bytes)
  • buggy_phong.png (34,057 bytes)
  • buggy_pbr.png (34,372 bytes)

Relationships

parent of 0032067 closedbugmaster Open CASCADE Visualization, TKOpenGl - shadowmap GLSL compilation error on WebGL 2.0 
parent of 0032129 closedkgv Open CASCADE Visualization, TKOpenGl - shadowmap is broken for ZLayer having non-zero origin 
parent of 0032758 verifiedkgv Open CASCADE Visualization, TKOpenGl - disable shadow-map from transform-persistence objects 
related to 0031196 closedbugmaster Community Visualization, TKOpenGl - enable Ray-Tracing using OpenGL ES 3.2 
child of 0031646 newiko Open CASCADE Visualization - shadow mapping within real-time renderer 

Activities

git

2021-01-09 23:38

administrator   ~0098023

Branch CR32039 has been created by kgv.

SHA-1: dcd21d48b4495214aff20161514a062f72eb1d95


Detailed log of new commits:

Author: kgv
Date: Mon Jan 4 12:17:44 2021 +0300

    0032039: Visualization, TKOpenGl - implement simple shadow mapping for a direct light source
    
    Graphic3d_CLight::ToCastShadows() - added new property defining if light should cast shadows (ignored by Ray-Tracing).
    
    OpenGl_ShaderManager::stdComputeLighting() now implements shadow mapping for directional lights.
    OpenGl_ShaderManager::prepareGeomMainSrc() now handles copying of arrays.
    OpenGl_Context::ShadowMapTexUnit() - added property defining an offset for shadow map texture units.
    OpenGl_ShadowMap - added new class storing shadow map FBO with parameters.
    OpenGl_View::prepareFrameBuffers() - added resizing of shadow map FBOs.
    OpenGl_View::Redraw() - added section redrawing scene into shadow map FBOs via OpenGl_View::renderShadowMap() method.
    
    vrenderparams - added new parameters -shadowMapResolution and -shadowMapBias.

git

2021-01-10 02:32

administrator   ~0098033

Branch CR32039 has been updated forcibly by kgv.

SHA-1: a2415614578d62eafa019fc12c2117bcc301dff2

kgv

2021-01-10 04:27

developer   ~0098037

Patch is ready for review
- OCCT branch: CR32039.

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

kgv

2021-01-10 04:31

developer  

buggy_raytrace.png (35,965 bytes)

kgv

2021-01-10 04:32

developer  

buggy_phong.png (34,057 bytes)

kgv

2021-01-10 04:32

developer  

buggy_pbr.png (34,372 bytes)

osa

2021-01-12 14:37

developer   ~0098089

The patch was reviewed

kgv

2021-01-12 14:43

developer   ~0098090

Please use branch CR32039_1 for integration.

bugmaster

2021-01-16 13:30

administrator   ~0098148

Combination -
OCCT branch : IR-2021-01-15
master SHA - 6fab0b34288ef3f29ecf4eabc0283540460dbc31
a206de37fbfa0bf71bd534ae47192bbec23b8522
Products branch : IR-2021-01-15 SHA - a8521c25e41405ac279e65e1fcde5de75a344b0b
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: 17754.160000000134 / 17720.07000000011 [+0.19%]
Products
Total CPU difference: 12412.630000000105 / 12419.360000000095 [-0.05%]
Windows-64-VC14:
OCCT
Total CPU difference: 19336.3125 / 19330.015625 [+0.03%]
Products
Total CPU difference: 13740.03125 / 13831.828125 [-0.66%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

Related Changesets

occt: master d84e8669

2021-01-04 09:17:44

kgv


Committer: bugmaster Details Diff
0032039: Visualization, TKOpenGl - implement simple shadow mapping for a direct light source

Graphic3d_CLight::ToCastShadows() - added new property defining if light should cast shadows (ignored by Ray-Tracing).

OpenGl_ShaderManager::stdComputeLighting() now implements shadow mapping for directional lights.
OpenGl_ShaderManager::prepareGeomMainSrc() now handles copying of arrays.
OpenGl_Context::ShadowMapTexUnit() - added property defining an offset for shadow map texture units.
OpenGl_ShadowMap - added new class storing shadow map FBO with parameters.
OpenGl_View::prepareFrameBuffers() - added resizing of shadow map FBOs.
OpenGl_View::Redraw() - added section redrawing scene into shadow map FBOs via OpenGl_View::renderShadowMap() method.

vrenderparams - added new parameters -shadowMapResolution and -shadowMapBias.
Affected Issues
0032039
mod - src/Graphic3d/Graphic3d_CLight.cxx Diff File
mod - src/Graphic3d/Graphic3d_CLight.hxx Diff File
mod - src/Graphic3d/Graphic3d_LightSet.cxx Diff File
mod - src/Graphic3d/Graphic3d_LightSet.hxx Diff File
mod - src/Graphic3d/Graphic3d_RenderingParams.hxx Diff File
mod - src/Graphic3d/Graphic3d_ShaderProgram.cxx Diff File
mod - src/Graphic3d/Graphic3d_ShaderProgram.hxx Diff File
mod - src/Graphic3d/Graphic3d_TextureUnit.hxx Diff File
mod - src/OpenGl/FILES Diff File
mod - src/OpenGl/OpenGl_Context.cxx Diff File
mod - src/OpenGl/OpenGl_Context.hxx Diff File
mod - src/OpenGl/OpenGl_FrameBuffer.hxx Diff File
mod - src/OpenGl/OpenGl_FrameStats.cxx Diff File
mod - src/OpenGl/OpenGl_LayerList.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderManager.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderManager.hxx Diff File
mod - src/OpenGl/OpenGl_ShaderProgram.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderProgram.hxx Diff File
mod - src/OpenGl/OpenGl_ShaderStates.hxx Diff File
add - src/OpenGl/OpenGl_ShadowMap.cxx Diff File
add - src/OpenGl/OpenGl_ShadowMap.hxx Diff File
mod - src/OpenGl/OpenGl_Structure.cxx Diff File
mod - src/OpenGl/OpenGl_View.cxx Diff File
mod - src/OpenGl/OpenGl_View.hxx Diff File
add - src/Shaders/DirectionalLightShadow.glsl Diff File
mod - src/Shaders/FILES Diff File
add - src/Shaders/Shaders_DirectionalLightShadow_glsl.pxx Diff File
mod - src/ViewerTest/ViewerTest_ViewerCommands.cxx Diff File
mod - tests/v3d/grids.list Diff File
add - tests/v3d/shadows/buggy Diff File
add - tests/v3d/shadows/dir1 Diff File
add - tests/v3d/shadows/dir2 Diff File
add - tests/v3d/shadows/dirhead Diff File

Issue History

Date Modified Username Field Change
2021-01-04 12:00 kgv New Issue
2021-01-04 12:00 kgv Assigned To => kgv
2021-01-04 12:01 kgv Relationship added child of 0031646
2021-01-09 23:38 git Note Added: 0098023
2021-01-10 02:32 git Note Added: 0098033
2021-01-10 04:27 kgv Note Added: 0098037
2021-01-10 04:27 kgv Assigned To kgv => osa
2021-01-10 04:27 kgv Status new => resolved
2021-01-10 04:31 kgv File Added: buggy_raytrace.png
2021-01-10 04:32 kgv File Added: buggy_phong.png
2021-01-10 04:32 kgv File Added: buggy_pbr.png
2021-01-12 14:37 osa Note Added: 0098089
2021-01-12 14:37 osa Assigned To osa => bugmaster
2021-01-12 14:37 osa Status resolved => reviewed
2021-01-12 14:43 kgv Note Added: 0098090
2021-01-16 13:30 bugmaster Note Added: 0098148
2021-01-16 13:30 bugmaster Status reviewed => tested
2021-01-16 13:52 bugmaster Test case number => v3d/shadows/buggy,dir1,dir2,dirhead
2021-01-16 14:12 bugmaster Changeset attached => occt master d84e8669
2021-01-16 14:12 bugmaster Status tested => verified
2021-01-16 14:12 bugmaster Resolution open => fixed
2021-01-19 22:38 kgv Relationship added parent of 0032067
2021-02-13 13:29 kgv Relationship added parent of 0032129
2021-02-20 15:58 kgv Relationship added related to 0031196
2021-12-30 20:16 kgv Relationship added parent of 0032758