snapping ducks

2 suggestions, which might be quick and easy to implement…

“snap duck position tool/shortcut”
eg select 2 origins or ducks, snap the 1st to the position of the 2nd)
(note I dont mean link… just snap the position without linking)

related to (1)

for the warp tools: a shortcut to “align [wrap vertices] to [original box vertices] to save time having to copy and paster the coordinates in the param window

thanks for reading…

Hi carbonphobia,

  1. Snap ducks has a little problem. Basically, when ducks are selected, there is not current way to know which duck was first or second selected. Something extra has to be done to implement this straight forward.

Sincerely, I don’t understand the request. :blush:
-G

thanks for the quick reply…

For the 1st…
couldnt you have a separate “linked list of pointers” for selected origins/vertices and just add it to the list on “event select object”?

Just thinking about this (im actually a programmer as well, but i havent looked at the code) if you dont have such a linked list … are you going thru each layer and object when the mouse is dragged to see what is on and off ?
If thats the case the linked list could be a performance improvement too… ?

[side note: Just curious, the main guys working on the code like yourself, is there a studio behind you guys funding the development, or your just doing it for hobby? If there is some funding, Id quit my job and code synfig]

For the 2nd point… I mean that when you add a wrap layer there is: the “original box”, and
the “wrap shape box”

but they are not aligned (same positon of ducks)…

Usually animations start with the unwarped character, and then they get warped… so the animator has to spend time aligning the ducks manually in the param window.

I’ll give you a quick overview of what’s behind. In Synfig, most of objects are derived from Node class. Layer’s Parameters are all them derived from ValueNode class. There are three types of ValueNode child classes: Constant, Animated and Linkable. There is a fourth (PlaceHloder) but it is used only internally. Parameters can be linked if the hold value is compatible. Two linked parameters uses the same value node. Value nodes can be exported (given a name) so it can be used in any layer/canvas/document that references it.

On the other hand there are ducks. Ducks are graphical representation of value nodes. Ducks life is too short. Every time you move the time cursor, the set of ducks is discarded and a new set is created. Ducks are inserted in a list of ducks by a routine that examines the selected layers and the selected exported value nodes. There is not current way to know which duck is inserted first. Ducks in the list can be selected or not. It depends on user interaction. Selected ducks are in a list too as a sub group of all the ducks. Currently there is not way to know which duck was selected first by the user (it doesn’t mean there won’t be a way to know that if it is coded).

On the other hand there are Actions. Actions receive parameters (time, layers, value nodes, etc.) and depending on what parameters are passed, some actions are available others not available. Right click creates the candidate action list and shows it to the user as a context menu. There are not so many actions created for multiple ducks selection. One of them is the “Link” action. If all the ducks are value type compatible, they are linked, if not a message of error is shown. At link preparation time, there is a value node selected from the selected value nodes who will be the value node where all the other value nodes will link to. As each value node as a parameter associated (the duck knows both), when a value node is selected to be the link target, the other parameters are disconnected from its own value node and connected to the target link value node, so finally all them (the parameters) share the same value node.

To be able to create actions for multiple ducks selection (and then for multiple value node selection) it is needed to write the code to check all the selected value nodes and take decision then. Also, at selection time (inside the tool code) there must be new code to mark the first selected duck (value node) and use it as “target” for further collective actions.

You can read the history of Synfig here. Currently there are two working coders (nikitakit and me) one administrator and infrastructure worker (zelgadis) a windows packager (pixelgeek) basically. I have also full administration rights but I’m focused more on code. There are also very valuable people contributing with code, artwork, translation, etc. who won’t be listed to not miss anyone. All we are volunteers.

Aaah! the Warp Layer! Yes, it may be interesting but then it maybe difficult to select the target box instead of the source box. It is due to the fact that the ducks are not inserted in an ordered way. They are just inserted. I understand better the first request.

As an alternative to that tedious task of align the source and target boxes at the start of the animation, you can use the grid for that and once aligned you can scale, and translate to the original place.

Thanks for your feedback input.
Greetings
-G