synfig-core  1.0.3
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Friends | List of all members
synfig::ValueNode Class Reference

Base class for all Value Nodes. More...

#include <valuenode.h>

Inheritance diagram for synfig::ValueNode:
synfig::Node synfig::LinkableValueNode synfig::PlaceholderValueNode synfig::ValueNode_Animated synfig::ValueNode_Const synfig::ValueNode_Add synfig::ValueNode_And synfig::ValueNode_AngleString synfig::ValueNode_Atan2 synfig::ValueNode_BLineCalcTangent synfig::ValueNode_BLineCalcVertex synfig::ValueNode_BLineCalcWidth synfig::ValueNode_BLineRevTangent synfig::ValueNode_Bone synfig::ValueNode_BoneInfluence synfig::ValueNode_BoneLink synfig::ValueNode_BoneWeightPair synfig::ValueNode_Compare synfig::ValueNode_Composite synfig::ValueNode_Cos synfig::ValueNode_Derivative synfig::ValueNode_DotProduct synfig::ValueNode_Duplicate synfig::ValueNode_Dynamic synfig::ValueNode_DynamicList synfig::ValueNode_Exp synfig::ValueNode_GradientColor synfig::ValueNode_GradientRotate synfig::ValueNode_Integer synfig::ValueNode_IntString synfig::ValueNode_Join synfig::ValueNode_Linear synfig::ValueNode_Logarithm synfig::ValueNode_Not synfig::ValueNode_Or synfig::ValueNode_Pow synfig::ValueNode_RadialComposite synfig::ValueNode_Random synfig::ValueNode_Range synfig::ValueNode_Real synfig::ValueNode_RealString synfig::ValueNode_Reciprocal synfig::ValueNode_Reference synfig::ValueNode_Repeat_Gradient synfig::ValueNode_Reverse synfig::ValueNode_Scale synfig::ValueNode_SegCalcTangent synfig::ValueNode_SegCalcVertex synfig::ValueNode_Sine synfig::ValueNode_StaticList synfig::ValueNode_Step synfig::ValueNode_Stripes synfig::ValueNode_Subtract synfig::ValueNode_Switch synfig::ValueNode_TimedSwap synfig::ValueNode_TimeLoop synfig::ValueNode_TimeString synfig::ValueNode_TwoTone synfig::ValueNode_VectorAngle synfig::ValueNode_VectorLength synfig::ValueNode_VectorX synfig::ValueNode_VectorY

Public Types

typedef etl::handle< ValueNodeHandle
typedef etl::loose_handle
< ValueNode
LooseHandle
typedef etl::handle< const
ValueNode
ConstHandle
typedef etl::rhandle< ValueNodeRHandle
- Public Types inherited from synfig::Node
typedef TimePointSet time_set

Public Member Functions

sigc::signal< void > & signal_value_changed ()
 ValueBase Changed.
sigc::signal< void, int * > & signal_children_reordered ()
 Children Reordered.
sigc::signal< void, int > & signal_child_changed ()
 Child Changed.
sigc::signal< void, int > & signal_child_removed ()
 Child Removed.
sigc::signal< void, int > & signal_child_inserted ()
 Child Inserted.
sigc::signal< void > & signal_id_changed ()
 ID Changed.
virtual ~ValueNode ()
virtual ValueBase operator() (Time) const
 Returns the value of the ValueNode at time t.
void set_id (const String &x)
const Stringget_id () const
 Returns the id of the ValueNode.
virtual String get_name () const =0
 Returns the name of the ValueNode type.
virtual String get_local_name () const =0
 Returns the localized name of the ValueNode type.
virtual String get_description (bool show_exported_name=true) const
 Return a full description of the ValueNode and its parentage.
String get_string () const
virtual ValueNode::Handle clone (etl::loose_handle< Canvas > canvas, const GUID &deriv_guid=GUID()) const =0
 Clones a Value Node.
bool is_exported () const
 Returns if the Value Node has an ID (has been exported)
bool is_descendant (ValueNode::Handle value_node_dest)
 Check recursively if is a descendant of the Value Node.
Typeget_type () const
 Returns the type of the ValueNode.
etl::loose_handle< Canvasget_parent_canvas () const
 Returns a handle to the parent canvas, if it has one.
