@@ -22,7 +22,7 @@ def __init__(self):
2222 super ().__init__ ()
2323
2424 @exportRpc (schemas_dict ["register" ]["rpc" ])
25- def register (self , params ):
25+ def registerMesh (self , params ):
2626 print (schemas_dict ["register" ]["rpc" ], params , flush = True )
2727 validate_schema (params , schemas_dict ["register" ])
2828 id = params ["id" ]
@@ -32,7 +32,7 @@ def register(self, params):
3232 filter = {}
3333 mapper = vtk .vtkDataSetMapper ()
3434 mapper .SetInputConnection (reader .GetOutputPort ())
35- super () .register (id , file_name , reader , filter , mapper )
35+ self .register (id , file_name , reader , filter , mapper )
3636 except Exception as e :
3737 print ("error : " , str (e ), flush = True )
3838
@@ -41,84 +41,84 @@ def deregisterMesh(self, params):
4141 print (schemas_dict ["deregister" ]["rpc" ], params , flush = True )
4242 validate_schema (params , schemas_dict ["deregister" ])
4343 id = params ["id" ]
44- super () .deregister (id )
44+ self .deregister (id )
4545
4646 @exportRpc (schemas_dict ["set_visibility" ]["rpc" ])
47- def SetVisibility (self , params ):
47+ def SetMeshVisibility (self , params ):
4848 print (schemas_dict ["set_visibility" ]["rpc" ], params , flush = True )
4949 validate_schema (params , schemas_dict ["set_visibility" ])
5050 id = params ["id" ]
5151 visibility = bool (params ["visibility" ])
52- super () .SetVisibility (id , visibility )
52+ self .SetVisibility (id , visibility )
5353
5454 @exportRpc (schemas_dict ["set_opacity" ]["rpc" ])
55- def SetOpacity (self , params ):
55+ def SetMeshOpacity (self , params ):
5656 print (schemas_dict ["set_opacity" ]["rpc" ], params , flush = True )
5757 validate_schema (params , schemas_dict ["set_opacity" ])
5858 id = params ["id" ]
5959 opacity = float (params ["opacity" ])
60- super () .SetOpacity (id , opacity )
60+ self .SetOpacity (id , opacity )
6161
6262 @exportRpc (schemas_dict ["set_edge_visibility" ]["rpc" ])
63- def setEdgeVisibility (self , params ):
63+ def setMeshEdgeVisibility (self , params ):
6464 print (schemas_dict ["set_edge_visibility" ]["rpc" ], params , flush = True )
6565 validate_schema (params , schemas_dict ["set_edge_visibility" ])
6666 id = params ["id" ]
6767 visibility = bool (params ["visibility" ])
68- super () .SetEdgeVisibility (id , visibility )
68+ self .SetEdgeVisibility (id , visibility )
6969
7070 @exportRpc (schemas_dict ["set_point_visibility" ]["rpc" ])
71- def setPointVisibility (self , params ):
71+ def setMeshPointVisibility (self , params ):
7272 print (schemas_dict ["set_point_visibility" ]["rpc" ], params , flush = True )
7373 validate_schema (params , schemas_dict ["set_point_visibility" ])
7474 id = params ["id" ]
7575 visibility = bool (params ["visibility" ])
76- super () .SetVertexVisibility (id , visibility )
76+ self .SetVertexVisibility (id , visibility )
7777
7878 @exportRpc (schemas_dict ["set_point_size" ]["rpc" ])
79- def setPointSize (self , params ):
79+ def setMeshPointSize (self , params ):
8080 print (schemas_dict ["set_point_size" ]["rpc" ], params , flush = True )
8181 validate_schema (params , schemas_dict ["set_point_size" ])
8282 id = params ["id" ]
8383 size = float (params ["size" ])
84- super () .SetPointSize (id , size )
84+ self .SetPointSize (id , size )
8585
8686 @exportRpc (schemas_dict ["set_color" ]["rpc" ])
87- def setColor (self , params ):
87+ def setMeshColor (self , params ):
8888 print (schemas_dict ["set_color" ]["rpc" ], params , flush = True )
8989 validate_schema (params , schemas_dict ["set_color" ])
9090 id = params ["id" ]
9191 red = params ["red" ]
9292 green = params ["green" ]
9393 blue = params ["blue" ]
94- super () .SetColor (id , red , green , blue )
94+ self .SetColor (id , red , green , blue )
9595
9696 @exportRpc (schemas_dict ["display_vertex_attribute" ]["rpc" ])
9797 def setVertexAttribute (self , params ):
9898 print (schemas_dict ["display_vertex_attribute" ]["rpc" ], params , flush = True )
9999 validate_schema (params , schemas_dict ["display_vertex_attribute" ])
100100 id = params ["id" ]
101101 name = params ["name" ]
102- reader = super () .get_object (id )["reader" ]
102+ reader = self .get_object (id )["reader" ]
103103 points = reader .GetOutput ().GetPointData ()
104104 points .SetActiveScalars (name )
105- mapper = super () .get_object (id )["mapper" ]
105+ mapper = self .get_object (id )["mapper" ]
106106 mapper .ScalarVisibilityOn ()
107107 mapper .SetScalarModeToUsePointData ()
108108 mapper .SetScalarRange (points .GetScalars ().GetRange ())
109- super () .render ()
109+ self .render ()
110110
111111 @exportRpc (schemas_dict ["display_polygon_attribute" ]["rpc" ])
112112 def setPolygonAttribute (self , params ):
113113 print (schemas_dict ["display_polygon_attribute" ]["rpc" ], params , flush = True )
114114 validate_schema (params , schemas_dict ["display_polygon_attribute" ])
115115 id = params ["id" ]
116116 name = params ["name" ]
117- reader = super () .get_object (id )["reader" ]
117+ reader = self .get_object (id )["reader" ]
118118 cells = reader .GetOutput ().GetCellData ()
119119 cells .SetActiveScalars (name )
120- mapper = super () .get_object (id )["mapper" ]
120+ mapper = self .get_object (id )["mapper" ]
121121 mapper .ScalarVisibilityOn ()
122122 mapper .SetScalarModeToUseCellData ()
123123 mapper .SetScalarRange (cells .GetScalars ().GetRange ())
124- super () .render ()
124+ self .render ()
0 commit comments