issue102:tutoriel_4
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
issue102:tutoriel_4 [2015/11/06 12:19] – andre_domenech | issue102:tutoriel_4 [2015/11/07 00:45] (Version actuelle) – erlevo | ||
---|---|---|---|
Ligne 5: | Ligne 5: | ||
Draw a path using Bézier tool, consisting of straight lines forming a simple spiral type of shape. Something like this:** | Draw a path using Bézier tool, consisting of straight lines forming a simple spiral type of shape. Something like this:** | ||
- | Ce mois-ci, nous allons consacrer un premier regard aux effets de chemin. | + | Ce mois-ci, nous allons consacrer un premier regard aux effets de chemin. |
Plongeons directement dans le grand bain avec un effet relativement simple : Spline spirographique. | Plongeons directement dans le grand bain avec un effet relativement simple : Spline spirographique. | ||
- | Dessinez un chemin avec l' | + | Dessinez un chemin avec l' |
**Now select the path and open the LPE dialog using the Path > Path Effects... menu option (Path Effect Editor... in 0.48). At this point, the user interface diverges. To add the Spiro Spline LPE to your path: | **Now select the path and open the LPE dialog using the Path > Path Effects... menu option (Path Effect Editor... in 0.48). At this point, the user interface diverges. To add the Spiro Spline LPE to your path: | ||
Ligne 27: | Ligne 28: | ||
**The real difference comes when you start to manipulate the path: spiro splines are indifferent to changes in the node handles, so the most practical way to modify the path is to move the nodes themselves. The algorithm is a little unstable, and can sometimes shoot off into wild shapes as you do so; undoing your edit, or moving the nodes a little more, will generally get things back on track. For example, this image shows a green original path, plus the same path with the spiro LPE added in purple, demonstrating just how out-of-control the spiro algorithm can get!** | **The real difference comes when you start to manipulate the path: spiro splines are indifferent to changes in the node handles, so the most practical way to modify the path is to move the nodes themselves. The algorithm is a little unstable, and can sometimes shoot off into wild shapes as you do so; undoing your edit, or moving the nodes a little more, will generally get things back on track. For example, this image shows a green original path, plus the same path with the spiro LPE added in purple, demonstrating just how out-of-control the spiro algorithm can get!** | ||
- | La principale se manifeste quand vous commencez à manipuler le chemin : les splines spirographiques sont insensibles aux modifications des poignées des nœuds. La meilleure façon de modifier le chemin est donc de déplacer les nœuds eux-mêmes. L' | + | La principale se manifeste quand vous commencez à manipuler le chemin : les splines spirographiques sont insensibles aux modifications des poignées des nœuds. La meilleure façon de modifier le chemin est donc de déplacer les nœuds eux-mêmes. L' |
**As well as moving nodes, there' | **As well as moving nodes, there' | ||
- | En plus du déplacement des nœuds, il existe une autre manière de modifier un chemin spirographique : | + | En plus du déplacement des nœuds, il existe une autre manière de modifier un chemin spirographique : |
**The spiro algorithm was originally created by Raph Levien for font design (see http:// | **The spiro algorithm was originally created by Raph Levien for font design (see http:// | ||
- | L' | + | L' |
**Now it's time to draw something on the canvas: the kind of shape that suits spiro mode. Try drawing a circle, keeping it as neat as you can, and finishing in the starting node. As you draw you'll see a green line indicating your path, regardless of your current fill and stroke settings – don't worry, that's just a guideline that won't be visible when you've finished. Unless you have supernatural control over your muscles, the green path is likely to be bumpy and distorted; yet, on releasing the mouse button, it will be replaced with a nicely rounded circle. If your original path was extremely rough, you might not get a perfect circle, but the final shape will certainly be a lot smoother than your hand-drawn efforts.** | **Now it's time to draw something on the canvas: the kind of shape that suits spiro mode. Try drawing a circle, keeping it as neat as you can, and finishing in the starting node. As you draw you'll see a green line indicating your path, regardless of your current fill and stroke settings – don't worry, that's just a guideline that won't be visible when you've finished. Unless you have supernatural control over your muscles, the green path is likely to be bumpy and distorted; yet, on releasing the mouse button, it will be replaced with a nicely rounded circle. If your original path was extremely rough, you might not get a perfect circle, but the final shape will certainly be a lot smoother than your hand-drawn efforts.** | ||
- | Maintenant, il est temps de dessiner quelque-chose, le type de forme qui se prête bien aux splines spirographiques. Essayez de dessiner un cercle aussi régulier que possible en terminant votre tracé par son point de départ. À mesure que vous dessinez vous verrez une ligne verte qui prévisualise votre tracé sans tenir compte du type de trait et du remplissage. Ne vous en faites pas : il s'agit juste d'un guide qui ne sera plus visible quand vous aurez terminé. À moins que votre main ne soit d'une stabilité surnaturelle, | + | Maintenant, il est temps de dessiner quelque chose, le type de forme qui se prête bien aux splines spirographiques. Essayez de dessiner un cercle aussi régulier que possible en terminant votre tracé par son point de départ. À mesure que vous dessinez, vous verrez une ligne verte qui prévisualise votre tracé sans tenir compte du type de trait et du remplissage. Ne vous en faites pas : il s'agit juste d'un guide qui ne sera plus visible quand vous aurez terminé. À moins que votre main ne soit d'une stabilité surnaturelle, |
**Select the path you've drawn, and, in the Path Effects dialog, you should see that the Spiro Spline effect has been added. Toggle the visibility button (the eye-shaped icon) to see how the spiro version compares with your original path. Now try the process again with a different shape – a figure of eight, or a spiral. As you can see, for some shapes it's a lot easier to create something neat and smooth using spiro mode.** | **Select the path you've drawn, and, in the Path Effects dialog, you should see that the Spiro Spline effect has been added. Toggle the visibility button (the eye-shaped icon) to see how the spiro version compares with your original path. Now try the process again with a different shape – a figure of eight, or a spiral. As you can see, for some shapes it's a lot easier to create something neat and smooth using spiro mode.** | ||
- | Sélectionnez le chemin que vous venez de dessiner, et dans le dialogue des effets de chemin vous verrez que l' | + | Sélectionnez le chemin que vous venez de dessiner et, dans le dialogue des effets de chemin, vous verrez que l' |
**When using the Bézier tool in spiro mode, the icon on the tool control bar is the same, but the drawing process is a little different. I usually suggest drawing Bézier paths as a series of straight line segments by single-clicking to place each node, then going back in Node Edit mode to add curves afterwards. If you take that approach with spiro mode enabled, you'll get a series of corner nodes which, as we've seen, don't really play a role in the spiro algorithm. Instead you need to click-and-drag as you place each node, in order to set the curves as you go along. Personally, I find this to be much harder to control, but give it a try to see if you're better at it than me! You can always lay down straight segments with spiro mode enabled, then explicitly change some points into cusp nodes afterwards. It's not a huge workflow improvement, | **When using the Bézier tool in spiro mode, the icon on the tool control bar is the same, but the drawing process is a little different. I usually suggest drawing Bézier paths as a series of straight line segments by single-clicking to place each node, then going back in Node Edit mode to add curves afterwards. If you take that approach with spiro mode enabled, you'll get a series of corner nodes which, as we've seen, don't really play a role in the spiro algorithm. Instead you need to click-and-drag as you place each node, in order to set the curves as you go along. Personally, I find this to be much harder to control, but give it a try to see if you're better at it than me! You can always lay down straight segments with spiro mode enabled, then explicitly change some points into cusp nodes afterwards. It's not a huge workflow improvement, | ||
- | Quand vous utilisez l' | + | Quand vous utilisez l' |
**One big problem with having spiro buttons on these two tools it that it's easy for newcomers to Inkscape to enable them, then forget about it. A common question on the support forums is, “why can't I change the shape of my path using the node handles?” The answer is usually because the Spiro LPE has unintentionally been added, so watch out for that if you find yourself similarly stuck.** | **One big problem with having spiro buttons on these two tools it that it's easy for newcomers to Inkscape to enable them, then forget about it. A common question on the support forums is, “why can't I change the shape of my path using the node handles?” The answer is usually because the Spiro LPE has unintentionally been added, so watch out for that if you find yourself similarly stuck.** | ||
- | Un des problèmes posés par la disponibilité du mode spirographique pour ces deux outils est qu'il est facile pour les néophytes d' | + | Un des problèmes posés par la disponibilité du mode spirographique pour ces deux outils est qu'il est facile pour les néophytes d' |
**Let' | **Let' | ||
Ligne 61: | Ligne 62: | ||
Voyons un autre effet de chemin : les engrenages. | Voyons un autre effet de chemin : les engrenages. | ||
- | Vous devez commencer par dessiner un chemin avec au moins trois nœuds – au début j'en utiliserai exactement trois, ainsi le rôle de chacun | + | |
+ | Vous devez commencer par dessiner un chemin avec au moins trois nœuds – au début, j'en utiliserai exactement trois pour rendre | ||
1. l' | 1. l' | ||
2. le centre de la roue ; | 2. le centre de la roue ; | ||
Ligne 68: | Ligne 70: | ||
**With your gear selected, switch to the Bézier tool. The start and end nodes of your path should be visible: click on the end node, then double-click somewhere else on the canvas to add another segment to your path. Now the path has four nodes, and you should find that a second gear has been added, centered at the new end node.** | **With your gear selected, switch to the Bézier tool. The start and end nodes of your path should be visible: click on the end node, then double-click somewhere else on the canvas to add another segment to your path. Now the path has four nodes, and you should find that a second gear has been added, centered at the new end node.** | ||
- | Votre engrenage sélectionné, | + | L'engrenage |
**You can repeat this process to add more nodes, and hence more gears. Applying the Gear LPE to any path with more than three nodes follows the same rules: the first three nodes define the parameters for the first gear, and any subsequent nodes set the center points for additional gears in the chain. Once you've got a few gears on screen, switch to the node tool to move their centers, noting how Inkscape automatically adjusts the radius and number of teeth in the process. Try dragging the first node around the second one to crank your gear train into life (after all, it is a LIVE path effect).** | **You can repeat this process to add more nodes, and hence more gears. Applying the Gear LPE to any path with more than three nodes follows the same rules: the first three nodes define the parameters for the first gear, and any subsequent nodes set the center points for additional gears in the chain. Once you've got a few gears on screen, switch to the node tool to move their centers, noting how Inkscape automatically adjusts the radius and number of teeth in the process. Try dragging the first node around the second one to crank your gear train into life (after all, it is a LIVE path effect).** | ||
- | Vous pouvez répéter la manipulation pour ajouter plus de points | + | Vous pouvez répéter la manipulation pour ajouter plus de nœuds |
**As well as the values that are implicitly set by the positions of the nodes, there are two additional parameters required to fully specify the effect. These can be found at the bottom of the Path Effects dialog, in fields labelled “Teeth” (the number of teeth on the first gear), and “Phi” (the “tooth pressure angle” - set it to about 20 for realistic looking teeth). Almost all LPEs populate this part of the dialog with a UI of some sort, and in some cases the number of additional parameters is rather excessive (watch out if you're working on a small screen!).** | **As well as the values that are implicitly set by the positions of the nodes, there are two additional parameters required to fully specify the effect. These can be found at the bottom of the Path Effects dialog, in fields labelled “Teeth” (the number of teeth on the first gear), and “Phi” (the “tooth pressure angle” - set it to about 20 for realistic looking teeth). Almost all LPEs populate this part of the dialog with a UI of some sort, and in some cases the number of additional parameters is rather excessive (watch out if you're working on a small screen!).** | ||
- | En plus des valeurs contrôlées par la position des nœuds, deux paramètres | + | En plus des valeurs contrôlées par la position des nœuds, deux paramètres |
**You may have guessed from the UI that it's possible to apply more than one LPE to a path. In programming terms you can think of an LPE as a function that takes a path as an input, and produces another path as an output, allowing you to chain them together. Be aware, however, that the order in which you chain them is significant. Consider this simple path, made up of cusp nodes: | **You may have guessed from the UI that it's possible to apply more than one LPE to a path. In programming terms you can think of an LPE as a function that takes a path as an input, and produces another path as an output, allowing you to chain them together. Be aware, however, that the order in which you chain them is significant. Consider this simple path, made up of cusp nodes: | ||
Ligne 88: | Ligne 90: | ||
It may not be easy to see, but the only real effect is that the teeth of the gears have become more rounded (though each gear also has one tooth that's misshapen). Thinking about our chain of LPEs the general effect makes some sense: the first LPE outputs a composite path in the shape of the gears, then the spiro algorithm is applied to that path, smoothing out any cusp nodes that are present in it. But what happens if we apply the Spiro Spline LPE first, and the Gears LPE second?** | It may not be easy to see, but the only real effect is that the teeth of the gears have become more rounded (though each gear also has one tooth that's misshapen). Thinking about our chain of LPEs the general effect makes some sense: the first LPE outputs a composite path in the shape of the gears, then the spiro algorithm is applied to that path, smoothing out any cusp nodes that are present in it. But what happens if we apply the Spiro Spline LPE first, and the Gears LPE second?** | ||
- | Mais si nous appliquons les deux effets à ce chemin, l' | + | Mais si nous appliquons les deux effets à ce chemin, l' |
- | Cela n'est peut-être pas facile à voir, mais les dents sont maintenant plus arrondies (et chaque pignon possède une dent qui est déformée). En pensant à notre chaîne d' | + | Cela n'est peut-être pas facile à voir, mais les dents sont maintenant plus arrondies (et chaque pignon possède une dent qui est déformée). En pensant à notre chaîne d' |
**Now we've got a load more gears! This is because the path that is created by the Spiro Spline LPE has more nodes than our original input path. Although we drew 6 nodes, the spiro version of the path actually has 13, so when the second LPE runs it creates a lot of extra gears. We could have predicted this result had we only kept an eye on Inkscape' | **Now we've got a load more gears! This is because the path that is created by the Spiro Spline LPE has more nodes than our original input path. Although we drew 6 nodes, the spiro version of the path actually has 13, so when the second LPE runs it creates a lot of extra gears. We could have predicted this result had we only kept an eye on Inkscape' | ||
Ligne 95: | Ligne 97: | ||
Why not practice drawing naturalistic curves and mechanistic gears, then next time we'll continue to look at some of the other LPEs that are available.** | Why not practice drawing naturalistic curves and mechanistic gears, then next time we'll continue to look at some of the other LPEs that are available.** | ||
- | Maintenant nous avons beaucoup plus de pignons ! C'est parce-que le chemin créé par Spline spirographique comporte beaucoup plus de nœuds que le chemin d' | + | Maintenant nous avons beaucoup plus de pignons ! C'est parce-que le chemin créé par Spline spirographique comporte beaucoup plus de nœuds que le chemin d' |
Pourquoi ne pas vous entraîner à dessiner des courbes organiques et des engrenages réalistes ? | Pourquoi ne pas vous entraîner à dessiner des courbes organiques et des engrenages réalistes ? |
issue102/tutoriel_4.1446808743.txt.gz · Dernière modification : 2015/11/06 12:19 de andre_domenech