View Issue Details

IDProjectCategoryView StatusLast Update
0029076Open CASCADEOCCT:Visualizationpublic2021-02-10 11:13
Reporterkgv Assigned Toapn  
PrioritynormalSeverityfeature 
Status closedResolutionfixed 
Target Version7.4.0Fixed in Version7.4.0 
Summary0029076: Visualization - implement element shrinking Shader
DescriptionIt is desired having a GLSL program implementing Element shrinking presentation, which would not require duplicating vertex data (and providing better flexibility - like dynamic shrink scaling and shrinking by size fixed in pixels).

This would require Geometry Shader support.

Implementing triangle shrinking is relatively straightforward task. At the same time, shrinking quads is not, because quads can not be given to Geometry Shader as input.

First possible approach would be passing GL_LINE_STRIP_ADJACENCY (which defines 4 vertices for Geometry Shader input) so that input data in Primitive Array will represent array of quads and Geometry Shader will be able shrinking it as whole. This means that prepared Primitive Array can be rendered as not shrunk quads only using additional dedicated Geometry Shader, affecting performance (but reducing index data).

Second possible approach would be defining a special Geometry Shader which would align shrunk triangle onto quad diagonal defined as first vertices of triangle. This means that Quads should be split into triangles in a special way (Quad: 1234 -> Tri1: 321; Tri2: 134), however Primitive Array can be rendered as usual triangles if needed.

In both cases shrinked rendering of mixed triangulation/quads data would require splitting data in two Primitive Arrays, while currently mixed data is rendered within single triangulation Primitive Array.
Steps To Reproducetestgrid bugs vis bug29076

pload VISUALIZATION
vclear
vinit
vaxo
vdrawparray p triangles v 0 0 0 v 0 1 0 v 1 1 0 v 1 0 0 v 2 1 0 v 2 0 0 e 3 e 1 e 2 e 1 e 3 e 4 e 5 e 4 e 3 e 4 e 5 e 6
vsetinteriorstyle p 1 -quads 1 -edgeColor RED -edgeWidth 4
vfit
Additional information
and documentation updates
Displaying mesh edges is a common approach in mesh structure analysis and in visualization debugging task.

There are 3 possible implementations:
1) glPolygonMode(), unavailable on OpenGL ES.
2) filling dedicated GL_LINES array.
3) GLSL program.

Historically OCCT provides Aspect_IS_HOLLOW interior style for this purpose, which was implemented as glPolygonMode(GL_FRONT_AND_BACK, GL_LINE).
Each solution has its cons and pros:

1) glPolygonMode.
CONS:
- Unavailable on OpenGL ES.
- Fixed line width (1 pixel) on OpenGL, Core Profile.
- Rendering interior + mesh edges requires 2 passes.
- Hardware might render edges shared between triangle twice, reducing performance.
- Wide lines are rendered with visual artifacts.
- Triangles only.
PROS:
- Easy to switch on.
- Line width in pixels.

2) Dedicated GL_LINES array.
CONS:
- Extra memory footprint for additional data.
- Presentation data should be recomputed.
- The same limitations with line width as glPolygonMode
  (1 pixel width with Core Profile, visual artifacts on wide lines).
PROS:
- Better performance than glPolygonMode(),
  because only unique triangle edges are drawn.
- Can be computed for arbitrary polygons (triangles/quads/polygons).

3) GLSL program.
CONS:
- Requires Geometry Shader stage,
  which is available only since OpenGL ES 3.2+ and OpenGL 3.2+,
  and executed considerably slow on hardware
  (even dummy pass-through Geometry Shader drops performance).
- Variable line width,
  becoming twice thicker on edges shared between triangles.
- Visually hollow presentation without AntiAliasing
  might look not that good as normal GL_LINES.
PROS:
- Arbitrary line width,
  no limitation within Core Profile,
  no artifacts on wide lines.
- Variable line width,
  becoming thinner at large camera distance;
  this avoids mesh becoming a solid mess at distance.
- Rendering interior + mesh edges presentation in single pass.
- Shrinking element presentation (as transparent mesh edges).
- Triangles and quads edges;
  quads should be split into triangles in specific edges order.
- Switching on the fly without recomputing presentation,
  as in case of glPolygonMode().
- Smooth mesh edges on top of interior without AntiAliasing.

This patch implements and enables 3rd approach by default, providing a good compromise between performance, functionality and simplicity to activate.
glPolygonMode() remains available on desktop OpenGL and can be enabled via OpenGl_Caps::usePolygonMode, while 2nd approach should be implemented at application level.
TagsNo tags attached.
Test case numberv3d glsl interior

Attached Files

  • shrink_quad.svg (13,886 bytes)
  • shrink_triangle.png (48,972 bytes)
  • shrink_quad.png (78,570 bytes)
  • geomShader.txt (5,276 bytes)
  • edge_think.png (10,190 bytes)
  • bug29076.png (89,697 bytes)
  • interior1_persp_glsl_msaa.png (96,992 bytes)
  • interior2_persp_glsl_msaa.png (28,600 bytes)

Relationships

related to 0029074 closedbugmaster Open CASCADE Visualization, TKOpenGl - support Geometry Shader definition 
parent of 0032124 closedbugmaster Community Visualization, AIS_Shape - setting color will cause Iso Lines to appear due to misprint in Prs3d_Drawer::SetOwnLineAspects() 
related to 0030119 closedapn Open CASCADE Visualization, OpenGl_ShaderManager - implement mechanism generating in/out section of shader programs 
Not all the children of this issue are yet resolved or closed.

Activities

kgv

2017-09-02 22:55

developer  

shrink_quad.svg (13,886 bytes)

kgv

2017-09-02 22:55

developer  

shrink_triangle.png (48,972 bytes)

kgv

2017-09-02 22:55

developer  

shrink_quad.png (78,570 bytes)

mnv

2018-07-16 17:22

developer   ~0077683

Uploaded geomShader.gs source code for geometry shader. If figure is shrinked in window coordinate the shrink value is correct, but in time of rotation produced wrong result(shrinkTrianglePix() method in shader). If figure is shrinked in model coordinates the shrink value is wrong, but rotation operations is correct(shrinkTriangle() method in shader).

mnv

2018-07-16 17:29

developer  

geomShader.txt (5,276 bytes)

kgv

2018-07-17 12:55

developer  

edge_think.png (10,190 bytes)

git

2018-08-03 10:51

administrator   ~0078340

Branch CR29076 has been created by mnv.

SHA-1: 4e86f3d336dac13820172f9a71ef5ed062ca27ce


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior style:
    - SHRINKED: show shrinked triangulation
    - COMBINED: show solid and wireframe
    HOLLOW, SHRINKED and COMBINED interior styles are drawing by shader program with geometry shader.
    Added new parameter for vaspects command:
    [-setWireframeWidth LineWidth] - this command used for set width of wireframe line for new interior styles.
    And added new alias vsetwfwidth for new parameter.

git

2018-08-03 11:56

administrator   ~0078347

Branch CR29076 has been updated forcibly by mnv.

SHA-1: 0541152a928d70fa8fb5bfd2bd69c0c03bbba90d

git

2018-08-03 13:48

administrator   ~0078352

Branch CR29076 has been updated forcibly by mnv.

SHA-1: d8c873a6d5d3bd32de9411c4e22b9b4d900e5181

git

2018-08-03 14:04

administrator   ~0078354

Branch CR29076 has been updated forcibly by mnv.

SHA-1: bfd000869ad735514c6401fdb34fdf064ba7112c

git

2018-08-03 16:33

administrator   ~0078365

Branch CR29076_1 has been created by mnv.

SHA-1: 3e57eb14d4a6307f600f9552a5a5f7615b784b5b


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Hollow interior style was renamed to Wireframe.
    Added new Interior style:
    - Shrunk: show shrunk triangulation
    - Combined: show solid and wireframe
    Wireframe, Shrunk and Combined interior styles are drawing by shader program with geometry shader.
    Added new parameters for vaspects command:
    [-setWireframeWidth LineWidth] - set width of wireframe line for new interior styles.
    [-unsetWireframeWidth] - set width of wireframe line to default value.
    And added new aliases vsetwfwidth and vunsetwfwidth for new parameters.
    Updated vsetinteriorstyle command.

git

2018-08-06 10:33

administrator   ~0078415

Branch CR29076_1 has been updated forcibly by mnv.

SHA-1: 0b42ba6ae5dc06082c55e062b8fa9a11bf85fcc1

git

2018-08-06 10:55

administrator   ~0078417

Branch CR29076_1 has been updated forcibly by mnv.

SHA-1: a0691cc4bb8249a4b8c3cb462df610dd472697e7

git

2018-08-06 13:49

administrator   ~0078421

Branch CR29076_1 has been updated forcibly by mnv.

SHA-1: be331ed2597c86f54277d9a5e72a0913859ea5a7

git

2018-08-06 14:00

administrator   ~0078422

Branch CR29076_1 has been updated forcibly by mnv.

SHA-1: d209c1a84f1d246388d547ddf6e276e0c575b1e5

mnv

2018-08-06 16:23

developer   ~0078429

Patch is ready for review
http://jenkins-test-11.nnov.opencascade.com:8080/view/CR29076-master-MNV/view/ALL/

kgv

2018-08-06 18:58

developer   ~0078442

+//! IS_SHRINKED   display shrunk triangulation of surface.
...
+Aspect_IS_SHRUNK,

Please move description of enumeration values to their location.
It might be better naming this value Aspect_IS_SHRINK.

git

2018-08-07 11:19

administrator   ~0078452

Branch CR29076_2 has been created by mnv.

SHA-1: 9b4afd3d309f52092004a063562cb9efeb25b44c


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior style:
    - Shrink: display shrunk triangulation of surface
    - Solid Wireframe: display boundaries and surface
    Hollow, Shrink and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameters for vaspects command:
    [-setWireframeWidth LineWidth] - set width of wireframe line for new interior styles.
    [-unsetWireframeWidth] - set width of wireframe line to default value.
    And added new aliases vsetwfwidth and vunsetwfwidth for new parameters.
    Updated vsetinteriorstyle command.

git

2018-08-07 11:20

administrator   ~0078453

Branch CR29076_1 has been updated by mnv.

SHA-1: adc133b300d5dab7fc188bc99b38492d4ce6d698


Detailed log of new commits:

Author: mnv
Date: Tue Aug 7 11:14:13 2018 +0300

    Udated aspects enumeration description.

git

2018-08-09 11:10

administrator   ~0078519

Branch CR29076_2 has been updated forcibly by mnv.

SHA-1: bc63cd54effa5d947472a59431e01e0e540d0788

kgv

2018-08-14 21:59

developer   ~0078617

--- a/src/OpenGl/OpenGl_Text.cxx
+++ b/src/OpenGl/OpenGl_Text.cxx
+  OpenGl_AspectFace anAspect;
+  anAspect.Aspect()->SetAlphaMode(Graphic3d_AlphaMode_Opaque);
   theCtx->ShaderManager()->BindFaceProgram (Handle(OpenGl_TextureSet)(), Graphic3d_TOSM_UNLIT,
-                                            Graphic3d_AlphaMode_Opaque, Standard_False, Standard_False,
+                                            anAspect.Aspect(), Standard_False, Standard_False,

This is unacceptable creating OpenGl_AspectFace for such purpose.

--- a/src/Graphic3d/Graphic3d_AspectFillArea3d.hxx
+++ b/src/Graphic3d/Graphic3d_AspectFillArea3d.hxx
   Aspect_TypeOfLine            myEdgeType;
   Standard_ShortReal           myEdgeWidth;
   Handle(Graphic3d_HatchStyle) myHatchStyle;
+  Standard_Integer             myWireframeWidth;

myEdgeWidth is not enough or it is used for another purpose?

-    Standard_Integer aBits = getProgramBits (theTextures, theAlphaMode, theHasVertColor, false);
+    Standard_Integer aBits = getProgramBits(theTextures, theAlphaMode, theHasVertColor, false);

Unrelated changes should be avoided.

-                                   Graphic3d_AlphaMode theAlphaMode,
+                                   const Graphic3d_AlphaMode theAlphaMode,

This change makes no sense.

+    switch (theAspect->InteriorStyle())
+    {
+    case Aspect_IS_HOLLOW:

Broken indentation for cases.

+  Standard_Boolean BindFaceProgram (const Handle(OpenGl_TextureSet)&          theTextures,
+    myWireframeWidth = theAspect->WireframeWidth();
+    myWireframeColor = theAspect->EdgeColor();

It doesn't look consistent to management of other properties.

+    theProgram->SetUniform(myContext, aLocViewPort, aViewport);
+  }
+  
+  const GLint aLocLineWidth = theProgram->GetUniformLocation(myContext, "occLineWidth");

Please avoid trailing spaces.

+  const GLint aLocViewPort = theProgram->GetUniformLocation(myContext, "occViewport");
+  const GLint aLocLineWidth = theProgram->GetUniformLocation(myContext, "occLineWidth");
+  const GLint aLocWireframeColor = theProgram->GetUniformLocation(myContext, "occWireframeColor");

These are expected to be cached within OpenGl_ShaderProgram.

occLineWidth

Make sure this is properly multiplied by rendering resolution (see OpenGl_Context::SetLineWidth()).
Check rendering with non-standard rendering scale (vrenderparams -rendScale and -resolution).

+        EOL"THE_SHADER_IN  vec4 VertColorVS[];"
+        EOL"THE_SHADER_OUT vec4 VertColorFS;" : "")

You may use shorter "in" and "out" within GLSL130+ Shaders (which Geometry Shaders require anyway) instead of THE_SHADER_IN/THE_SHADER_OUT intended for compatibility with old OpenGL 2.1.

+  const Standard_Boolean  isUseGeomShader  = theBits & OpenGl_PO_HollowMode || 
+                                             theBits & OpenGl_PO_ShrinkMode || 
+                                             theBits & OpenGl_PO_SolidWFMode;

toUseGeomShader.

-    aSrcVertExtraOut  += EOL"THE_SHADER_OUT vec4 VertColor;";
-    aSrcVertExtraMain += EOL"  VertColor = occVertColor;";
-    aSrcFragExtraOut  += EOL"THE_SHADER_IN  vec4 VertColor;";
-    aSrcFragGetColor  =  EOL"vec4 getColor(void) { return VertColor; }";
+    if (isUseGeomShader)
+    {
+      aSrcVertExtraOut  += EOL"THE_SHADER_OUT vec4 VertColorVS;";
+      aSrcVertExtraMain += EOL"  VertColorVS = occVertColor;";
+      aSrcFragExtraOut  += EOL"THE_SHADER_IN  vec4 VertColorFS;";
+      aSrcFragGetColor   = EOL"vec4 getColor(void) { return VertColorFS; }";
+    }
+    else
+    {
+      aSrcVertExtraOut  += EOL"THE_SHADER_OUT vec4 VertColor;";
+      aSrcVertExtraMain += EOL"  VertColor = occVertColor;";
+      aSrcFragExtraOut  += EOL"THE_SHADER_IN  vec4 VertColor;";
+      aSrcFragGetColor   = EOL"vec4 getColor(void) { return VertColor; }";
+    }

Using macros for in/out attributes coming from/to vertex/fragment/geometric shader, or introducing some custom preprocessor, should be better then duplicating big portions of code.

+  const Standard_Boolean isUseGeomShader = theBits & OpenGl_PO_HollowMode ||
+                                           theBits & OpenGl_PO_ShrinkMode ||
+                                           theBits & OpenGl_PO_SolidWFMode;

It doesn't look like code properly checks that GL context supports Geometric Shaders in advance leading to potential misbehavior.
Please add checks and verify code (you may add early out at various points-GL versions within OpenGl_Context::Init() as fast check; in addition, you may execute program using Mesa software implementation within Compatibility Profile or/and on Android devices limited by OpenGL ES 2.0 features).

kgv

2018-08-14 23:40

developer   ~0078618

Last edited: 2018-08-14 23:42

Declare input/output variables using interface blocks (when Geometry Shader is used), so that to keep same names across stages like this:

# Vertex Shader - nameless instance
out VertexData
{
  vec4 VertColor;
};
void main()
{
  VertColor = occColor;
  gl_Position = occVertex;
}


# Geometry Shader - two named instances for input (array) and output
layout(triangles) in;
layout(triangle_strip, max_vertices=3) out;
in VertexData
{
  vec4 VertColor;
} geomIn[3];

out VertexData
{
  vec4 VertColor;
} geomOut;
void main()
{
  mat4 aMat = occProjectionMatrix * occWorldViewMatrix * occModelWorldMatrix;
  for (int aTriVertIter = 0; aTriVertIter < 3; ++aTriVertIter)
  {
    gl_Position = aMat * gl_in[aTriVertIter].gl_Position;
    geomOut.VertColor = geomIn[aTriVertIter].VertColor;
    EmitVertex();
  }
  EndPrimitive();
}


# Fragment Shader - nameless instance
in VertexData
{
  vec4 VertColor;
};
void main()
{
  occFragColor = VertColor;
}


git

2018-08-20 09:13

administrator   ~0078685

Branch CR29076_3 has been created by mnv.

SHA-1: 5aa406dce16934ca06b85df31671e023ce6f5c73


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Shrink: display shrunk triangulation of surface
    - Solid Wireframe: display boundaries and surface
    Hollow, HiddenLine, Shrink and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.

git

2018-08-20 09:15

administrator   ~0078686

Branch CR29076_2 has been updated forcibly by mnv.

SHA-1: 7ec9ff6da893d77d5d87e09c5e9c3fb2a3ea394b

git

2018-08-20 13:47

administrator   ~0078688

Branch CR29076_3 has been updated forcibly by mnv.

SHA-1: 153846f7c2530a84746f508d4ff5b9cdd1f5f7fd

git

2018-08-20 14:25

administrator   ~0078689

Branch CR29076_3 has been updated forcibly by mnv.

SHA-1: 6679e92105bc3c706c062bc29c48f43750141c9f

git

2018-08-20 14:32

administrator   ~0078690

Branch CR29076_4 has been created by mnv.

SHA-1: 6679e92105bc3c706c062bc29c48f43750141c9f


No new revisions were added by this update.

git

2018-08-20 14:33

administrator   ~0078691

Branch CR29076_4 has been deleted by mnv.

SHA-1: 6679e92105bc3c706c062bc29c48f43750141c9f

git

2018-08-28 09:31

administrator   ~0078806

Branch CR29076_4 has been created by mnv.

SHA-1: b9870f07075d49f483fe74a7f84affb9244c0540


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Shrink: display shrunk triangulation of surface
    - Solid Wireframe: display boundaries and surface
    Hollow, HiddenLine, Shrink and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.

Author: mnv
Date: Fri Aug 24 14:08:53 2018 +0300

    Added camera scale for shrunk display mode.

Author: mnv
Date: Mon Aug 27 16:49:58 2018 +0300

    Added new inerior style for scalability shrunk presentation.
    Added quad presentation mode.

git

2018-08-31 17:18

administrator   ~0078900

Branch CR29076_5 has been created by mnv.

SHA-1: cd0d6aee23a874e5e85185303f5c58e605656243


No new revisions were added by this update.

git

2018-09-05 16:14

administrator   ~0079001

Branch CR29076_5 has been updated forcibly by mnv.

SHA-1: 71deb242a651ab3582dbc1b79b4ef14cfa701613

git

2018-09-05 19:02

administrator   ~0079007

Branch CR29076_5 has been updated forcibly by mnv.

SHA-1: 37de0c07122b484a7aa3613b235eafc0b72933e9

mnv

2018-09-05 19:02

developer   ~0079008

Patch is ready for review.

san

2018-09-05 19:07

developer   ~0079009

Is it possible to have few up-to-date screenshots attached to the issue, with different scene zoom factors - to evaluate rendering quality and behavior with respect to zooming?

kgv

2018-09-06 10:50

developer   ~0079010

+  void SetScaleFactor (const Standard_Real theScaleFactor)
+  {
+    myScaleFactor = (float)theScaleFactor;
+  }

Why Standard_Real?

+  //! Returns true if advanced shading is on (true by default).
+  Standard_Boolean IsAdvancedShading() const { return myIsAdvancedShading; }

The property name and description is confusing.

+  //! Returns true if quad presentation is on (false by default).
+  bool IsQuadMode() const { return myIsQuadMode; }

What it is supposed to mean?

   bool                    myToMapTexture;
+  Standard_ShortReal      myScaleFactor;
+  Standard_Boolean        myIsQuadMode;

Please reorder fields for better packing.

-  Graphic3d_TypeOfLimit_NB                              //!< number of elements in this enumeration
+  Graphic3d_TypeOfLimit_NB,                             //!< number of elements in this enumeration
+  Graphic3d_TypeOfLimit_HasShrunkPrs                    //!< indicates whether shrunk presentation is supported

Please read description of _NB enumeration value before adding new values.

--- a/src/OpenGl/OpenGl_Context.hxx
+++ b/src/OpenGl/OpenGl_Context.hxx
@@ -784,6 +784,9 @@ public: //! @name methods to alter or retrieve current state
     myLineWidthScale  = Max (1.0f, std::floor (theRatio + 0.5f));
   }
 
+  //! Return scale factor for line width.
+  Standard_ShortReal LineWidthScale() const { return myLineWidthScale; }

Usually get-ter is expected to precede set-ter.

+    case Graphic3d_TypeOfLimit_HasShrunkPrs:
+      return aCtx->IsGlGreaterEqual (3, 2);

Doesn't look correct.

+  OpenGl_PO_PixelShrinkMode = 0x2000,  //!< pixel shrunk triangulation display mode
+  OpenGl_PO_SolidWFMode     = 0x4000,  //!< solid wireframe display mode
+  OpenGl_PO_HiddenLine      = 0x8000,  //!< removed hidden lines display mode
+  OpenGl_PO_ScaleShrinkMode = 0x10000, //!< scalability shrunk triangulation display mode

These are used as enumeration, not as bit flags which can be combined together.
Please define it as dedicated enumeration and add a bitmask to cover its values.

+// =======================================================================
+// function : prepareEdgeDistString
+// purpose  : Auxiliary function for prepareGeomSrc function
+// =======================================================================
+TCollection_AsciiString prepareEdgeDistString (const Standard_Integer& theTriVertIter)

Why Standard_Integer& ? It also looks like "static" is missing.
Please use normal //! doxygen syntax for describing function in place of its declaration.

+// =======================================================================
+// function : prepareGeomSrc
+// purpose  :
+// =======================================================================
+TCollection_AsciiString OpenGl_ShaderManager::prepareGeomMainSrc (const OpenGl_ShaderVarList& theVarList,

Inconsistent header.

+          EOL"    for (int aTriVertIter = 0; aTriVertIter < 3; ++aTriVertIter)"
+          EOL"    {"
+          EOL"      aCenter += gl_in[aTriVertIter].gl_Position.xyz;"
+          EOL"    }"
+          EOL"    aCenter /= 3.0;"

Looks like it is simpler unrolling loop in source code.

+  TCollection_AsciiString aSrcMainGeom = TCollection_AsciiString()
+    + ((theBits & OpenGl_PO_ScaleShrinkMode) != 0
+        ? EOL"void main()"

The block looks too big for ternary operator - consider using if/else instead.

+          EOL"  vec3 aWinCoord = theVec.xyz / theVec.w;"
+          EOL"  aWinCoord   = aWinCoord * 0.5 + 0.5;"
+          EOL"  aWinCoord.x = aWinCoord.x * occViewport[0] + occViewport[2];"
+          EOL"  aWinCoord.y = aWinCoord.y * occViewport[1] + occViewport[3];"
+          EOL"  return aWinCoord;"

Consider writing this in a single line.

+  const Standard_Boolean  toUseGeomShader  = myContext->IsGlGreaterEqual(3, 2) && (theBits & OpenGl_PO_AdvShading) != 0;

If I understand the purpose of OpenGl_PO_AdvShading flag, it should be within global Caps, not within GLSL program bits.

+        EOL"  Normal = normalize (cross (dFdx (Position.xyz / Position.w), dFdy (Position.xyz / Position.w)));"//;

//;

+//! List of variable of shader program.
+typedef NCollection_Vector<TCollection_AsciiString> OpenGl_ShaderVarList;

Why it is a vector, not a sequence?
Looks like misused collection basing on context.

+    if (myContext->SampleAlphaToCoverage())
+    {
+      theBits |= OpenGl_PO_MSAA;

So why a bit flag is called "MSAA", while it has a different meaning?

+  Standard_EXPORT void SetAspects (const Standard_ShortReal& theWireframeWidth,
+                                   const OpenGl_Vec3&        theWireframeColor,
+                                   const Standard_ShortReal& theScaleFactor,

"const Standard_ShortReal&" doesn't make sense for primitive types.

+  Standard_EXPORT void SetViewport (const OpenGl_Vec4& theViewport) { myViewport = theViewport; }
+  Standard_EXPORT Standard_ShortReal WireframeWidth() const { return myWireframeWidth; }
+  Standard_EXPORT const OpenGl_Vec3& WireframeColor() const { return myWireframeColor; }
...
>> other places <<

Inline methods should not be exported from DLL.

+  Standard_ShortReal myWireframeWidth; //!< wireframe width
+  OpenGl_Vec3        myWireframeColor; //!< wireframe color
+  OpenGl_Vec4        myViewport;       //!< viewport properties
+  Standard_ShortReal myScaleFactor;    //!< scale factor for shrunk presentation

Consider reordering fields.

+  aManager->SetWireframeViewportState (OpenGl_Vec4 ((float)aContext->Viewport()[2], 
+                                                    (float)aContext->Viewport()[3],
+                                                    (float)aContext->Viewport()[0], 
+                                                    (float)aContext->Viewport()[1]));

Does it make sense reordering of well-known array?

+      if (aValue == "on"
+       || aValue == "1")
+      {
+        aChangeSet->ToSetAdvancedShading = 1;
+      }
+      else if (aValue == "off"
+            || aValue == "0")

ViewerTest::ParseOnOff()

+      + ((theBits & OpenGl_PO_MSAA) != 0 ? EOL"  occSetFragColor (vec4 (aEdgeColor, 1 - aMixVal));"

Invalid GLSL code.
Please make sure that GLSL programs are compilable without warnings on OpenGL drivers of different vendors.

+                                           EOL"  if (aMixColor.a == 0.0) discard;"
+                                           EOL"  else occSetFragColor (aMixColor);");

Why discard is needed here? Does it affect result or improves performance?

+void OpenGl_ShaderManager::prepareShadersOutSrc()

Please move this in/out variables processing into dedicated patch, so that we can push it to master soon in front of other part of the patch.

Hollow, Hidden Line, Shrinks and Solid Wireframe interior styles are drawing by shader program with geometry shader.

Please describe in more detail changes in behavior including benefits (performance, line size within Core Profile, OpenGL ES support) and cons (possible disappearance of entire mesh on zoom-out, etc.).
Put also information into upgrade guide.

> AP1_s1_clean_test_perf.jpg
Please put performance comparison to this bug in text form and I don't see performance results for other vendors - only NVIDIA is listed, no Intel and any mobile OpenGL ES graphics.

git

2018-09-10 14:44

administrator   ~0079086

Branch CR29076_6 has been created by mnv.

SHA-1: 6b297c2420b8cb2c363183ef85a229fe5f3624e6


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Pixel Shrink: display shrunk triangulation of surface on pixels
    - Scale Shrink: display shrunk triangulation of surface on scalability
    - Solid Wireframe: display boundaries and surface
    Hollow, Hidden Line, Shrinks and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    [-scalefactor] - set scale factor value for Scale Shrink presentation.
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.
    Added quad presentation mode.

git

2018-09-10 15:34

administrator   ~0079088

Branch CR29076_6 has been updated forcibly by mnv.

SHA-1: 04ac8ac2cc6c270c37fd294de338a1df3391d023

git

2018-09-11 09:40

administrator   ~0079110

Branch CR29076_6 has been updated forcibly by mnv.

SHA-1: 4925f5f415ce34c73289249c52e75f22d26cd592

git

2018-09-27 09:23

administrator   ~0079430

Branch CR29076_12 has been created by mnv.

SHA-1: 00303e92e6d783b25df2198f6bc865e004db3f3c


Detailed log of new commits:

Author: mnv
Date: Thu Sep 27 08:38:15 2018 +0300

    Implemented procedural generation of shader in/out section.

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Pixel Shrink: display shrunk triangulation of surface on pixels
    - Scale Shrink: display shrunk triangulation of surface on scalability
    - Solid Wireframe: display boundaries and surface
    Hollow, Hidden Line, Shrinks and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    [-scalefactor] - set scale factor value for Scale Shrink presentation.
    Using the geometry shader has the following advantages:
    Hollow, Hidden Line and Solid Wireframe - configurable line size without using glPolygonMode.
    New interior styles support by OpenGl ES 3.2+.
    Better frame rate for big models (10M+ triangles).
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.
    Added quad presentation mode.
    Updated upgrade documentation.

Author: mnv
Date: Mon Sep 24 11:53:12 2018 +0300

    0030153: Visualization, TKOpenGl - AIS_ColoredShape::SynchronizeAspects() doesn't update all aspects
    
    Added new virtual method OpenGl_Element::UpdateParameters().
    This method is needed for updating aspects for all OpenGl group members.
    Added new virtual method Graphic3d_Group::SynchronizeAspects().
    This method is overriden in OpenGl_Group and implement logic for updating presentation aspects after their modification.

Author: mnv
Date: Thu Sep 13 17:47:51 2018 +0300

    0030136: Visualization, TKOpenGl - Graphic3d_TOSM_FACET does not work on mobile devices
    
    Added new type of graphic3d limit Graphic3d_TypeOfLimit_HasFlatShading.
    Added workaround for unexpected behaviour of mobile devices with Adreno GPU.
    Added new complex flag hasFlatShading to OpenGl_Context for indicating support of flat shading.

git

2018-10-09 17:54

administrator   ~0079828

Branch CR29076_15 has been created by mnv.

SHA-1: 27dec47884cad617d6c14df69bd9a848c1f264da


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Solid Wireframe: display boundaries and surface
    Hollow, Hidden Line and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    Using the geometry shader has the following advantages:
    Hollow, Hidden Line and Solid Wireframe - configurable line size without using glPolygonMode.
    New interior styles support by OpenGl ES 3.2+.
    Better frame rate for big models (10M+ triangles).
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.
    Added quad presentation mode.
    Updated upgrade documentation.

Author: mnv
Date: Fri Sep 7 10:18:46 2018 +0300

    0030119: Visualization - implement mechanism for generating in/out section of shader programs.
    
    Added functionality which generate in/out part of shaders source code from prepared list of variables.

Author: mnv
Date: Thu Sep 27 16:30:48 2018 +0300

    0030166: Visualization, TKOpenGl - Implement the functionality for outputting the source code of the shader program.
    
    Added new option -glslcode for vgldebug command.
    This option have folowing parameters:
    off - disable glsl source code outputs
    short - outputs glsl source code in short format (except common declarations (global constants and Vertex Shader inputs))
    full - outputs glsl source code in full format.

git

2018-10-10 08:32

administrator   ~0079833

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: e33a14d32d09a201930bf3faae4605ac3c8dea94

git

2018-10-10 08:45

administrator   ~0079834

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: 95e381c9c1ae1dbc4c821e6b36abf4355e751dce

git

2018-10-10 10:03

administrator   ~0079836

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: 486704677d845b5975f8375f2c7716b4068342e3

git

2018-10-10 12:18

administrator   ~0079848

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: 7d28ebf0db5f62aba128ec71289f9c9171487d59

git

2018-10-11 10:24

administrator   ~0079873

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: 7dee8729342dc3b86449aad6a70cecfef716b499

mnv

2018-10-11 11:17

developer  

bug29076.png (89,697 bytes)

git

2018-10-11 11:20

administrator   ~0079876

Branch CR29076_15 has been updated forcibly by mnv.

SHA-1: c0b71a4ad092e8249d9850d03de70938d60676a1

git

2018-10-11 14:25

administrator   ~0079890

Branch CR29076_16 has been created by mnv.

SHA-1: e1783394c439713c1083c01c1c2325f9cfd16a3d


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Solid Wireframe: display boundaries and surface
    Hollow, Hidden Line and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    Using the geometry shader has the following advantages:
    Hollow, Hidden Line and Solid Wireframe - configurable line size without using glPolygonMode.
    New interior styles support by OpenGl ES 3.2+.
    Better frame rate for big models (10M+ triangles).
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.
    Added quad presentation mode.
    Updated upgrade documentation.

Author: mnv
Date: Thu Sep 27 16:30:48 2018 +0300

    0030166: Visualization, TKOpenGl - add option OpenGl_Caps::glslDumpLevel dumping the source code of the shader program
    
    Added new option -glslcode for vgldebug command with the following values:
    - off disables glsl source code dump;
    - short to dump glsl source code in short format (except common declarations);
    - full to dump glsl source code in full format.

mnv

2018-10-12 11:16

developer   ~0079910

Patch is ready for review.

git

2018-10-15 15:57

administrator   ~0079966

Branch CR29076_16 has been updated forcibly by mnv.

SHA-1: b071cafcbab0a959e7ac3203bdb6c9649fd4e670

git

2018-10-16 15:14

administrator   ~0080017

Branch CR29076_16 has been updated forcibly by mnv.

SHA-1: 5880e85d306ca473aec446460f2d2501f80287d5

git

2018-10-17 16:37

administrator   ~0080064

Branch CR29076_16 has been updated forcibly by mnv.

SHA-1: 055548752f350c71d74df9f567bcd679b206aa0e

git

2018-10-17 17:36

administrator   ~0080069

Branch CR29076_16 has been updated forcibly by mnv.

SHA-1: e1e9a867445484ba8f34078e5c2765d50aa4621d

kgv

2018-10-22 23:46

developer   ~0080211

Please rebase the patch.

git

2018-10-23 15:01

administrator   ~0080231

Branch CR29076_17 has been created by mnv.

SHA-1: b86da1888ba5fe599ead3df0361fee189192c453


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Element shrinking shader was implemented.
    Added new Interior styles:
    - Solid Wireframe: display boundaries and surface
    Hollow, Hidden Line and Solid Wireframe interior styles are drawing by shader program with geometry shader.
    Added new parameter for vsetedgetype command:
    [-width] - set width of wireframe line.
    Using the geometry shader has the following advantages:
    Hollow, Hidden Line and Solid Wireframe - configurable line size without using glPolygonMode.
    New interior styles support by OpenGl ES 3.2+.
    Better frame rate for big models (10M+ triangles).
    Updated vsetinteriorstyle command.
    Updated behaviour of vsetedgetype command.
    Added quad presentation mode.
    Updated upgrade documentation.

git

2018-10-24 08:23

administrator   ~0080245

Branch CR29076_17 has been updated forcibly by mnv.

SHA-1: a51692888e51ef2ed3e44187bb3c65143953c9d6

mnv

2018-10-24 10:53

developer   ~0080252

Patch rebased and ready for review.
http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR29076-master-MNV/view/ALL/

git

2018-12-13 12:29

administrator   ~0081506

Branch CR29076_17 has been updated forcibly by mnv.

SHA-1: 86c8ae991cf25cd7539cca5d49ba8deffe578caf

mnv

2018-12-13 15:33

developer   ~0081515

Patch is ready for review
http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR29076-master-MNV/view/ALL/

git

2018-12-18 10:50

administrator   ~0081545

Branch CR29076_17 has been updated forcibly by mnv.

SHA-1: fe3edaefb53741db03f6bf9ece2c520d08af0b88

git

2018-12-18 10:51

administrator   ~0081546

Branch CR29076_17 has been updated forcibly by mnv.

SHA-1: 2d9911c267d5ff5e65dbb6ca5725137448be01fd

mnv

2018-12-18 13:56

developer   ~0081551

Patch rebased and ready for review
http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR29076-master-MNV/view/ALL/

git

2019-02-14 19:13

administrator   ~0082184

Branch CR29076_18 has been created by kgv.

SHA-1: ba78c3ded68d39e2164d7f22367a40560bc17429


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Aspect_InteriorStyle has been extended by Aspect_IS_SOLID_WIREFRAME,
    which is now used by Graphic3d_AspectFillArea3d::SetDrawEdges() instead of dedicated Boolean flag.
    
    OpenGl_ShaderManager now provides built-in GLSL programs for drawing
    Aspect_IS_SOLID_WIREFRAME, Aspect_IS_HOLLOW and Aspect_IS_HIDDENLINE
    styles in single pass (and on OpenGL ES which does not provide glPolygonMode()).
    
    OpenGl_PrimitiveArray now uses GLSL programs instead of glPolygonMode() by default,
    which can be managed by OpenGl_Caps::usePolygonMode flag (desktop OpenGL only).
    glPolygonMode() is also used as fallback regardless OpenGl_Caps::usePolygonMode flag
    when GLSL programs are not supported (Geometry Shaders are required)
    or stipple line style is required (not implemented within Face GLSL).
    
    vsetedgetype and vsetinteriorstyle commands have been refactored to relax input syntax,
    handle Interior Style enumeration by names instead of integers,
    handle normalized color components, and avoid unnecessary actions.
    
    Redundant command BUC60738 has been removed.

git

2019-02-14 20:05

administrator   ~0082185

Branch CR29076_18 has been updated forcibly by kgv.

SHA-1: c3e5c7acc2db8794012f023c6015a44d314a1029

git

2019-02-14 20:17

administrator   ~0082186

Branch CR29076_18 has been updated forcibly by kgv.

SHA-1: 5b4e33c109335f79560efc8072e989494c690e1a

git

2019-02-14 20:27

administrator   ~0082187

Branch CR29076_18 has been updated forcibly by kgv.

SHA-1: c6f6dce30646921e10ba0ae001dedce12abbc691

git

2019-02-14 20:50

administrator   ~0082188

Branch CR29076_18 has been updated forcibly by kgv.

SHA-1: 2e34c19edf1c5b1535d4d6e82cc5419a62b7b3f2

git

2019-02-14 23:41

administrator   ~0082189

Branch CR29076_18 has been updated forcibly by kgv.

SHA-1: d0df7c31f40e4686ee12421cc7a23a6b94582ce0

git

2019-02-19 00:04

administrator   ~0082216

Branch CR29076_19 has been created by kgv.

SHA-1: 099f86e247bdc04f8c2903d84d5d2266d757a0b8


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Aspect_InteriorStyle has been extended by Aspect_IS_SOLID_WIREFRAME,
    which is now used by Graphic3d_AspectFillArea3d::SetDrawEdges() instead of dedicated Boolean flag.
    
    OpenGl_ShaderManager now provides built-in GLSL programs for drawing
    Aspect_IS_SOLID_WIREFRAME, Aspect_IS_HOLLOW and Aspect_IS_HIDDENLINE
    styles in single pass (and on OpenGL ES which does not provide glPolygonMode()).
    
    OpenGl_PrimitiveArray now uses GLSL programs instead of glPolygonMode() by default,
    which can be managed by OpenGl_Caps::usePolygonMode flag (desktop OpenGL only).
    glPolygonMode() is also used as fallback regardless OpenGl_Caps::usePolygonMode flag
    when GLSL programs are not supported (Geometry Shaders are required)
    or stipple line style is required (not implemented within Face GLSL).
    
    vsetedgetype and vsetinteriorstyle commands have been refactored to relax input syntax,
    handle Interior Style enumeration by names instead of integers,
    handle normalized color components, and avoid unnecessary actions.
    
    Redundant command BUC60738 has been removed.

git

2019-02-19 01:52

administrator   ~0082217

Branch CR29076_19 has been updated forcibly by kgv.

SHA-1: 67810589039f382e8d898c93340f18dcba81bb92

git

2019-02-19 02:03

administrator   ~0082218

Branch CR29076_19 has been updated forcibly by kgv.

SHA-1: c97eed8cda721714c8e9402ad1dd4b043ec87475

git

2019-02-19 17:50

administrator   ~0082225

Branch CR29076_20 has been created by kgv.

SHA-1: ffcc4759d6a0d1f557755e39eb1c8c2e93421cf1


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Aspect_InteriorStyle has been extended by Aspect_IS_SOLID_WIREFRAME,
    which is now used by Graphic3d_AspectFillArea3d::SetDrawEdges() instead of dedicated Boolean flag.
    
    OpenGl_ShaderManager now provides built-in GLSL programs for drawing
    Aspect_IS_SOLID_WIREFRAME, Aspect_IS_HOLLOW and Aspect_IS_HIDDENLINE
    styles in single pass (and on OpenGL ES which does not provide glPolygonMode()).
    
    Graphic3d_RenderingParams::ToEnableAlphaToCoverage is now enabled by default
    and properly handled at TKOpenGl level - enables coverage for Graphic3d_AlphaMode_Mask primitives.
    
    OpenGl_PrimitiveArray now uses GLSL programs instead of glPolygonMode() by default,
    which can be managed by OpenGl_Caps::usePolygonMode flag (desktop OpenGL only).
    glPolygonMode() is also used as fallback regardless OpenGl_Caps::usePolygonMode flag
    when GLSL programs are not supported (Geometry Shaders are required)
    or stipple line style is required (not implemented within Face GLSL).
    
    vaspects command has been extended by -setInterior -setEdgeColor -setEdgeType -setEdgeWidth
    arguments replacing vsetinteriorstyle/vsetedgetype/vunsetedgetype commands.
    ViewerTest::ParseColor() now parses RGBA color.
    
    Redundant command BUC60738 has been removed.

git

2019-02-19 19:45

administrator   ~0082226

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 829d02ee7644838af71fd1965b7c57aad0d2177e

git

2019-02-19 19:48

administrator   ~0082227

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 07437c1fecf81f69e9957a8f22bb83b484b5a530

git

2019-02-19 20:36

administrator   ~0082228

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 3692b72a468e490d761a67b56fe1f6b1a4c9d9aa

git

2019-02-19 21:37

administrator   ~0082229

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 38f7f13a58c4215f6bcd31d6afd56f6b49ad0373

git

2019-02-19 21:51

administrator   ~0082230

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: b817859b3f2639097f1845e4dac151b916dab074

git

2019-02-19 22:22

administrator   ~0082231

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: b471037e73fdf86c9eba519b4343b4ba7001a207

git

2019-02-19 22:58

administrator   ~0082232

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 6457543337b8f29fee9cd4484a5359590a54ba76

git

2019-02-20 09:59

administrator   ~0082234

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 1828cc115feacd4b68d501961b2b9a11c762ac1e

git

2019-02-20 12:11

administrator   ~0082238

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: df41f1f5a5d1c2128ffb0b05a89337c29187b79b

git

2019-02-20 18:38

administrator   ~0082240

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: e6d82aad0bd4823cbbefacd65c296a8e70c15be4

kgv

2019-02-20 19:45

developer  

interior1_persp_glsl_msaa.png (96,992 bytes)

kgv

2019-02-20 19:45

developer  

interior2_persp_glsl_msaa.png (28,600 bytes)

kgv

2019-02-20 20:07

developer   ~0082242

Please raise the patch.

http://jenkins-test-12.nnov.opencascade.com:8080/view/CR29076_20-CR29076_20-KGV/

git

2019-02-20 21:51

administrator   ~0082243

Branch CR29076_20 has been updated forcibly by kgv.

SHA-1: 1fd65732ec097091e39da6be0c42fa7b20640d2a

apn

2019-02-21 17:03

administrator   ~0082278

Combination -
OCCT branch : CR29076_20
master SHA - 1fd65732ec097091e39da6be0c42fa7b20640d2a
d67d4b811012eef8913d3c535c29654d0acf3c4c
Products branch : CR29076_20 SHA - d02742684bde53dfe75415683a98c98f95273a35
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: 16542.63999999998 / 16568.890000000087 [-0.16%]
Products
Total CPU difference: 9102.370000000032 / 9068.370000000014 [+0.37%]
Windows-64-VC14:
OCCT
Total CPU difference: 18026.921875 / 17934.78125 [+0.51%]
Products
Total CPU difference: 10466.09375 / 10477.75 [-0.11%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2019-02-22 11:07

administrator   ~0082293

Branch CR29076_21 has been created by kgv.

SHA-1: 7f0b60ea64a13041d10f7e1d8559a77d80448243


Detailed log of new commits:

Author: mnv
Date: Wed Aug 1 18:09:37 2018 +0300

    0029076: Visualization - implement element shrinking Shader
    
    Aspect_IS_HOLLOW now an alias to Aspect_IS_EMPTY and Aspect_IS_HIDDENLINE does not implicitly enables mesh edges,
    so that Graphic3d_AspectFillArea3d::SetDrawEdges() should be set independently.
    
    OpenGl_ShaderManager now provides built-in GLSL programs for drawing mesh edges
    in single pass (and on OpenGL ES which does not provide glPolygonMode()).
    
    Graphic3d_RenderingParams::ToEnableAlphaToCoverage is now enabled by default
    and properly handled at TKOpenGl level - enables coverage for Graphic3d_AlphaMode_Mask primitives.
    
    OpenGl_PrimitiveArray now uses GLSL programs instead of glPolygonMode() by default,
    which can be managed by OpenGl_Caps::usePolygonMode flag (desktop OpenGL only).
    glPolygonMode() is also used as fallback regardless OpenGl_Caps::usePolygonMode flag
    when GLSL programs are not supported (Geometry Shaders are required)
    or stipple line style is required (not implemented within Face GLSL).
    
    vaspects command has been extended by -setInterior -setDrawEdges -setEdgeColor -setEdgeType -setEdgeWidth
    arguments replacing vsetinteriorstyle/vsetedgetype/vunsetedgetype commands.
    vaspects now accepts arguments without "set" prefix.
    ViewerTest::ParseColor() now parses RGBA color.
    
    Redundant command BUC60738 has been removed.
    AIS_ColorScale - fixed usage of uninitialized FillArea aspects.

kgv

2019-02-22 12:18

developer   ~0082296

Please take updated patch CR29076_21 into IR.

http://jenkins-test-12.nnov.opencascade.com:8080/view/CR29076_21-CR29076_20-KGV/

git

2019-03-05 13:46

administrator   ~0082610

Branch CR29076_17 has been deleted by kgv.

SHA-1: 2d9911c267d5ff5e65dbb6ca5725137448be01fd

git

2019-03-05 13:46

administrator   ~0082611

Branch CR29076_18 has been deleted by kgv.

SHA-1: d0df7c31f40e4686ee12421cc7a23a6b94582ce0

git

2019-03-05 13:46

administrator   ~0082612

Branch CR29076_19 has been deleted by kgv.

SHA-1: c97eed8cda721714c8e9402ad1dd4b043ec87475

git

2019-03-05 13:46

administrator   ~0082613

Branch CR29076_20 has been deleted by kgv.

SHA-1: 1fd65732ec097091e39da6be0c42fa7b20640d2a

git

2019-03-05 13:46

administrator   ~0082614

Branch CR29076_21 has been deleted by kgv.

SHA-1: 7f0b60ea64a13041d10f7e1d8559a77d80448243

git

2019-03-05 13:48

administrator   ~0082657

Branch CR29076 has been deleted by kgv.

SHA-1: bfd000869ad735514c6401fdb34fdf064ba7112c

git

2019-03-05 13:48

administrator   ~0082658

Branch CR29076_1 has been deleted by kgv.

SHA-1: adc133b300d5dab7fc188bc99b38492d4ce6d698

git

2019-03-05 13:48

administrator   ~0082659

Branch CR29076_12 has been deleted by kgv.

SHA-1: 00303e92e6d783b25df2198f6bc865e004db3f3c

git

2019-03-05 13:48

administrator   ~0082660

Branch CR29076_15 has been deleted by kgv.

SHA-1: c0b71a4ad092e8249d9850d03de70938d60676a1

git

2019-03-05 13:48

administrator   ~0082661

Branch CR29076_16 has been deleted by kgv.

SHA-1: e1e9a867445484ba8f34078e5c2765d50aa4621d

git

2019-03-05 13:48

administrator   ~0082662

Branch CR29076_2 has been deleted by kgv.

SHA-1: 7ec9ff6da893d77d5d87e09c5e9c3fb2a3ea394b

git

2019-03-05 13:48

administrator   ~0082663

Branch CR29076_3 has been deleted by kgv.

SHA-1: 6679e92105bc3c706c062bc29c48f43750141c9f

git

2019-03-05 13:48

administrator   ~0082664

Branch CR29076_4 has been deleted by kgv.

SHA-1: b9870f07075d49f483fe74a7f84affb9244c0540

git

2019-03-05 13:48

administrator   ~0082665

Branch CR29076_5 has been deleted by kgv.

SHA-1: 37de0c07122b484a7aa3613b235eafc0b72933e9

git

2019-03-05 13:48

administrator   ~0082666

Branch CR29076_6 has been deleted by kgv.

SHA-1: 4925f5f415ce34c73289249c52e75f22d26cd592

Related Changesets

occt: master 2a332745

2018-08-01 15:09:37

mnv


Committer: apn Details Diff
0029076: Visualization - implement element shrinking Shader

Aspect_IS_HOLLOW now an alias to Aspect_IS_EMPTY and Aspect_IS_HIDDENLINE does not implicitly enables mesh edges,
so that Graphic3d_AspectFillArea3d::SetDrawEdges() should be set independently.

OpenGl_ShaderManager now provides built-in GLSL programs for drawing mesh edges
in single pass (and on OpenGL ES which does not provide glPolygonMode()).

Graphic3d_RenderingParams::ToEnableAlphaToCoverage is now enabled by default
and properly handled at TKOpenGl level - enables coverage for Graphic3d_AlphaMode_Mask primitives.

OpenGl_PrimitiveArray now uses GLSL programs instead of glPolygonMode() by default,
which can be managed by OpenGl_Caps::usePolygonMode flag (desktop OpenGL only).
glPolygonMode() is also used as fallback regardless OpenGl_Caps::usePolygonMode flag
when GLSL programs are not supported (Geometry Shaders are required)
or stipple line style is required (not implemented within Face GLSL).

vaspects command has been extended by -setInterior -setDrawEdges -setEdgeColor -setEdgeType -setEdgeWidth
arguments replacing vsetinteriorstyle/vsetedgetype/vunsetedgetype commands.
vaspects now accepts arguments without "set" prefix.
ViewerTest::ParseColor() now parses RGBA color.

Redundant command BUC60738 has been removed.
AIS_ColorScale - fixed usage of uninitialized FillArea aspects.
Affected Issues
0029076
mod - dox/dev_guides/upgrade/upgrade.md Diff File
mod - dox/user_guides/visualization/visualization.md Diff File
mod - src/AIS/AIS_ColorScale.cxx Diff File
mod - src/AIS/AIS_ColorScale.hxx Diff File
mod - src/AIS/AIS_Shape.cxx Diff File
mod - src/AIS/AIS_Shape.hxx Diff File
mod - src/Aspect/Aspect_InteriorStyle.hxx Diff File
mod - src/Graphic3d/Graphic3d_AspectFillArea3d.cxx Diff File
mod - src/Graphic3d/Graphic3d_AspectFillArea3d.hxx Diff File
mod - src/Graphic3d/Graphic3d_RenderingParams.hxx Diff File
mod - src/Graphic3d/Graphic3d_TypeOfLimit.hxx Diff File
mod - src/OpenGl/OpenGl_Caps.cxx Diff File
mod - src/OpenGl/OpenGl_Caps.hxx Diff File
mod - src/OpenGl/OpenGl_Context.cxx Diff File
mod - src/OpenGl/OpenGl_Context.hxx Diff File
mod - src/OpenGl/OpenGl_GraphicDriver.cxx Diff File
mod - src/OpenGl/OpenGl_LineAttributes.cxx Diff File
mod - src/OpenGl/OpenGl_MaterialState.hxx Diff File
mod - src/OpenGl/OpenGl_PrimitiveArray.cxx Diff File
mod - src/OpenGl/OpenGl_SetOfShaderPrograms.hxx Diff File
mod - src/OpenGl/OpenGl_ShaderManager.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderManager.hxx Diff File
mod - src/OpenGl/OpenGl_ShaderObject.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderProgram.cxx Diff File
mod - src/OpenGl/OpenGl_ShaderProgram.hxx Diff File
mod - src/OpenGl/OpenGl_Text.cxx Diff File
mod - src/OpenGl/OpenGl_View_Redraw.cxx Diff File
mod - src/OpenGl/OpenGl_Workspace.cxx Diff File
mod - src/Prs3d/Prs3d_Drawer.cxx Diff File
mod - src/Prs3d/Prs3d_Drawer.hxx Diff File
mod - src/QABugs/FILES Diff File
mod - src/QABugs/QABugs.cxx Diff File
mod - src/QABugs/QABugs.hxx Diff File
rm - src/QABugs/QABugs_4.cxx Diff File
mod - src/ViewerTest/ViewerTest.cxx Diff File
mod - src/ViewerTest/ViewerTest.hxx Diff File
mod - src/ViewerTest/ViewerTest_ObjectCommands.cxx Diff File
mod - src/ViewerTest/ViewerTest_ViewerCommands.cxx Diff File
mod - tests/bugs/mesh/bug29751 Diff File
mod - tests/bugs/vis/buc60738 Diff File
mod - tests/bugs/vis/bug23363 Diff File
mod - tests/bugs/vis/bug28306 Diff File
mod - tests/bugs/vis/bug6897_1 Diff File
rm - tests/bugs/vis/bug6897_2 Diff File
mod - tests/v3d/begin Diff File
mod - tests/v3d/glsl/alpha_mask Diff File
add - tests/v3d/glsl/interior1 Diff File
add - tests/v3d/glsl/interior2 Diff File

Issue History

Date Modified Username Field Change
2017-09-02 22:55 kgv New Issue
2017-09-02 22:55 kgv Assigned To => kgv
2017-09-02 22:55 kgv File Added: shrink_quad.svg
2017-09-02 22:55 kgv File Added: shrink_triangle.png
2017-09-02 22:55 kgv File Added: shrink_quad.png
2017-09-02 22:55 kgv Relationship added related to 0029074
2018-06-27 12:16 kgv Assigned To kgv => mnv
2018-06-27 12:16 kgv Status new => assigned
2018-07-16 17:16 mnv File Added: geomShader.gs
2018-07-16 17:22 mnv Note Added: 0077683
2018-07-16 17:28 mnv File Deleted: geomShader.gs
2018-07-16 17:29 mnv File Added: geomShader.txt
2018-07-17 12:55 kgv File Added: edge_think.png
2018-08-03 10:51 git Note Added: 0078340
2018-08-03 11:56 git Note Added: 0078347
2018-08-03 12:16 mnv File Added: bug29076_combined.png
2018-08-03 12:16 mnv File Added: bug29076_shrunk.png
2018-08-03 12:16 mnv File Added: bug29076_wireframe.png
2018-08-03 13:48 git Note Added: 0078352
2018-08-03 14:04 git Note Added: 0078354
2018-08-03 16:33 git Note Added: 0078365
2018-08-06 10:33 git Note Added: 0078415
2018-08-06 10:55 git Note Added: 0078417
2018-08-06 13:49 git Note Added: 0078421
2018-08-06 14:00 git Note Added: 0078422
2018-08-06 16:23 mnv Note Added: 0078429
2018-08-06 16:23 mnv Assigned To mnv => kgv
2018-08-06 16:23 mnv Status assigned => resolved
2018-08-06 16:23 mnv Steps to Reproduce Updated
2018-08-06 18:58 kgv Note Added: 0078442
2018-08-06 18:58 kgv Assigned To kgv => mnv
2018-08-06 18:58 kgv Status resolved => assigned
2018-08-07 11:19 git Note Added: 0078452
2018-08-07 11:20 git Note Added: 0078453
2018-08-09 11:04 mnv File Deleted: bug29076_combined.png
2018-08-09 11:04 mnv File Deleted: bug29076_wireframe.png
2018-08-09 11:04 mnv File Deleted: bug29076_shrunk.png
2018-08-09 11:04 mnv File Added: bug29076.png
2018-08-09 11:10 git Note Added: 0078519
2018-08-14 21:59 kgv Note Added: 0078617
2018-08-14 23:40 kgv Note Added: 0078618
2018-08-14 23:42 kgv Note Edited: 0078618
2018-08-17 15:51 mnv File Deleted: bug29076.png
2018-08-17 15:51 mnv File Added: bug29076.png
2018-08-20 09:13 git Note Added: 0078685
2018-08-20 09:15 git Note Added: 0078686
2018-08-20 13:47 git Note Added: 0078688
2018-08-20 14:25 git Note Added: 0078689
2018-08-20 14:32 git Note Added: 0078690
2018-08-20 14:33 git Note Added: 0078691
2018-08-28 09:31 git Note Added: 0078806
2018-08-31 17:18 git Note Added: 0078900
2018-09-05 16:14 git Note Added: 0079001
2018-09-05 19:02 git Note Added: 0079007
2018-09-05 19:02 mnv Note Added: 0079008
2018-09-05 19:02 mnv Assigned To mnv => kgv
2018-09-05 19:02 mnv Status assigned => resolved
2018-09-05 19:07 san Note Added: 0079009
2018-09-06 10:50 kgv Note Added: 0079010
2018-09-06 10:50 kgv Assigned To kgv => mnv
2018-09-06 10:50 kgv Status resolved => assigned
2018-09-10 14:44 git Note Added: 0079086
2018-09-10 15:34 git Note Added: 0079088
2018-09-11 09:40 git Note Added: 0079110
2018-09-27 09:23 git Note Added: 0079430
2018-10-09 17:54 git Note Added: 0079828
2018-10-10 08:32 git Note Added: 0079833
2018-10-10 08:45 git Note Added: 0079834
2018-10-10 10:03 git Note Added: 0079836
2018-10-10 12:18 git Note Added: 0079848
2018-10-11 10:24 git Note Added: 0079873
2018-10-11 11:17 mnv File Deleted: bug29076.png
2018-10-11 11:17 mnv File Added: bug29076.png
2018-10-11 11:20 git Note Added: 0079876
2018-10-11 14:25 git Note Added: 0079890
2018-10-12 11:16 mnv Note Added: 0079910
2018-10-12 11:16 mnv Assigned To mnv => kgv
2018-10-12 11:16 mnv Status assigned => resolved
2018-10-15 15:57 git Note Added: 0079966
2018-10-16 15:14 git Note Added: 0080017
2018-10-17 16:37 git Note Added: 0080064
2018-10-17 17:36 git Note Added: 0080069
2018-10-22 23:45 kgv Relationship added related to 0030119
2018-10-22 23:46 kgv Note Added: 0080211
2018-10-22 23:46 kgv Assigned To kgv => mnv
2018-10-22 23:46 kgv Status resolved => feedback
2018-10-23 15:01 git Note Added: 0080231
2018-10-24 08:23 git Note Added: 0080245
2018-10-24 10:53 mnv Note Added: 0080252
2018-10-24 10:53 mnv Assigned To mnv => kgv
2018-10-24 10:53 mnv Status feedback => resolved
2018-12-13 12:29 git Note Added: 0081506
2018-12-13 15:33 mnv Note Added: 0081515
2018-12-18 10:50 git Note Added: 0081545
2018-12-18 10:51 git Note Added: 0081546
2018-12-18 13:56 mnv Note Added: 0081551
2019-02-14 12:05 bugmaster Project Internal => Open CASCADE
2019-02-14 19:13 git Note Added: 0082184
2019-02-14 20:05 git Note Added: 0082185
2019-02-14 20:17 git Note Added: 0082186
2019-02-14 20:27 git Note Added: 0082187
2019-02-14 20:50 git Note Added: 0082188
2019-02-14 23:41 git Note Added: 0082189
2019-02-15 09:58 kgv Steps to Reproduce Updated
2019-02-19 00:04 git Note Added: 0082216
2019-02-19 01:52 git Note Added: 0082217
2019-02-19 02:03 git Note Added: 0082218
2019-02-19 17:50 git Note Added: 0082225
2019-02-19 19:45 git Note Added: 0082226
2019-02-19 19:48 git Note Added: 0082227
2019-02-19 20:36 git Note Added: 0082228
2019-02-19 21:37 git Note Added: 0082229
2019-02-19 21:51 git Note Added: 0082230
2019-02-19 22:22 git Note Added: 0082231
2019-02-19 22:58 git Note Added: 0082232
2019-02-20 09:59 git Note Added: 0082234
2019-02-20 12:11 git Note Added: 0082238
2019-02-20 18:38 git Note Added: 0082240
2019-02-20 19:44 kgv File Added: interior1_persp_glsl_msaa.png
2019-02-20 19:44 kgv File Added: interior2_persp_glsl_msaa.png
2019-02-20 19:45 kgv File Deleted: interior1_persp_glsl_msaa.png
2019-02-20 19:45 kgv File Deleted: interior2_persp_glsl_msaa.png
2019-02-20 19:45 kgv File Added: interior1_persp_glsl_msaa.png
2019-02-20 19:45 kgv File Added: interior2_persp_glsl_msaa.png
2019-02-20 20:07 kgv Note Added: 0082242
2019-02-20 20:07 kgv Assigned To kgv => bugmaster
2019-02-20 20:07 kgv Status resolved => reviewed
2019-02-20 21:51 git Note Added: 0082243
2019-02-20 22:23 kgv Additional Information Updated
2019-02-20 22:24 kgv Additional Information Updated
2019-02-20 22:26 kgv Additional Information Updated
2019-02-21 17:03 apn Test case number => v3d glsl interior
2019-02-21 17:03 apn Note Added: 0082278
2019-02-21 17:03 apn Status reviewed => tested
2019-02-22 11:07 git Note Added: 0082293
2019-02-22 12:18 kgv Note Added: 0082296
2019-02-23 13:56 apn Changeset attached => occt master 2a332745
2019-02-23 13:56 apn Assigned To bugmaster => apn
2019-02-23 13:56 apn Status tested => verified
2019-02-23 13:56 apn Resolution open => fixed
2019-03-05 13:46 git Note Added: 0082610
2019-03-05 13:46 git Note Added: 0082611
2019-03-05 13:46 git Note Added: 0082612
2019-03-05 13:46 git Note Added: 0082613
2019-03-05 13:46 git Note Added: 0082614
2019-03-05 13:48 git Note Added: 0082657
2019-03-05 13:48 git Note Added: 0082658
2019-03-05 13:48 git Note Added: 0082659
2019-03-05 13:48 git Note Added: 0082660
2019-03-05 13:48 git Note Added: 0082661
2019-03-05 13:48 git Note Added: 0082662
2019-03-05 13:48 git Note Added: 0082663
2019-03-05 13:48 git Note Added: 0082664
2019-03-05 13:48 git Note Added: 0082665
2019-03-05 13:48 git Note Added: 0082666
2021-02-10 11:13 kgv Relationship added parent of 0032124
The file specified in $g_log_destination "/var/log/mantis/bugs/LDAP.log" is not writable.