Open
Description
i have to build a STEP viewer for my project in witch i can see the hierarchical structure of the step file geomertical entities.
For now i can only see the names of the entities with this code:
from OCC.Display.WebGl import x3dom_renderer
from OCC.Core.STEPControl import STEPControl_Reader
from OCC.Extend.DataExchange import read_step_file_with_names_colors
from OCC.Core.Quantity import Quantity_Color, Quantity_TOC_RGB
from OCC.Display.SimpleGui import init_display
step_reader = STEPControl_Reader()
status=step_reader.ReadFile('step/ASY-0039890.stp')
step_reader.TransferRoot(1)
shapes_labels_colors = read_step_file_with_names_colors('step/ASY-0039890.stp')
my_renderer = x3dom_renderer.X3DomRenderer()
for shpt_lbl_color in shapes_labels_colors:
my_renderer.DisplayShape(shpt_lbl_color)
my_renderer.render()
the execution of this code:
Now i want to see the names of the entities in this way:
Can any one help please?