NetworkObject

class compas_rhino.objects.NetworkObject(network, scene=None, name=None, layer=None, visible=True, settings=None)[source]

Bases: compas_rhino.objects._object.BaseObject

Class for representing COMPAS networkes in Rhino.

Parameters
  • network (compas.datastructures.Network) – A network data structure.

  • scene (compas.scenes.Scene, optional) – A scene object.

  • name (str, optional) – The name of the object.

  • layer (str, optional) – The layer for drawing.

  • visible (bool, optional) – Toggle for the visibility of the object.

  • settings (dict, optional) – A dictionary of settings.

Attributes

SETTINGS

anchor

The node of the network that is anchored to the location of the object.

guid_edge

Map between Rhino object GUIDs and network edge identifiers.

guid_edgelabel

Map between Rhino object GUIDs and network edgelabel identifiers.

guid_node

Map between Rhino object GUIDs and network node identifiers.

guid_nodelabel

Map between Rhino object GUIDs and network nodelabel identifiers.

guids

location

compas.geometry.Point: The location of the object.

network

node_xyz

The view coordinates of the mesh object.

rotation

list of float: The rotation angles around the 3 axis of the coordinate system with the origin placed at the location of the object in the scene.

scale

float: A uniform scaling factor for the object in the scene.

Inherited Attributes

artist

id

item

layer

name

scene

Methods

clear

Clear all previously created Rhino objects.

draw

Draw the object representing the network.

modify

Update the attributes of the network.

modify_edges

Update the attributes of the edges.

modify_nodes

Update the attributes of the nodes.

move

Move the entire mesh object to a different location.

move_node

Move a single node of the network object and update the data structure accordingly.

select

Select the object representing the item.

select_edges

Select edges of the network.

select_nodes

Select nodes of the network.

Inherited Methods

build

clear_layer

Clear the layer of the object.

redraw

Redraw the Rhino scene/view.

register

registered_object_types