etl::loose_handle< Canvasget_root_canvas () const
 Returns a handle to the parent canvas, if it has one.
etl::loose_handle< Canvasget_non_inline_ancestor_canvas () const
 Returns a handle to the parent canvas, if it has one.
void set_parent_canvas (etl::loose_handle< Canvas > x)
 Sets the parent canvas for the Value Node.
virtual void set_root_canvas (etl::loose_handle< Canvas > x)
 Sets the root canvas parent for the Value Node.
String get_relative_id (etl::loose_handle< const Canvas > x) const
 Returns the relative ID of a Node when accessed form the Canvas.
int replace (etl::handle< ValueNode > x)
virtual Interpolation get_interpolation () const
 Get the default interpolation for Value Nodes.
virtual void set_interpolation (Interpolation)
 Set the default interpolation for Value Nodes.
- Public Member Functions inherited from synfig::Node
sigc::signal< void > & signal_deleted ()
sigc::signal< void > & signal_changed ()
sigc::signal< void, GUID > & signal_guid_changed ()
 GUID Changed.
virtual ~Node ()
void changed ()
const GUIDget_guid () const
 Gets the GUID for this Node.
virtual void set_guid (const GUID &x)
 Sets the GUID for this Node.
int get_time_last_changed () const
 Gets the time when the Node was changed.
void add_child (Node *x)
 Adds the parameter as the child of the current Node.
void remove_child (Node *x)
 Removes the parameter as a child of the current Node.
int parent_count () const
 Returns how many parenst has the current Node.
const time_setget_times () const
 Returns the cached times values for all the children.
RWLockget_rw_lock () const
 Writeme!

Static Public Member Functions

static bool subsys_init ()
 Instantiates the book of ValaueNodes and register all the valid valuenodes on it.
static bool subsys_stop ()
 Deletes the book of ValueNodes.
static void breakpoint ()

Protected Member Functions

 ValueNode (Type &type=type_nil)
void set_type (Type &t)
 Sets the type of the ValueNode.
virtual void on_changed ()
- Protected Member Functions inherited from synfig::Node
 Node ()
void begin_delete ()
virtual void on_guid_changed (GUID guid)
virtual void get_times_vfunc (time_set &set) const =0

Friends

class Layer
class LinkableValueNode

Additional Inherited Members

- Public Attributes inherited from synfig::Node
std::set< Node * > parent_set

Detailed Description

Base class for all Value Nodes.

Member Typedef Documentation

typedef etl::handle<ValueNode> synfig::ValueNode::Handle
typedef etl::loose_handle<ValueNode> synfig::ValueNode::LooseHandle
typedef etl::handle<const ValueNode> synfig::ValueNode::ConstHandle
typedef etl::rhandle<ValueNode> synfig::ValueNode::RHandle

Constructor & Destructor Documentation

ValueNode::ValueNode ( Type type = type_nil)
protected

References value_node_count().

ValueNode::~ValueNode ( )
virtual

Member Function Documentation

bool ValueNode::subsys_init ( )
static
bool ValueNode::subsys_stop ( )
static

Deletes the book of ValueNodes.

References book_.

Referenced by synfig::Main::~Main().

void ValueNode::breakpoint ( )
static
sigc::signal<void>& synfig::ValueNode::signal_value_changed ( )
inline

ValueBase Changed.

sigc::signal<void,int*>& synfig::ValueNode::signal_children_reordered ( )
inline

Children Reordered.

sigc::signal<void,int>& synfig::ValueNode::signal_child_changed ( )
inline

Child Changed.

sigc::signal<void,int>& synfig::ValueNode::signal_child_removed ( )
inline

Child Removed.

sigc::signal<void,int>& synfig::ValueNode::signal_child_inserted ( )
inline

Child Inserted.

sigc::signal<void>& synfig::ValueNode::signal_id_changed ( )
inline

ID Changed.

virtual ValueBase synfig::ValueNode::operator() ( Time  ) const
inlinevirtual

Returns the value of the ValueNode at time t.

