MantisBT - Open CASCADE
View Issue Details
0030952Open CASCADE[OCCT] OCCT:DRAWpublic2019-09-06 12:202020-08-28 16:35
kgv 
kgv 
normalminor 
newopen 
 
[OCCT] 7.6.0* 
0030952: Draw Harness, ViewerTest - add command showing on-screen GUI for configuring material properties
Currently, Draw Harness does not provide tools for configuring material properties apart from assigning color and named material:
> vaspects -setMaterial SILVER -setColor RED

It is desired providing some more flexible tool for playing with materials, with simplistic user interface based on AIS.
pload MODELING VISUALIZATION
psphere s 1
vclear
vinit View1
vdisplay -dispMode 1 s
vfit
vlight -change 0 -intensity 2.5
vlight -change 1 -intensity 0.7
vrenderparams -shadingModel pbr
vmaterialwidget w s
No tags attached.
related to 0031237new mahaidong Community Visualization - implement simple 2d gui on the AIS layer 
png draw_pbr_mat.png (66,148) 2019-11-10 00:59
https://tracker.dev.opencascade.org/
png draw_common_mat.png (92,319) 2019-11-10 01:00
https://tracker.dev.opencascade.org/
Issue History
2019-09-06 12:20kgvNew Issue
2019-09-06 12:20kgvAssigned To => kgv
2019-09-06 12:21gitNote Added: 0086862
2019-09-17 18:06gitNote Added: 0087214
2019-09-17 18:21gitNote Added: 0087216
2019-09-17 19:04gitNote Added: 0087218
2019-09-17 19:26gitNote Added: 0087220
2019-09-17 20:43gitNote Added: 0087222
2019-09-17 20:45gitNote Added: 0087223
2019-09-18 00:23gitNote Added: 0087225
2019-09-18 01:39gitNote Added: 0087226
2019-09-18 01:45gitNote Added: 0087228
2019-09-18 19:58gitNote Added: 0087273
2019-09-18 20:03gitNote Added: 0087275
2019-09-19 10:38gitNote Added: 0087293
2019-09-19 12:00gitNote Added: 0087295
2019-09-19 14:08gitNote Added: 0087302
2019-09-19 14:46gitNote Added: 0087306
2019-09-19 15:19gitNote Added: 0087311
2019-09-19 18:13gitNote Added: 0087321
2019-09-19 20:33gitNote Added: 0087325
2019-09-19 20:39gitNote Added: 0087326
2019-09-19 20:56gitNote Added: 0087327
2019-09-19 21:02gitNote Added: 0087328
2019-09-19 22:06gitNote Added: 0087330
2019-09-19 22:33gitNote Added: 0087331
2019-09-20 09:44gitNote Added: 0087345
2019-09-20 13:06gitNote Added: 0087357
2019-09-20 13:23gitNote Added: 0087360
2019-09-20 15:25gitNote Added: 0087369
2019-09-20 15:50gitNote Added: 0087370
2019-09-20 22:38gitNote Added: 0087377
2019-09-21 11:45gitNote Added: 0087379
2019-09-21 15:08gitNote Added: 0087381
2019-09-21 17:18gitNote Added: 0087382
2019-09-21 18:03gitNote Added: 0087385
2019-09-21 18:43gitNote Added: 0087391
2019-09-21 20:45gitNote Added: 0087394
2019-09-21 21:15gitNote Added: 0087396
2019-09-21 22:13gitNote Added: 0087399
2019-09-21 22:32gitNote Added: 0087403
2019-11-09 23:54gitNote Added: 0088826
2019-11-10 00:59kgvFile Added: draw_pbr_mat.png
2019-11-10 01:00kgvFile Added: draw_common_mat.png
2019-11-10 01:01gitNote Added: 0088827
2019-11-10 01:54kgvRelationship addedrelated to 0031146
2019-11-11 11:23kgvSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=22174#r22174
2019-12-12 10:35kgvRelationship addedrelated to 0031237
2019-12-12 10:54mahaidongNote Added: 0089473
2020-08-28 16:35kgvTarget Version7.5.0 => 7.6.0*

Notes
(0086862)
git   
2019-09-06 12:21   
Branch CR30952 has been created by kgv.

SHA-1: 719236fc5f5318f5971066c5dacd06c791292b39


Detailed log of new commits:

Author: kgv
Date: Fri Sep 6 12:18:09 2019 +0300

    0030952: Draw Harness, ViewerTest - add command showing on-screen GUI for configuring material properties
