GvValue Class Reference Graph View

#include <c4d_graphview.h>

详细描述

Calculation interface for a port main ID. Used by the convenience functions, for example GvBuildValuesTable() .

注意
Cannot be instantiated. Use GvNode::AllocCalculationHandler() to allocate it and GvNode::FreeCalculationHandler() to destroy it.

公共成员函数

Bool   Calculate ( GvNode *node, GvPortIO io, GvRun *r, GvCalc *c, Int32 index=0, BaseTime *time=nullptr)
Bool   IsConnected ( Int32 index)
Bool   IsPort (void)
Int32   NrOfPorts (void)
GvValueID   GetValueID (void)
Int32   GetMainID ()
GvPort GetPort ( Int32 index=0)

私有成员函数

  GvValue ()
  ~GvValue ()

构造函数 & 析构函数文档编制

◆  GvValue()

GvValue () private

◆  ~GvValue()

~ GvValue () private

成员函数文档编制

◆  Calculate()

Bool Calculate ( GvNode node ,
GvPortIO   io ,
GvRun r ,
GvCalc c ,
Int32   index = 0 ,
BaseTime time = nullptr  
)

Calculates all ports of the value. This is the recommended method for calculating ports. After a port has been calculated you can get the value with the various functions in GvPort .

注意
This function is not equivalent to GvPort::Calculate() .
参数
[in] node The node that the ports of this value belongs to. The caller owns the pointed node.
[in] io Currently not used.
[in] r The run helper. The caller owns the pointed run helper.
[in] c The calculation helper. The caller owns the pointed calculation helper.
[in] index The port index or GV_MULTIPLE_PORTS to calculate all ports: 0 <= index < NrOfPorts()
[in] time If not nullptr animation tracks of the node are evaluated before the calculation.
返回
true if the value was calculated, otherwise false .

◆  IsConnected()

Bool IsConnected ( Int32   index )

Checks if any port of the value is connected. This is equivalent to a || over all GetPort(index)->GvPort::IsIncomingConnected() .

参数
[in] index The port index: 0 <= index < NrOfPorts()
返回
true if the port is connected, otherwise false .

◆  IsPort()

Bool IsPort ( void  )

Checks if there are any ports in the value.

返回
true if if NrOfPorts() > 0, otherwise false .

◆  NrOfPorts()

Int32 NrOfPorts ( void  )

The number of ports in this value.

返回
The port count.

◆  GetValueID()

GvValueID GetValueID ( void  )

The value ID of the managed ports. For all 0 <= index < NrOfPorts() this is equal to GetPort(index)->GvPort::GetValueType GetValueType() . (Well defined since all ports are of the same type in a GvValue .)

返回
The value ID.

◆  GetMainID()

Int32 GetMainID ( )

The main ID of the managed ports. For all 0 <= index < NrOfPorts() this is equal to GetPort(index)->GvPort::GetMainID GetMainID() . (Well defined since all ports are of the same type in a GvValue .)

返回
The main ID.

◆  GetPort()

GvPort * GetPort ( Int32   index = 0 )

Retrieves a port by index.

参数
[in] index The port index: 0 <= index < NrOfPorts()
返回
The retrieved port. The node owns the pointed port.