Reimplemented in synfig::PlaceholderValueNode, synfig::ValueNode_DynamicList, synfig::ValueNode_Bone_Root, synfig::ValueNode_Dynamic, synfig::ValueNode_BLine, synfig::ValueNode_StaticList, synfig::ValueNode_WPList, synfig::ValueNode_Derivative, synfig::ValueNode_Repeat_Gradient, synfig::ValueNode_Bone, synfig::ValueNode_DIList, synfig::ValueNode_Stripes, synfig::ValueNode_TimedSwap, synfig::ValueNode_Scale, synfig::ValueNode_BoneInfluence, synfig::ValueNode_GradientRotate, synfig::ValueNode_Random, synfig::ValueNode_Switch, synfig::ValueNode_BLineCalcTangent, synfig::ValueNode_Add, synfig::ValueNode_Subtract, synfig::ValueNode_BLineCalcWidth, synfig::ValueNode_Reference, synfig::ValueNode_TwoTone, synfig::ValueNode_BoneLink, synfig::ValueNode_Compare, synfig::ValueNode_Composite, synfig::ValueNode_Join, synfig::ValueNode_RealString, synfig::ValueNode_AngleString, synfig::ValueNode_Duplicate, synfig::ValueNode_GradientColor, synfig::ValueNode_IntString, synfig::ValueNode_Pow, synfig::ValueNode_SegCalcTangent, synfig::ValueNode_Step, synfig::ValueNode_TimeLoop, synfig::ValueNode_Atan2, synfig::ValueNode_BLineCalcVertex, synfig::ValueNode_BLineRevTangent, synfig::ValueNode_BoneWeightPair, synfig::ValueNode_Cos, synfig::ValueNode_DotProduct, synfig::ValueNode_Linear, synfig::ValueNode_Reverse, synfig::ValueNode_Sine, synfig::ValueNode_Const, synfig::ValueNode_Exp, synfig::ValueNode_Logarithm, synfig::ValueNode_RadialComposite, synfig::ValueNode_Range, synfig::ValueNode_Real, synfig::ValueNode_Reciprocal, synfig::ValueNode_TimeString, synfig::ValueNode_VectorAngle, synfig::ValueNode_VectorLength, synfig::ValueNode_VectorX, synfig::ValueNode_VectorY, synfig::ValueNode_Integer, synfig::ValueNode_Or, synfig::ValueNode_SegCalcVertex, synfig::ValueNode_And, synfig::ValueNode_Average, synfig::ValueNode_Not, and synfig::ValueNode_WeightedAverage.

void ValueNode::set_id ( const String x)

Sets the id of the ValueNode

const String& synfig::ValueNode::get_id ( ) const
inline

Returns the id of the ValueNode.

The ID is used for keeping track of a specific instance of a ValueNode.

Referenced by get_description(), synfig::LinkableValueNode::get_description(), get_relative_id(), and is_exported().

virtual String synfig::ValueNode::get_name ( ) const
pure virtual

Returns the name of the ValueNode type.

Implemented in synfig::PlaceholderValueNode, synfig::ValueNode_DynamicList, synfig::ValueNode_Bone_Root, synfig::ValueNode_Animated, synfig::ValueNode_Dynamic, synfig::ValueNode_BLine, synfig::ValueNode_StaticList, synfig::ValueNode_WPList, synfig::ValueNode_Bone, synfig::ValueNode_Derivative, synfig::ValueNode_Scale, synfig::ValueNode_Repeat_Gradient, synfig::ValueNode_DIList, synfig::ValueNode_Stripes, synfig::ValueNode_TimedSwap, synfig::ValueNode_BoneInfluence, synfig::ValueNode_Random, synfig::ValueNode_Const, synfig::ValueNode_Switch, synfig::ValueNode_BLineCalcTangent, synfig::ValueNode_GradientRotate, synfig::ValueNode_Duplicate, synfig::ValueNode_Add, synfig::ValueNode_BLineCalcWidth, synfig::ValueNode_Reference, synfig::ValueNode_Subtract, synfig::ValueNode_BoneLink, synfig::ValueNode_Compare, synfig::ValueNode_Join, synfig::ValueNode_RealString, synfig::ValueNode_GradientColor, synfig::ValueNode_IntString, synfig::ValueNode_Pow, synfig::ValueNode_SegCalcTangent, synfig::ValueNode_Step, synfig::ValueNode_TimeLoop, synfig::ValueNode_TwoTone, synfig::ValueNode_Atan2, synfig::ValueNode_BLineCalcVertex, synfig::ValueNode_BLineRevTangent, synfig::ValueNode_BoneWeightPair, synfig::ValueNode_Cos, synfig::ValueNode_DotProduct, synfig::ValueNode_Linear, synfig::ValueNode_Reverse, synfig::ValueNode_Sine, synfig::ValueNode_AngleString, synfig::ValueNode_Composite, synfig::ValueNode_Exp, synfig::ValueNode_Logarithm, synfig::ValueNode_Range, synfig::ValueNode_Real, synfig::ValueNode_Reciprocal, synfig::ValueNode_TimeString, synfig::ValueNode_VectorAngle, synfig::ValueNode_VectorLength, synfig::ValueNode_VectorX, synfig::ValueNode_VectorY, synfig::ValueNode_Integer, synfig::ValueNode_Or, synfig::ValueNode_SegCalcVertex, synfig::ValueNode_Not, synfig::ValueNode_RadialComposite, synfig::ValueNode_And, synfig::ValueNode_Average, synfig::ValueNode_WeightedAverage, and synfig::ValueNode_Greyed.

