# ROOT CELL 11 htg.InitializeNonOrientedCursor(cursor, 11, True) cursor.SetGlobalIndexStart(offsetIndex) idx = cursor.GetGlobalNodeIndex() scalarArray.InsertTuple1(idx, 12) print('#',scalarArray.GetNumberOfTuples()) print('DataRange: ',scalarArray.GetRange()) isFilter = False # Axis reflection reflection = None if True: print('With AxisReflection Filter (HTG)') reflection = vtk.vtkHyperTreeGridAxisReflection() if isFilter: reflection.SetInputConnection(htg.GetOutputPort()) else: reflection.SetInputData(htg) reflection.SetPlaneToY() reflection.SetCenter(0) isFilter = True else: print('No AxisReflection Filter (HTG)') reflection = htg # Geometries geometry = vtk.vtkHyperTreeGridGeometry() if isFilter: geometry.SetInputConnection(reflection.GetOutputPort())
# ROOT CELL 11 htg.InitializeNonOrientedCursor(cursor, 11, True) cursor.SetGlobalIndexStart(offsetIndex) idx = cursor.GetGlobalNodeIndex() scalarArray.InsertTuple1(idx, 12) print('#', scalarArray.GetNumberOfTuples()) print('DataRange: ', scalarArray.GetRange()) isFilter = False # Axis reflection reflection = None if True: print('With AxisReflection Filter (HTG)') reflection = vtk.vtkHyperTreeGridAxisReflection() if isFilter: reflection.SetInputConnection(htg.GetOutputPort()) else: reflection.SetInputData(htg) reflection.SetPlaneToZ() reflection.SetCenter(0) isFilter = True else: print('No AxisReflection Filter (HTG)') reflection = htg # Geometries geometry = vtk.vtkHyperTreeGridGeometry() if isFilter: geometry.SetInputConnection(reflection.GetOutputPort())