Keyframe.OfObject Method

Definition

Overloads

OfObject(Single)

Constructs a Keyframe object with the given time.

OfObject(Single, Object)

Constructs a Keyframe object with the given time and value.

OfObject(Single)

Constructs a Keyframe object with the given time.

[Android.Runtime.Register("ofObject", "(F)Landroid/animation/Keyframe;", "")]
public static Android.Animation.Keyframe? OfObject (float fraction);
[<Android.Runtime.Register("ofObject", "(F)Landroid/animation/Keyframe;", "")>]
static member OfObject : single -> Android.Animation.Keyframe

Parameters

fraction
Single

The time, expressed as a value between 0 and 1, representing the fraction of time elapsed of the overall animation duration.

Returns

Attributes

Remarks

Constructs a Keyframe object with the given time. The value at this time will be derived from the target object when the animation first starts (note that this implies that keyframes with no initial value must be used as part of an ObjectAnimator). The time defines the time, as a proportion of an overall animation's duration, at which the value will hold true for the animation. The value for the animation between keyframes will be calculated as an interpolation between the values at those keyframes.

Java documentation for android.animation.Keyframe.ofObject(float).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

OfObject(Single, Object)

Constructs a Keyframe object with the given time and value.

[Android.Runtime.Register("ofObject", "(FLjava/lang/Object;)Landroid/animation/Keyframe;", "")]
public static Android.Animation.Keyframe? OfObject (float fraction, Java.Lang.Object? value);
[<Android.Runtime.Register("ofObject", "(FLjava/lang/Object;)Landroid/animation/Keyframe;", "")>]
static member OfObject : single * Java.Lang.Object -> Android.Animation.Keyframe

Parameters

fraction
Single

The time, expressed as a value between 0 and 1, representing the fraction of time elapsed of the overall animation duration.

value
Object

The value that the object will animate to as the animation time approaches the time in this keyframe, and the value animated from as the time passes the time in this keyframe.

Returns

Attributes

Remarks

Constructs a Keyframe object with the given time and value. The time defines the time, as a proportion of an overall animation's duration, at which the value will hold true for the animation. The value for the animation between keyframes will be calculated as an interpolation between the values at those keyframes.

Java documentation for android.animation.Keyframe.ofObject(float, java.lang.Object).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to