virtual String synfig::ValueNode::get_local_name ( ) const
pure virtual

Returns the localized name of the ValueNode type.

Implemented in synfig::PlaceholderValueNode, synfig::ValueNode_DynamicList, synfig::ValueNode_Bone_Root, synfig::ValueNode_Animated, synfig::ValueNode_Dynamic, synfig::ValueNode_BLine, synfig::ValueNode_StaticList, synfig::ValueNode_WPList, synfig::ValueNode_Bone, synfig::ValueNode_Derivative, synfig::ValueNode_Scale, synfig::ValueNode_Repeat_Gradient, synfig::ValueNode_DIList, synfig::ValueNode_Stripes, synfig::ValueNode_BoneInfluence, synfig::ValueNode_TimedSwap, synfig::ValueNode_Switch, synfig::ValueNode_Random, synfig::ValueNode_Const, synfig::ValueNode_BLineCalcTangent, synfig::ValueNode_GradientRotate, synfig::ValueNode_Duplicate, synfig::ValueNode_Reference, synfig::ValueNode_Add, synfig::ValueNode_BLineCalcWidth, synfig::ValueNode_Subtract, synfig::ValueNode_BoneLink, synfig::ValueNode_Compare, synfig::ValueNode_Join, synfig::ValueNode_RealString, synfig::ValueNode_GradientColor, synfig::ValueNode_IntString, synfig::ValueNode_Pow, synfig::ValueNode_SegCalcTangent, synfig::ValueNode_Step, synfig::ValueNode_TimeLoop, synfig::ValueNode_TwoTone, synfig::ValueNode_Atan2, synfig::ValueNode_BLineCalcVertex, synfig::ValueNode_BLineRevTangent, synfig::ValueNode_BoneWeightPair, synfig::ValueNode_Cos, synfig::ValueNode_DotProduct, synfig::ValueNode_Linear, synfig::ValueNode_Reverse, synfig::ValueNode_Sine, synfig::ValueNode_AngleString, synfig::ValueNode_Composite, synfig::ValueNode_Exp, synfig::ValueNode_Logarithm, synfig::ValueNode_Range, synfig::ValueNode_Real, synfig::ValueNode_Reciprocal, synfig::ValueNode_TimeString, synfig::ValueNode_VectorAngle, synfig::ValueNode_VectorLength, synfig::ValueNode_VectorX, synfig::ValueNode_VectorY, synfig::ValueNode_Integer, synfig::ValueNode_Or, synfig::ValueNode_SegCalcVertex, synfig::ValueNode_Not, synfig::ValueNode_RadialComposite, synfig::ValueNode_And, synfig::ValueNode_Average, synfig::ValueNode_WeightedAverage, and synfig::ValueNode_Greyed.

Referenced by synfig::LinkableValueNode::get_description().

String ValueNode::get_description ( bool  show_exported_name = true) const
virtual

Return a full description of the ValueNode and its parentage.

Reimplemented in synfig::LinkableValueNode.

