1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-03 17:56:21 +03:00

7 Commits

Author SHA1 Message Date
kgv
06d40093b7 0032121: Draw Harness, ViewerTest - implement -reset option for vlight command
vlight command has been revised to provide more friendly syntax.
Command now accepts light index or name as first argument.
Added arguments -enable/-disable for managing enabled state.
Added argument -reset to reset light parameters to default values.

V3d_Viewer::SetDefaultLights() now sets names "headlight" and "ambient" to created lights.
Graphic3d_TypeOfLightSource enumeration values have been renamed to avoid shortcuts.
Draw::Atof(), applied corrections to avoid explicit new/delete calls.
2021-07-12 20:50:25 +03:00
kgv
ba562b2b7a 0031999: Tests - request Core Profile on macOS for Ray-Tracing tests 2020-12-23 19:45:32 +03:00
kgv
dbc8becff4 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.
2020-07-23 16:08:17 +03:00
mzernova
89d855ba58 0031225: Visualization, TKOpenGl - support cubemap for environment texture within Ray-Tracing
Ray-Tracing now handles IBL and background cubemaps in similar way as PBR.
Ambient light source is handled by Ray-Tracing in similar way as PBR,
e.g. as coefficient for environment map (IBL) or as constant light source.

Test script generating PBR spheres has been moved to Samples
and now shared by PBR and Path-Tracing tests.
2019-12-27 16:26:48 +03:00
kgv
9196ea9d5a 0030991: Draw Harness - ViewerTest::ParseColor() defines out-of-range alpha component
ViewerTest::ParseColor() - fixed alpha component defined as 255 for RGB-only input.
Quantity_Color::ColorToHex() now rounds-up float values to closest integer.
Quantity_ColorRGBA::ColorToHex() - added method formatting color into hex with alpha component consistent to Quantity_Color::ColorToHex() for RGB.

vdrawtext command now uses ViewerTest::ParseColor() for parsing color argument, so that it accepts hex.
vreadpixel command now has been extended with -hex argument for printing color in hex format.

Commands XSetColor, XGetColor, XGetShapeColor, XGetAllColors, XAddColor, XRemoveColor, XFindColor,
XUnsetColor, XGetInstanceColor, XSetInstanceColor have been corrected to properly report syntax input errors
and to accept color names and hex (by reusing ViewerTest::ParseColor()).
2019-09-24 13:52:45 +03:00
dbp
05aa616d6d 0028218: Visualization, Path Tracing - Redesign path tracing materials to support two-layered model
Existing OCCT path tracing engine used very simple additive material (BSDF) model, so it was possible to reproduce
behavior only of very basic materials such as metal, glass, or plastic. However, some important in CAD industry
materials like car paint or ceramic could not be modeled well. In this patch, OCCT BSDF was significantly improved
by replacing additive model with two-layered scattering model. Therefore, we have base diffuse, glossy, or transmissive
layer, covered by one glossy/specular coat. The layers themselves have no thickness; they can simply reflect light or
transmits it to the layer under it. Balancing different combinations of layer properties can produce a wide range of
different effects. At the same time, disabling the first (coat) layer allows to keep full compatibility with previously
supported scattering model. All new parameters are available via 'vbsdf' command.

Location of new sample for few material examples:
samples\tcl\pathtrace_materials.tcl

Fix shader compilation issue.

Fix test case sample_ball_alpha.

Shaders_PathtraceBase_fs.pxx - regenerate resource from origin
2017-03-03 16:11:21 +03:00
dbp
6e728f3b5c 0027974: Visualization, ray tracing - Improve ray tracing engine
* Multiple importance sampling for path tracing
* Improved light sources sampling (better handling several light sources)
* Fixed issues in light source intersection (light distance is taken into account)
* Add new TCL sample - OCCT Ball model for demonstrating physically-based materials
* Fix potential issue on NVIDIA GPUs ("Error: Failed to upload light source buffer")
* Path tracing materials reviewed; directional light source was smoother by default
2016-11-08 16:43:23 +03:00