InstantTerra API Logo

Contents

  • Python API documentation
    • Getting started
      • Installing Python
        • Recommended versions
        • Download
        • Setup
        • Verification
      • First steps in Instant Terra Python API
        • Opening the Python command prompt
        • Testing the API
    • User guide
      • Creating an instance of InstantTerra API
        • What is an “instance” ?
        • Opening an instance
        • Closing an instance
      • Managing a project
        • What is a “project” ?
        • Creating a new project or a project “by default”
        • Saving a project
        • Opening a project
        • Closing a project
      • Graph manipulation
        • What is the project’s “graph”?
        • Retrieving the number of nodes in the graph
        • Retrieving all nodes in the graph
        • Adding a node on the graph
        • Adding a node on the graph next to another one
        • Removing a node from the graph
        • Adding a link between two nodes
        • Adding a link between two nodes using the connector name
        • Removing a link
      • Accessing node data
        • What is a graph “node”?
        • Changing a node name
        • Changing a node comment
        • Retrieving the node type
        • Retrieving the parameters’ list
        • Determining if a parameter exists
        • Retrieving or setting a parameter value
      • Exporting the results
        • Exporting all
      • Example
        • Creating an image series of an animated terrain
    • API reference
      • Package wysilab
        • Class InstantTerra
        • Class Project
        • Class Graph
        • Class Node
        • Class Link
        • Class NodeModel
        • Class Connector
        • Enum ApiNodeType
  • C# API documentation
    • Getting started
      • First steps in Instant Terra C# API
        • Create a new C# project in Visual Studio
        • Add the API reference
        • Testing the API
    • User guide
      • Creating an instance of InstantTerra C# API
        • What is an “instance” ?
        • Opening an instance
        • Closing an instance
      • Managing a project
        • What is a “project” ?
        • Creating a new project or a project “by default”
        • Saving a project
        • Opening a project
        • Closing a project
      • Graph manipulation
        • What is the project’s “graph”?
        • Retrieving the number of nodes in the graph
        • Retrieving all nodes in the graph
        • Adding a node on the graph
        • Adding a node on the graph next to another one
        • Removing a node from the graph
        • Adding a link wetween two nodes
        • Adding a link between two nodes using the connector name
        • Removing a link
      • Accessing node data
        • What is a graph “node”?
        • Changing a node name
        • Changing a node comment
        • Retrieving the node type
        • Retrieving the parameters’ list
        • Determining if a parameter exists
        • Retrieving or setting a parameter value
      • Exporting the results
        • Exporting all
      • Example
        • Creating an image series of an animated terrain
    • API reference
      • Namespace InstantTerraApi
        • Class InstantTerra
        • Class Project
        • Class Graph
        • Class Node
        • Class Link
        • Class NodeModel
        • Class Connector
        • Enum ApiNodeType
  • C++ API documentation
    • User’s guide
      • Create an Instant Terra C++ API instance
        • What is an “instance” ?
        • Open and close an instance
      • Managing your projects
        • What is a “projet” ?
        • Creating a new project or a project “by default”
        • Saving a project
        • Opening a project
        • Closing a project
      • Graph manipulation
        • What is the project’s “graph”?
        • Retrieving the number of nodes in the graph
        • Getting a node from the graph with its index
      • Accessing node data
        • What is a graph “node”?
        • Getting the node name
        • Getting the node comment
        • Getting the node model
        • Getting the parameters count
        • Determining if a parameter exists
        • Retrieving the parameter name
        • Retrieving the parameter value
        • Getting the node connector count
        • Retrieving the node connector
        • Retrieving node data
      • Node connectors and data
        • What is a node “connector”?
        • Getting the connector name
        • Getting the connector mode
        • Getting the connector type
        • What is a node “Data”?
        • Getting the data type
        • Getting grid width and height
        • Getting the float content of a terrain or a mask
      • Custom memory allocator & error handler
        • Custom memory allocator
        • Custom error handler
    • API reference
      • Namespace InstantTerraApi
        • Class MemoryAllocator
        • Class Error
        • Class ErrorHandler
        • Class InstantTerra
        • Class Project
        • Class Graph
        • Class Node
        • Class NodeModel
        • Class Connector
        • Class Data
        • Enum ConnectorMode
        • Enum ConnectorType
        • Enum DataType
        • Enum ErrorCode
InstantTerra API
  • Docs »
  • Python API documentation »
  • API reference »
  • Package wysilab »
  • Class Link

Class Link¶

class link.Link¶

This class represents a link between two nodes.

>>> from wysilab import InstantTerra
>>> it = InstantTerra()
>>> my_node = it.project.graph.get_all_nodes()[0]  # Get the first node
>>> link = it.project.graph.get_node_links(my_node)[0] # Get the first link of the node "my_node"
class link.LinkType¶

This enum represents the type of a node connector.

  • Terrain

  • Mask

  • Value

  • ColorRamp

  • ColorMap

  • VectorMap

  • Other

Link.start_node¶
Type

Node (Nodes)

Node at the start of the link.

>>> print(my_link.start_node)
Perlin noise
Link.start_connector_type¶
Type

ConnectorType

Connector type at the start of the link.

>>> print(my_link.start_connector_type)
<ConnectorType.Terrain: 0>
Link.start_connector_mode¶
Type

ConnectorMode

Connector mode at the start of the link.

>>> print(my_link.start_connector_mode)
<ConnectorMode.Output: 2>
Link.end_node¶
Type

Node (Nodes)

Node at the end of the link.

>>> print(my_link.end_node)
Apply curve
Link.end_connector_type¶
Type

ConnectorType

Connector type at the end of the link.

>>> print(my_link.end_connector_type)
<ConnectorType.Terrain: 0>
Link.end_connector_mode¶
Type

ConnectorMode

Connector mode at the end of the link.

>>> print(my_link.start_connector_mode)
<ConnectorMode.MandatoryInput: 0>
Link.type¶
Type

LinkType

Type of the link.

>>> print(my_link.type)
<LinkType.Terrain: 0>
Next Previous

© Copyright 2019, Wysilab

Built with Sphinx using a theme provided by Read the Docs.