FMX.Graphics.TPathData.SmoothCurveTo
Delphi
procedure SmoothCurveTo(const ControlPoint2, EndPoint: TPointF);
C++
void __fastcall SmoothCurveTo(const System::Types::TPointF &ControlPoint2, const System::Types::TPointF &EndPoint);
Propriétés
Type | Visibilité | Source | Unité | Parent |
---|---|---|---|---|
procedure function |
public | FMX.Graphics.pas FMX.Graphics.hpp |
FMX.Graphics | TPathData |
Description
Ajoute une courbe lisse au TPathData en cours.
La courbe lisse est définie par quatre points :
- Un point de départ--le dernier point de TPathData.
- Deux points de contrôle. Si Points a plus de deux éléments, le premier point de contrôle coïncide avec le point de départ de la courbe, sinon il est égal au deuxième point de contrôle. Le paramètre
Control2
spécifie le deuxième point de contrôle. - Un point de fin, spécifié par le paramètre
EndPoint
.
SmoothCurveTo ajoute les deux points de contrôle et le point de fin de la courbe au tableau Points. Les points ajoutés sont du type CurveTo.
Pour déplacer le point de départ de la courbe, appelez la méthode MoveTo ou MoveToRel avant d'appeler SmoothCurveTo.
Pour trouver le point de fin de TPathData, appelez la méthode LastPoint.
Pour voir la différence entre les résultats de SmoothCurveTo et de SmoothCurveToRel, voir le tableau suivant :
Les points de paramètres utilisés dans l'exemple sont les suivants :
- Pour
ControlPoint2
-- CP2(a,b) - Pour
EndPoint
-- EP(c,d)
Chemin d'accès initial | Résultat CurveTo(CP2,EP) | Résultat CurveToRel(CP2,EP) |
---|---|---|
Voir aussi
- FMX.Graphics.TPathData.Points
- FMX.Graphics.TPathPointKind
- FMX.Graphics.TPathData.ClosePath
- FMX.Graphics.TPathData.CurveTo
- FMX.Graphics.TPathData.CurveToRel
- FMX.Graphics.TPathData.HLineTo
- FMX.Graphics.TPathData.HLineToRel
- FMX.Graphics.TPathData.LineTo
- FMX.Graphics.TPathData.LineToRel
- FMX.Graphics.TPathData.LastPoint
- FMX.Graphics.TPathData.MoveTo
- FMX.Graphics.TPathData.MoveToRel
- FMX.Graphics.TPathData.SmoothCurveToRel
- FMX.Graphics.TPathData.VLineTo
- FMX.Graphics.TPathData.VLineToRel