References _, get_id(), and is_exported().

Referenced by get_string().

String ValueNode::get_string ( void  ) const
virtual
virtual ValueNode::Handle synfig::ValueNode::clone ( etl::loose_handle< Canvas canvas,
const GUID deriv_guid = GUID() 
) const
pure virtual
bool synfig::ValueNode::is_exported ( ) const
inline

Returns if the Value Node has an ID (has been exported)

References get_id().

Referenced by get_description(), synfig::LinkableValueNode::get_description(), and get_relative_id().

bool ValueNode::is_descendant ( ValueNode::Handle  value_node_dest)

Check recursively if is a descendant of the Value Node.

loop through the parents of each node in current_nodes

Type& synfig::ValueNode::get_type ( ) const
inline

Returns the type of the ValueNode.

Referenced by synfig::ValueNode_WeightedAverage::create(), synfig::ValueNode_GradientRotate::create(), synfig::ValueNode_Stripes::create(), synfig::ValueNode_Repeat_Gradient::create(), synfig::ValueNode_Greyed::create_new(), synfig::ValueNode_Add::create_new(), synfig::ValueNode_Subtract::create_new(), synfig::ValueNode_Average::create_new(), synfig::ValueNode_WeightedAverage::create_new(), synfig::ValueNode_And::create_new(), synfig::ValueNode_Not::create_new(), synfig::ValueNode_RadialComposite::create_new(), synfig::ValueNode_AngleString::create_new(), synfig::ValueNode_Or::create_new(), synfig::ValueNode_VectorY::create_new(), synfig::ValueNode_Reciprocal::create_new(), synfig::ValueNode_Exp::create_new(), synfig::ValueNode_TwoTone::create_new(), synfig::ValueNode_VectorAngle::create_new(), synfig::ValueNode_TimeString::create_new(), synfig::ValueNode_VectorX::create_new(), synfig::ValueNode_VectorLength::create_new(), synfig::ValueNode_Logarithm::create_new(), synfig::ValueNode_Reverse::create_new(), synfig::ValueNode_BoneWeightPair::create_new(), synfig::ValueNode_Sine::create_new(), synfig::ValueNode_Composite::create_new(), synfig::ValueNode_Linear::create_new(), synfig::ValueNode_Atan2::create_new(), synfig::ValueNode_Cos::create_new(), synfig::ValueNode_DotProduct::create_new(), synfig::ValueNode_GradientColor::create_new(), synfig::ValueNode_Step::create_new(), synfig::ValueNode_BLineRevTangent::create_new(), synfig::ValueNode_IntString::create_new(), synfig::ValueNode_TimeLoop::create_new(), synfig::ValueNode_Pow::create_new(), synfig::ValueNode_BoneLink::create_new(), synfig::ValueNode_Integer::create_new(), synfig::ValueNode_Join::create_new(), synfig::ValueNode_Real::create_new(), synfig::ValueNode_RealString::create_new(), synfig::ValueNode_Compare::create_new(), synfig::ValueNode_Reference::create_new(), synfig::ValueNode_Range::create_new(), synfig::ValueNode_Duplicate::create_new(), synfig::ValueNode_BLineCalcTangent::create_new(), synfig::ValueNode_Switch::create_new(), synfig::ValueNode_TimedSwap::create_new(), synfig::ValueNode_BoneInfluence::create_new(), synfig::ValueNode_Random::create_new(), synfig::ValueNode_Scale::create_new(), synfig::ValueNode_Derivative::create_new(), synfig::ValueNode_Bone::create_new(), synfig::ValueNode_Dynamic::create_new(), synfig::ValueNode_RadialComposite::get_children_vocab_vfunc(), synfig::ValueNode_Composite::get_children_vocab_vfunc(), synfig::ValueNode_Linear::get_children_vocab_vfunc(), synfig::ValueNode_RadialComposite::get_link_index_from_name(), synfig::ValueNode_Composite::get_link_index_from_name(), synfig::ValueNode_Average::operator()(), synfig::ValueNode_WeightedAverage::operator()(), synfig::ValueNode_Integer::operator()(), synfig::ValueNode_TimeString::operator()(), synfig::ValueNode_Real::operator()(), synfig::ValueNode_Linear::operator()(), synfig::ValueNode_DotProduct::operator()(), synfig::ValueNode_AngleString::operator()(), synfig::ValueNode_IntString::operator()(), synfig::ValueNode_Step::operator()(), synfig::ValueNode_RealString::operator()(), synfig::ValueNode_Join::operator()(), synfig::ValueNode_BLineCalcTangent::operator()(), synfig::ValueNode_Random::operator()(), synfig::ValueNode_Derivative::operator()(), synfig::ValueNode_RadialComposite::set_link_vfunc(), synfig::ValueNode_Subtract::set_link_vfunc(), synfig::ValueNode_Add::set_link_vfunc(), synfig::ValueNode_TimedSwap::set_link_vfunc(), synfig::ValueNode_Composite::set_link_vfunc(), synfig::ValueNode_BLineRevTangent::set_link_vfunc(), synfig::ValueNode_Repeat_Gradient::set_link_vfunc(), synfig::ValueNode_Linear::set_link_vfunc(), synfig::ValueNode_Reverse::set_link_vfunc(), synfig::ValueNode_TimeLoop::set_link_vfunc(), synfig::ValueNode_Step::set_link_vfunc(), synfig::ValueNode_Reference::set_link_vfunc(), synfig::ValueNode_Range::set_link_vfunc(), synfig::ValueNode_BoneLink::set_link_vfunc(), synfig::ValueNode_Switch::set_link_vfunc(), synfig::ValueNode_BoneInfluence::set_link_vfunc(), synfig::ValueNode_Random::set_link_vfunc(), synfig::ValueNode_Scale::set_link_vfunc(), synfig::ValueNode_Derivative::set_link_vfunc(), synfig::ValueNode_Dynamic::set_link_vfunc(), synfig::ValueNode_Subtract::ValueNode_Subtract(), and synfig::ValueNode_Const::~ValueNode_Const().

