Handles drags-and-drops and performs node instantiation for the editor window.
|
| VuoEditorComposition (VuoComposition *baseComposition) |
| Creates an empty canvas upon which nodes and cables can be rendered.
|
|
void | setCompiler (VuoCompiler *compiler) |
| Specifies a compiler instance to be used by this composition (for, e.g., instantiating dropped nodes).
|
|
VuoRendererNode * | createNode (QString nodeClassName, string displayName="", double x=0, double y=0) |
| Instantiates a node of class name nodeClassName .
|
|
QAction * | getContextMenuDeleteSelectedAction (void) |
| Returns the context menu's action that deletes a component.
|
|
QMenu * | getContextMenuTints (QMenu *parent=0) |
| Returns the context menu's "Tint" submenu.
|
|
set< VuoRendererCable * > | getCablesInternalToSubcomposition (QList< QGraphicsItem * > subcompositionComponents) |
| Returns the set of cables creating internal connections within the set of input subcompositionComponents .
|
|
VuoCable * | getCableInProgress () |
| Returns the cable currently being dragged, or NULL if no cable is currently being dragged.
|
|
QGraphicsItem * | findNearbyComponent (QPointF scenePos, targetComponentType componentType=VuoEditorComposition::targetTypeAny, bool limitPortCollisionRange=true) |
| Returns a pointer to the component (port, cable, or node) that should be operated upon if the user were to click at position scenePos , or NULL if no component is within collision range.
|
|
QRectF | internalItemsBoundingRect () const |
| Calculates and returns the bounding rect of all internal composition components on the scene.
|
|
void | cancelCableDrag (void) |
| Cancel the current cable drag operation, if applicable.
|
|
void | clearHoverHighlighting () |
| Clear hover-highlighting of the previously highlighted graph component.
|
|
void | run (string compositionSnapshot) |
| Asynchronously compiles, links, and runs a composition created from the snapshot.
|
|
void | stop (void) |
| Asynchronously stops the running composition.
|
|
bool | isRunning (void) |
| Returns true if the composition is running.
|
|
void | updateRunningComposition (string oldCompositionSnapshot, string newCompositionSnapshot) |
| Asynchronously replaces the running composition (if any) with a composition created from newCompositionSnapshot .
|
|
void | updatePortConstantInRunningComposition (VuoCompilerInputEventPort *port, string constant) |
| If the composition is running, tells the composition to set a new constant value on the port.
|
|
string | takeSnapshot (void) |
| Returns a string representation of the composition (to save its current state).
|
|
| VuoRendererComposition (VuoComposition *baseComposition, bool renderMissingAsPresent=false) |
| Creates a canvas upon which nodes and cables can be rendered.
|
|
void | setBackgroundTransparent (bool transparent) |
| Sets whether the composition should be rendered with a transparent background.
|
|
VuoRendererNode * | createRendererNode (VuoNode *baseNode) |
| Creates a renderer detail for the base node.
|
|
void | addNode (VuoNode *node) |
| Adds a node to the canvas and the underlying composition.
|
|
void | addCable (VuoCable *cable) |
| Adds a cable to the canvas and the underlying composition.
|
|
void | addPublishedInputCable (VuoCable *c) |
| Adds a published input cable to the canvas and the underlying composition.
|
|
void | addPublishedOutputCable (VuoCable *c) |
| Adds a published output cable to the canvas and the underlying composition.
|
|
void | removeNode (VuoRendererNode *rn) |
| Removes a node from the canvas.
|
|
void | removeCable (VuoRendererCable *rc) |
| Removes a cable from the canvas.
|
|
void | removePublishedInputCable (VuoRendererCable *rc) |
| Removes a published input cable from the canvas and underlying composition.
|
|
void | removePublishedOutputCable (VuoRendererCable *rc) |
| Removes a published output cable from the canvas and underlying composition.
|
|
VuoRendererPublishedPort * | publishPort (VuoPort *port, string name="", bool attemptMerge=false) |
| Publishes this composition's internal port under the provided name , if possible; returns a pointer to the VuoRendererPublishedPort aliased to the internal port.
|
|
VuoCable * | createPublishedCable (VuoPort *vuoPseudoPort, VuoPort *internalPort) |
| Creates a published cable connecting published pseudo-port vuoPort with internal port internalPort (in whichever direction appropriate).
|
|
void | registerExternalPublishedPort (VuoPublishedPort *publishedPort, bool isInput) |
| Registers a previously existing VuoPublishedPort as one of this composition's published ports.
|
|
int | unregisterExternalPublishedPort (VuoPublishedPort *publishedPort, bool isInput) |
| Removes a published input or output VuoRendererPublishedPort from the list of published ports associated with this composition.
|
|
void | setPublishedPortName (VuoRendererPublishedPort *publishedPort, string name) |
| Sets the name of the provided publishedPort to name ; updates the composition's published pseudo-node and connected published cables accordingly.
|
|
string | getUniquePublishedPortName (string baseName, bool isInput) |
| Returns a string derived from the input baseName that is guaranteed to be unique either among the published input port names or among the published output port names for this composition, as specified by isInput .
|
|
vector< VuoRendererTypecastPort * > | collapseTypecastNodes (void) |
| Once all nodes and cables have been added to the scene, call this to convert each freestanding typecast node into a mini-node attached to its destination node.
|
|
VuoRendererTypecastPort * | collapseTypecastNode (VuoRendererNode *rn) |
| Convert a freestanding typecast node into a mini-node attached to its destination node; returns a pointer to the newly collapsed node.
|
|
void | uncollapseTypecastNode (VuoRendererNode *typecastNode) |
| Convert the collapsed typecast mini-node associated with the input typecastNode back into freestanding form.
|
|
VuoRendererNode * | uncollapseTypecastNode (VuoRendererTypecastPort *typecast) |
| Convert a collapsed typecast mini-node back into a freestanding node.
|
|
void | clearInternalPortEligibilityHighlighting (void) |
| Removes connection eligibility highlighting from all ports in the scene.
|
|
| VuoBaseDetail (string description, VuoComposition *base) |
| Creates a VuoComposition detail class.
|
|
VuoComposition * | getBase (void) const |
| Returns the VuoComposition detail class instance's base class instance.
|
|
void | setBase (VuoComposition *base) |
| Sets the VuoComposition detail class instance's base class instance.
|
|
|
void | dragEnterEvent (QGraphicsSceneDragDropEvent *event) |
| Decide whether we can accept the dragged data.
|
|
void | dragLeaveEvent (QGraphicsSceneDragDropEvent *event) |
| Decide what to do with the dragged data as it leaves.
|
|
void | dragMoveEvent (QGraphicsSceneDragDropEvent *event) |
| Decide what to do with the moved drag-drop data.
|
|
void | dropEvent (QGraphicsSceneDragDropEvent *event) |
| Handle the dropped data.
|
|
void | mouseDoubleClickEvent (QGraphicsSceneMouseEvent *event) |
| Handle mouse double-click events.
|
|
void | mousePressEvent (QGraphicsSceneMouseEvent *event) |
| Handle mouse press events.
|
|
void | mouseReleaseEvent (QGraphicsSceneMouseEvent *event) |
| Handle mouse release events.
|
|
void | mouseMoveEvent (QGraphicsSceneMouseEvent *event) |
| Handle mouse move events.
|
|
void | keyPressEvent (QKeyEvent *event) |
| Handle keypress events.
|
|
void | contextMenuEvent (QGraphicsSceneContextMenuEvent *event) |
| Display the context menu for a node, port, or cable.
|
|