MantisBT
Mantis Bug Tracker Workflow

View Revisions: Issue #31129 All Revisions ] Back to Issue ]
Summary 0031129: Visualization - revise background / environment API
Revision 2021-01-12 13:44 by kgv
Description Existing API for configuring viewer background / environment is unreliable.
There is no public getter returning current state, too many setters, PBR supports only Cubemap and Ray Tracing supports only Equirectangular panorama, different ways for using environment for lighting / background (V3d_View::SetBackgroundCubeMap() for PBR and Graphic3d_RenderingParams::UseEnvironmentMapBackground for RaT Tracing), Graphic3d_TextureEnv/Graphic3d_CubeMap have no relationship although has similar nature, and result depends on the order of called methods.

OpenGl_View::myBackgroundType is inaccessible outside. OpenGl_View::myBackgroundCubeMap can be left defined after OpenGl_View::SetBackgroundImage (Handle(Graphic3d_TextureMap)()) without any option to make it active as background again.

It is proposed to:
- Move background / environment properties to Graphic3d_RenderingParams (preserving a couple of old V3d_View methods for compatibility). No setter is needed to switch state - renderer should be able tracking change.
- Support Cubemap within Ray-Tracing. Preserving support of equirectangular panorama to be considered, if not troublesome.
- Provide dedicated properties for Background Environment and IBL Environment.
  Renderer should be able reusing OpenGL resource created for Background Environment for baking IBL Environment when they are the same using normal resource sharing mechanism. Remove Graphic3d_RenderingParams::UseEnvironmentMapBackground flag.
Revision 2019-11-05 10:50 by kgv
Description Existing API for configuring viewer background / environment is unreliable.
There is no public getter returning current state, too many setters, PBR supports only Cubemap and Ray Tracing supports only Equirectangular panorama, different ways for using environment for lighting / background (V3d_View::SetBackgroundCubeMap() for PBR and Graphic3d_RenderingParams::UseEnvironmentMapBackground for RaT Tracing), Graphic3d_TextureEnv/Graphic3d_CubeMap have no relationship although has similar nature, and result depends on the order of called methods.

It is proposed to:
- Move background / environment properties to Graphic3d_RenderingParams (preserving a couple of old V3d_View methods for compatibility). No setter is needed to switch state - renderer should be able tracking change.
- Support Cubemap within Ray-Tracing. Preserving support of equirectangular panorama to be considered, if not troublesome.
- Provide dedicated properties for Background Environment and IBL Environment.
  Renderer should be able reusing OpenGL resource created for Background Environment for baking IBL Environment when they are the same using normal resource sharing mechanism. Remove Graphic3d_RenderingParams::UseEnvironmentMapBackground flag.
Revision 2019-11-05 10:48 by kgv
Description Existing API for configuring viewer background / environment is unreliable.
There is no public getter returning current state, too many setters, PBR supports only Cubemap and Ray Tracing supports only Equirectangular panorama, different ways for using environment for lighting / background (V3d_View::SetBackgroundCubeMap() for PBR and Graphic3d_RenderingParams::UseEnvironmentMapBackground for RaT Tracing), Graphic3d_TextureEnv/Graphic3d_CubeMap have no relationship although has similar nature, and result depends on the order of called methods.

It is proposed to:
- Move background / environment properties to Graphic3d_RenderingParams (preserving a couple of old V3d_View methods for compatibility). No setter is needed to switch state - renderer should be able tracking change.
- Support Cubemap within Ray-Tracing. Preserving support of equirectangular panorama to be considered, if not troublesome.
- Provide dedicated properties for Background Environment and IBL Environment.
  Renderer should be able reusing OpenGL resource created for Background Environment for baking IBL Environment when they are the same using normal resource sharing mechanism.


Copyright © 2000 - 2021 MantisBT Team
Powered by Mantis Bugtracker