etl::loose_handle< Canvas > ValueNode::get_parent_canvas ( ) const
etl::loose_handle< Canvas > ValueNode::get_root_canvas ( ) const
etl::loose_handle< Canvas > ValueNode::get_non_inline_ancestor_canvas ( ) const

Returns a handle to the parent canvas, if it has one.

References get_parent_canvas().

Referenced by synfig::ValueNode_DynamicList::erase().

void ValueNode::set_parent_canvas ( etl::loose_handle< Canvas x)
void ValueNode::set_root_canvas ( etl::loose_handle< Canvas x)
virtual
String ValueNode::get_relative_id ( etl::loose_handle< const Canvas x) const

Returns the relative ID of a Node when accessed form the Canvas.

References get_id(), and is_exported().

int ValueNode::replace ( etl::handle< ValueNode x)

Replaces the Value Node with a given one. It look up all its parents remove it self from them and adds the given Value Node Notice that it is called twice and the second time it uses a replaceable handle to the Node

See Also
etl::rhandle

References synfig::Node::add_child(), synfig::Node::parent_set, and synfig::Node::remove_child().

virtual Interpolation synfig::ValueNode::get_interpolation ( ) const
inlinevirtual

Get the default interpolation for Value Nodes.

Reimplemented in synfig::ValueNode_Animated, and synfig::ValueNode_Const.

References synfig::INTERPOLATION_UNDEFINED.

virtual void synfig::ValueNode::set_interpolation ( Interpolation  )
inlinevirtual

Set the default interpolation for Value Nodes.

Reimplemented in synfig::ValueNode_Animated, and synfig::ValueNode_Const.

void synfig::ValueNode::set_type ( Type t)
inlineprotected

Sets the type of the ValueNode.

Reimplemented in synfig::LinkableValueNode, and synfig::ValueNode_Animated.

void ValueNode::on_changed ( )
protectedvirtual

Used when the node has changed. Makes changed the parent too. To be overloaded by the derivative classes. Emits a signal where the the GUI can be connected to.

Reimplemented from synfig::Node.

Reimplemented in synfig::ValueNode_Bone.

References get_parent_canvas(), and get_root_canvas().

Friends And Related Function Documentation

friend class Layer
friend
friend class LinkableValueNode
friend

The documentation for this class was generated from the following files: