Lumiera  0.pre.03
»edit your freedom«
LocatingPin Class Reference

#include "steam/mobject/session/locatingpin.hpp"

Description

Positioning specification, possibly chained to further specifications.

The base class LocatingPin is a "no-op" specification which doesn't constrain the possible locations and thus can be embedded into pristine Placement by default. The Functor operators provide a way to add concrete positioning specifications, thereby defining the position of the MObject to be placed.

Note
to the implementer of subclasses: LocatingPins are copyable and need to handle cloning (incl the chain)

Definition at line 97 of file locatingpin.hpp.

Public Member Functions

 LocatingPin (const LocatingPin &)
 it's OK to copy a LocainngPin, causing duplication of any chained lPins
 
virtual LocatingPinclone () const
 
bool isOverdetermined () const
 
FixedLocationoperator() (Time start, Fork track=0)
 
RelativeLocationoperator() (PlacementRef< MObject > &refObj, Offset const &offset=Offset(Time::ZERO))
 
LocatingPinoperator= (const LocatingPin &)
 
const SolutionData resolve () const
 implementing the core Placement functionality. More...
 

Classes

struct  LocatingSolution
 

Friends

bool operator== (LocatingPin const &, LocatingPin const &)
 check for equivalent definition of a complete locating chain
 

Protected Types

typedef TimeFork
 
typedef lib::time::Offset Offset
 
typedef std::shared_ptr< asset::PipePipe
 
typedef std::pair< Time, PipeSolutionData
 
typedef lib::time::Time Time
 
typedef lib::time::TimeVar TimeVar
 

Protected Member Functions

LocatingPinaddChain (LocatingPin *)
 
virtual int getPrioLevel () const
 order to consider when resolving. More...
 
virtual void intersect (LocatingSolution &) const
 
void resolve (LocatingSolution &) const
 

Protected Attributes

std::unique_ptr< LocatingPinnext_
 next additional Pin, if any
 

Member Function Documentation

◆ getPrioLevel()

virtual int getPrioLevel ( ) const
inlineprotectedvirtual

order to consider when resolving.

0=highest

Definition at line 112 of file locatingpin.hpp.

References lumiera::anonymous_namespace{basic-setup.cpp}::resolve().

Referenced by LocatingPin::addChain().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addChain()

LocatingPin & addChain ( LocatingPin newLp)
protected
Parameters
newLp
Note
we take ownership of newLp

Definition at line 81 of file locatingpin.cpp.

References LocatingPin::getPrioLevel(), and LocatingPin::next_.

Referenced by LocatingPin::LocatingSolution::getTime().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ resolve()

const LocatingPin::SolutionData resolve ( ) const

implementing the core Placement functionality.

By combining all the chained locating pins, try to get at a definite position (for this chain and consequently for the MObject handled by the enclosing Placement object).

Todo:

this could/should be replaced by a full-blown constraint solver at some point in the future

we are packing and unpacking the information (time,track) several times. Ichthyo considers a more elegant solution.

Definition at line 109 of file locatingpin.cpp.

References LocatingPin::LocatingSolution::getTime(), and LocatingPin::next_.

+ Here is the call graph for this function:
+ Inheritance diagram for LocatingPin:
+ Collaboration diagram for LocatingPin:

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