Skip to content

Commit

Permalink
Testing - Update tests with direct VIS loading #148
Browse files Browse the repository at this point in the history
XShow and XDisplay XDE require VISUALIZATION for correct work.
In some scenario DRAWEXE can generate a duplicates of the internal static singletons.
This means each dynamic library will have their own instance of the static singleton.
Update all direct library loading to use the XDE plugin mechanism.
This will ensure that the XDE plugin is loaded only once and that the correct instance is used.
Originally issue is reproduced only Linux with dlopen with "RTLD_LAZY".
Can be resolved additionally adding "RTLD_LAZY | RTLD_GLOBAL" for dlopen
  • Loading branch information
dpasukhi committed Nov 5, 2024
1 parent ea86bfe commit 05ec497
Show file tree
Hide file tree
Showing 16 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion tests/de_mesh/gltf_lateload/begin
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
catch { Close D }
2 changes: 1 addition & 1 deletion tests/de_mesh/gltf_read/begin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
# PBR requires OpenGL 3.0+ on macOS
if { $::tcl_platform(os) == "Darwin" } { vcaps -core }
2 changes: 1 addition & 1 deletion tests/de_mesh/gltf_write/begin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
# PBR requires OpenGL 3.0+ on macOS
if { $::tcl_platform(os) == "Darwin" } { vcaps -core }
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_read/begin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
# PBR requires OpenGL 3.0+ on macOS
if { $::tcl_platform(os) == "Darwin" } { vcaps -core }
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_write/as1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0029303: Data Exchange - add RWObj_CafWriter tool for wavefront OBJ file"
puts "Write as1 STEP model into OBJ file"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
Close D1 -silent
ReadStep D1 [locate_data_file as1-oc-214-mat.stp]
Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_write/ball
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0029303: Data Exchange - add RWObj_CafWriter tool for wavefront OBJ file"
puts "Write B-Rep model into OBJ file"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent

restore [locate_data_file Ball.brep] b
Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_write/lantern
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0029303: Data Exchange - add RWObj_CafWriter tool for wavefront OBJ file"
puts "Write textured lantern glTF model into OBJ file"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
Close D1 -silent
ReadGltf D1 [locate_data_file bug30691_Lantern.glb]
Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_write/mustang
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0029303: Data Exchange - add RWObj_CafWriter tool for wavefront OBJ file"
puts "Write textured plane OBJ model into OBJ file"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
Close D1 -silent

Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/obj_write/ship_boat
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0029303: Data Exchange - add RWObj_CafWriter tool for wavefront OBJ file"
puts "Write textured boat OBJ model into OBJ file"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING
Close D -silent
Close D1 -silent
ReadObj D1 [locate_data_file ship_boat.obj]
Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/step_read/begin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pload XDE OCAF MODELING
pload VISUALIZATION XDE OCAF MODELING

# enable reading/writing tessellated STEP geometry
param write.step.schema AP242DIS
Expand Down
2 changes: 1 addition & 1 deletion tests/de_mesh/step_write/begin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pload XDE OCAF MODELING
pload VISUALIZATION XDE OCAF MODELING

# enable reading/writing tessellated STEP geometry
param write.step.schema AP242DIS
Expand Down
1 change: 1 addition & 0 deletions tests/de_mesh/vrml_read/begin
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# File: begin

pload VISUALIZATION
pload XDE
pload OCAF
pload TOPTEST
2 changes: 1 addition & 1 deletion tests/v3d/bugs/bug23123
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "OCC23123: Bug/Regression in visualization of XDE documents in shaded mode"
puts "============"
puts ""

pload XDE VISUALIZATION
pload VISUALIZATION XDE

ReadStep D [locate_data_file OCC23123-test.step]
XShow D
Expand Down
2 changes: 1 addition & 1 deletion tests/v3d/bugs/bug23407_1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "CR23407: Draw face outlines for XDE objects"
puts "============"
puts ""

pload XDEDRAW VISUALIZATION STEP
pload VISUALIZATION XDEDRAW STEP

XNewDoc Doc1
ReadStep Doc1 [locate_data_file screw.step]
Expand Down
2 changes: 1 addition & 1 deletion tests/v3d/materials/bug27818_2
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ puts ""
# test change of highlight and selection properties for particular objects
####################################################################################

pload QAcommands VISUALIZATION
pload VISUALIZATION QAcommands

vinit View1
OCC27818
Expand Down
2 changes: 1 addition & 1 deletion tests/v3d/materials/materials
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ puts "0030930: Draw Harness, ViewerTest - add commands vlistcolors and vlistmate
puts "Generate a table of predefined Materials (Graphic3d_NameOfMaterial enumeration)"
puts "========"

pload XDE OCAF MODELING VISUALIZATION
pload VISUALIZATION XDE OCAF MODELING

Close D -silent
vclear
Expand Down

0 comments on commit 05ec497

Please sign in to comment.