From eea55df528a9767568eb8c1f5dc1b9e315941250 Mon Sep 17 00:00:00 2001 From: kgv Date: Fri, 6 Feb 2015 18:15:48 +0300 Subject: [PATCH] 0025802: Adopt test cases bugs vis bug10781 and bug23227 for Intel graphics driver Test case bugs/vis/bug10781 - use smaller line width in test case (some Intel OpenGL drivers support only 7 pixels-width lines). Test case bugs/vis/bug23227 - just check triangles count in feedback buffer is not 0. --- tests/bugs/vis/bug10781 | 28 ++++++++++++++++------------ tests/bugs/vis/bug23227 | 3 ++- 2 files changed, 18 insertions(+), 13 deletions(-) diff --git a/tests/bugs/vis/bug10781 b/tests/bugs/vis/bug10781 index 95a47617aa..a9a876122b 100755 --- a/tests/bugs/vis/bug10781 +++ b/tests/bugs/vis/bug10781 @@ -1,29 +1,33 @@ puts "============" puts "OCC10781" +puts "MeshVS is not sensitive to width of edges" puts "============" puts "" -####################################################################### -# MeshVS is not sensitive to width of edges -####################################################################### set BugNumber OCC10781 pload XDE -vinit +vinit View1 +vclear +vaxo meshfromstl m [locate_data_file OMF6391_box.stl] -set x_coord 210 -set y_coord 280 +set aCoordX 206 +set aCoordY 280 -vmoveto $x_coord $y_coord +vmoveto $aCoordX $aCoordY -checkcolor $x_coord $y_coord 0 0 0 +set aColor1px [vreadpixel $aCoordX $aCoordY rgb name] +if { "$aColor1px" != "BLACK" } { + puts "Error: BLACK color is expected at pixel ${aCoordX}x${aCoordY}" +} -mesh_edge_width m 20 -puts "\nSet big mesh edge width" - -checkcolor $x_coord $y_coord 1 1 0 +mesh_edge_width m 6 +set aColor5px [vreadpixel $aCoordX $aCoordY rgb name] +if { "$aColor5px" == "BLACK" } { + puts "Error: YELLOW color is expected at pixel ${aCoordX}x${aCoordY}" +} set only_screen 1 diff --git a/tests/bugs/vis/bug23227 b/tests/bugs/vis/bug23227 index efa6a41190..38210b0922 100755 --- a/tests/bugs/vis/bug23227 +++ b/tests/bugs/vis/bug23227 @@ -9,6 +9,7 @@ set BugNumber OCC23227 box b 1 2 3 vinit View1 vclear +vaxo vdisplay b vsetdispmode 1 vfit @@ -29,7 +30,7 @@ if { ${llength_vfeedback1} < 36 || ${llength_vfeedback2} < 36 || ${IndexTriangle } else { set Triangles1 [lindex ${vfeedback1} ${IndexTriangles1}+1] set Triangles2 [lindex ${vfeedback2} ${IndexTriangles1}+1] - if { ${Triangles1} == 6 && ${Triangles2} == 0 } { + if { ${Triangles1} != 0 && ${Triangles2} == 0 } { puts "OK ${BugNumber}" } else { puts "Faulty ${BugNumber}"