(0087214)
git   
2019-09-17 18:06   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 372172f7b88a238e07a7833e0ca2b1e3d9892ecb
(0087216)
git   
2019-09-17 18:21   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 54ef95fa80c9f19598ea6396d2daf79dba411332
(0087218)
git   
2019-09-17 19:04   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 8cb88bea3a0a650f331b039a920e09bc3371ba2d
(0087220)
git   
2019-09-17 19:26   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: b206198087a2b2cd7872c4957831590318e06c3d
(0087222)
git   
2019-09-17 20:43   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: ce366f95ff44235619c41add543bcf2221063e5a
(0087223)
git   
2019-09-17 20:45   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 96e8fbd73a06a0d1247fb66fa86dc11cca6d523f
(0087225)
git   
2019-09-18 00:23   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 810701e470d68e99862208e21e9f742837dc48d7
(0087226)
git   
2019-09-18 01:39   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 3c9f64969a89701f4728ec527d0943b9e65cf9e3
(0087228)
git   
2019-09-18 01:45   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: a27c0a2bce60c8db8090452a8138ded67b7e0569
(0087273)
git   
2019-09-18 19:58   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 0e300284929f7e0ebd17609d7f7364abb449f2f7
(0087275)
git   
2019-09-18 20:03   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 0bba5c89e9addc1832bf7df3a7924dc73b30801b
(0087293)
git   
2019-09-19 10:38   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 4cb0279ea7097e54bafd102c8a66a1d6dd0931ca
(0087295)
git   
2019-09-19 12:00   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 51ace0ceb7383761e465531ada8b92a35a36b1b6
(0087302)
git   
2019-09-19 14:08   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: c118fd2671aaebee96d034c9a742c10c4e885764
(0087306)
git   
2019-09-19 14:46   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: f15a4662e29b556a4496b117046a76b5c82e23fa
(0087311)
git   
2019-09-19 15:19   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: c28c8fe63871bc2d68f33f4bb4c2c6915854ca43
(0087321)
git   
2019-09-19 18:13   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 123d6a1af9e468376bca8d01c4762e204d4a00ef
(0087325)
git   
2019-09-19 20:33   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 4dac3d1dc991e39afdc78a741082236772c5aeb6
(0087326)
git   
2019-09-19 20:39   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 29d2e99b672f755bfd363363d912123bcea23cd1
(0087327)
git   
2019-09-19 20:56   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 636ff8ac5bfcbcd18ec0e048b5c7f81124f217df
(0087328)
git   
2019-09-19 21:02   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 1656b11ad498736bf34c515391b5b702491ea720
(0087330)
git   
2019-09-19 22:06   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: fbda5419f313de0a467eecba47239e8134374bfe
(0087331)
git   
2019-09-19 22:33   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 5fca505767de6fb4cdcc6f6b6cce92c4c53ab9ae
(0087345)
git   
2019-09-20 09:44   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 7689db335fffce4426b2ac8bedf98b82bf272eb9
(0087357)
git   
2019-09-20 13:06   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: f09f520909ef78d177604e3309cb4d11c6eff16d
(0087360)
git   
2019-09-20 13:23   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: 341e87e4aed8955afc2c73fbab431ff6a11a787d
(0087369)
git   
2019-09-20 15:25   
Branch CR30952 has been updated by kgv.

SHA-1: a561a3313e288070d189fe40b8073c41d7ceadd0


Detailed log of new commits:

Author: kgv
Date: Fri Sep 20 15:21:44 2019 +0300

    Test cases have been updated to new sRGB rendered results.

(0087370)
git   
2019-09-20 15:50   
Branch CR30952 has been updated forcibly by kgv.

SHA-1: e67b461e6c98d90e71bb7aff605a5308915d44aa
(0087377)
git   
2019-09-20 22:38   
Branch CR30952 has been updated by kgv.

SHA-1: 8541e78cde14b94354be17a94a8a172c4b7f9604


Detailed log of new commits:

Author: kgv
Date: Fri Sep 20 22:34:58 2019 +0300

    #Quantity_Color::Name() - look for nearest sRGB color rather than nearest linear RGB color.

(0087379)
git   
2019-09-21 11:45   
Branch CR30952 has been updated by kgv.

SHA-1: dcf2a3737e153a488117b6dc05491a0f5236d137


Detailed log of new commits:

Author: kgv
Date: Sat Sep 21 11:41:40 2019 +0300

    0030991: Draw Harness - ViewerTest::ParseColors() defines out-of-range alpha component

(0087381)
git   
2019-09-21 15:08   
Branch CR30952 has been updated by kgv.

SHA-1: 850d0c5d9015ad7a5c9e2cc60405e815b392fe50


Detailed log of new commits:

Author: kgv
Date: Sat Sep 21 15:04:59 2019 +0300

    # Use float sRGB values for finding a color name

Author: kgv
Date: Sat Sep 21 15:04:16 2019 +0300

    # update test cases

(0087382)
git   
2019-09-21 17:18   
Branch CR30952_1 has been created by kgv.

SHA-1: eaa7a81aa6343985e6f1278d9971f9432890c53c


Detailed log of new commits:

Author: kgv
Date: Thu Aug 29 11:04:56 2019 +0300

    0029528: Visualization, TKOpenGl - allow defining sRGB textures
    
    Quantity_Color definition has been modified to store RGB components
    in linear color space within Quantity_TOC_RGB type.
    Standard colors defined by Quantity_NameOfColor enumeration has been updated accordingly.
    New Quantity_TOC_sRGB type has been introduced to handle RGB components in non-linear sRGB color space.
    
    OpenGl_TextureFormat class definition has been moved to dedicated files.
    New method OpenGl_TextureFormat::FindFormat() replaces OpenGl_Texture::GetDataFormat().
    New method OpenGl_TextureFormat::FindSizedFormat() replaces OpenGl_FrameBuffer::getColorDataFormat()
    and OpenGl_FrameBuffer::getDepthDataFormat().
    
    Graphic3d_TextureRoot::IsColorMap() - introduced new property defining
    if RGB(A)8 image formats should be loaded as sRGB(A) textures or as data RGB(A) textures.
    OpenGl_Texture initialization methods have been extended with new theIsColorMap argument.
    
    vreadpixel - added argument -sRGB printing color in sRGB color space.
    
    Test cases have been updated to new sRGB rendered results.

Author: kgv
Date: Mon Sep 16 23:06:38 2019 +0300

    0030969: Coding Rules - refactor Quantity_Color.cxx color table definition
    
    The table of named colors has been compressed and moved out
    from Quantity_Color.cxx into Quantity_ColorTable.pxx.
    
    Quantity_NameOfColor - grayscale enumeration values have been re-ordered to fix discontinuity.
    Duplicating colors has been merged within enumeration:
      CHARTREUSE=CHARTREUSE1, GOLD=GOLD1, GREEN=GREEN1, ORANGE=ORANGE1,
      ORANGERED=ORANGERED1, RED=RED1, TOMATO=TOMATO1, YELLOW=YELLOW1.
    Added aliases to several other common colors:
      BLUE=BLUE1, CYAN=CYAN1, LIGHTCYAN=LIGHTCYAN1, MAGENTA=MAGENTA1.
    
    Quantity_Color::ColorToHex() now rounds-up float values to closest integer.
    Quantity_ColorRGBA::ColorToHex() - added method formatting color into hex with alpha component.
    
    Quantity_Color class definition has been cleaned to follow OCCT coding style.
    Quantity_Color now stores NCollection_Vec3<float> as class field instead of separate components.
    Removed unused class Quantity_ColorDefinitionError.
    
    New methods Quantity_Color::Convert_LinearRGB_To_sRGB() and Quantity_Color::Convert_sRGB_To_LinearRGB()
    converting RGB components from linear to non-linear sRGB colorspace and vice versa.
    Image_PixMap::PixelColor() and Image_PixMap::SetPixelColor() methods have been extended
    with an optional argument for performing linearization/delinearization of 8-bit sRGB pixel formats.
    
    Draw Harness command AISColor has been corrected to take color name instead of enumeration index.

Author: kgv
Date: Wed Jul 3 11:28:26 2019 +0300

    0029902: Data Exchange, XCAF - provide extended Material definition for visualization purposes
    
    Introduced new attribute XCAFDoc_VisMaterial storing visualization material definition.

Author: kgv
Date: Fri Sep 6 12:18:09 2019 +0300

    0030952: Draw Harness, ViewerTest - add command showing on-screen GUI for configuring material properties

Author: kgv
Date: Sat Sep 21 17:10:23 2019 +0300

    0030991: Draw Harness - ViewerTest::ParseColor() defines out-of-range alpha component
    
    ViewerTest::ParseColor() - fixed alpha component defined as 255 for RGB-only input.
    
    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()).
(0087385)
git   
2019-09-21 18:03   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: e3fc240efa08a22b0407c5d1a0079140c4edd840
(0087391)
git   
2019-09-21 18:43   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: be29eb50fd294507ba96674d4d756cfdb708db51
(0087394)
git   
2019-09-21 20:45   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: c355ab99defeb3897146ca4af97ee5c395ef90bd
(0087396)
git   
2019-09-21 21:15   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: b7d88f44e04501d8b60e37c73cb0b57ecf101d6e
(0087399)
git   
2019-09-21 22:13   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: 241fd89600055b1a07ac67c69f8e5a4f91d2e398
(0087403)
git   
2019-09-21 22:32   
Branch CR30952_1 has been updated forcibly by kgv.

SHA-1: 91cdeb7a2936da66ffcc396a8d05a09456d840b7
(0088826)
git   
2019-11-09 23:54   
Branch CR30952_2 has been created by kgv.

SHA-1: 57391cee29d34efa99586afc4f528b6e7e1da77c


Detailed log of new commits:

Author: kgv
Date: Fri Sep 6 12:18:09 2019 +0300

    0030952: Draw Harness, ViewerTest - add command showing on-screen GUI for configuring material properties
(0088827)
git   
2019-11-10 01:01   
Branch CR30952_2 has been updated forcibly by kgv.

SHA-1: 32ade905c6a011bbd7901c4a2e975fbee8c5bf4d
(0089473)
mahaidong   
2019-12-12 10:54   
cool! can I do something with this?