88 lines
3.2 KiB
Ucode
88 lines
3.2 KiB
Ucode
/**
|
|
* Copyright 1998-2013 Epic Games, Inc. All Rights Reserved.
|
|
*/
|
|
class InterpTrackLinearColorBase extends InterpTrack
|
|
native(Interpolation)
|
|
abstract;
|
|
|
|
cpptext
|
|
{
|
|
// UObject interface
|
|
virtual void PostEditChangeProperty(FPropertyChangedEvent& PropertyChangedEvent);
|
|
|
|
void Serialize(FArchive& Ar)
|
|
{
|
|
Super::Serialize(Ar);
|
|
}
|
|
|
|
// InterpTrack interface
|
|
virtual INT GetNumKeyframes() const;
|
|
virtual void GetTimeRange(FLOAT& StartTime, FLOAT& EndTime) const;
|
|
virtual FLOAT GetTrackEndTime() const;
|
|
virtual FLOAT GetKeyframeTime(INT KeyIndex) const;
|
|
virtual INT SetKeyframeTime(INT KeyIndex, FLOAT NewKeyTime, UBOOL bUpdateOrder=true);
|
|
virtual void RemoveKeyframe(INT KeyIndex);
|
|
virtual INT DuplicateKeyframe(INT KeyIndex, FLOAT NewKeyTime);
|
|
virtual UBOOL GetClosestSnapPosition(FLOAT InPosition, TArray<INT> &IgnoreKeys, FLOAT& OutPosition);
|
|
|
|
virtual FColor GetKeyframeColor(INT KeyIndex) const;
|
|
|
|
// FCurveEdInterface interface
|
|
virtual INT GetNumKeys();
|
|
virtual INT GetNumSubCurves() const;
|
|
|
|
/**
|
|
* Provides the color for the sub-curve button that is present on the curve tab.
|
|
*
|
|
* @param SubCurveIndex The index of the sub-curve. Cannot be negative nor greater or equal to the number of sub-curves.
|
|
* @param bIsSubCurveHidden Is the curve hidden?
|
|
* @return The color associated to the given sub-curve index.
|
|
*/
|
|
virtual FColor GetSubCurveButtonColor(INT SubCurveIndex, UBOOL bIsSubCurveHidden) const;
|
|
|
|
virtual FLOAT GetKeyIn(INT KeyIndex);
|
|
virtual FLOAT GetKeyOut(INT SubIndex, INT KeyIndex);
|
|
virtual void GetInRange(FLOAT& MinIn, FLOAT& MaxIn);
|
|
virtual void GetOutRange(FLOAT& MinOut, FLOAT& MaxOut);
|
|
|
|
/**
|
|
* Provides the color for the given key at the given sub-curve.
|
|
*
|
|
* @param SubIndex The index of the sub-curve
|
|
* @param KeyIndex The index of the key in the sub-curve
|
|
* @param[in] CurveColor The color of the curve
|
|
* @return The color that is associated the given key at the given sub-curve
|
|
*/
|
|
virtual FColor GetKeyColor(INT SubIndex, INT KeyIndex, const FColor& CurveColor);
|
|
|
|
virtual BYTE GetKeyInterpMode(INT KeyIndex);
|
|
virtual void GetTangents(INT SubIndex, INT KeyIndex, FLOAT& ArriveTangent, FLOAT& LeaveTangent);
|
|
virtual FLOAT EvalSub(INT SubIndex, FLOAT InVal);
|
|
|
|
virtual INT CreateNewKey(FLOAT KeyIn);
|
|
virtual void DeleteKey(INT KeyIndex);
|
|
|
|
virtual INT SetKeyIn(INT KeyIndex, FLOAT NewInVal);
|
|
virtual void SetKeyOut(INT SubIndex, INT KeyIndex, FLOAT NewOutVal);
|
|
virtual void SetKeyInterpMode(INT KeyIndex, EInterpCurveMode NewMode);
|
|
virtual void SetTangents(INT SubIndex, INT KeyIndex, FLOAT ArriveTangent, FLOAT LeaveTangent);
|
|
|
|
/** Returns TRUE if this curve uses legacy tangent/interp algorithms and may be 'upgraded' */
|
|
virtual UBOOL UsingLegacyInterpMethod() const;
|
|
|
|
/** 'Upgrades' this curve to use the latest tangent/interp algorithms (usually, will 'bake' key tangents.) */
|
|
virtual void UpgradeInterpMethod();
|
|
}
|
|
|
|
/** Actually track data containing keyframes of a vector as it varies over time. */
|
|
var InterpCurveLinearColor LinearColorTrack;
|
|
|
|
/** Tension of curve, used for keypoints using automatic tangents. */
|
|
var() float CurveTension;
|
|
|
|
defaultproperties
|
|
{
|
|
TrackTitle="Generic LinearColor Track"
|
|
CurveTension=0.0
|
|
}
|