DDraceNetwork Docs
CSmoothValue Class Reference

#include <smooth_value.h>

Inheritance diagram for CSmoothValue:
[legend]
Collaboration diagram for CSmoothValue:
[legend]

Public Member Functions

 CSmoothValue (float InitialValue, float MinValue, float MaxValue)
 
void SetValue (float Target)
 
void ChangeValue (float Amount)
 
void SetValueInstant (float Target)
 
bool UpdateValue ()
 
float GetValue () const
 
void SetValueRange (float MinValue, float MaxValue)
 
float GetMinValue () const
 
float GetMaxValue () const
 
- Public Member Functions inherited from CEditorComponent
virtual bool OnInput (const IInput::CEvent &Event) override
 
void InitSubComponents ()
 
void RegisterSubComponent (CEditorComponent &Component)
 
- Public Member Functions inherited from CEditorObject
virtual ~CEditorObject ()=default
 
virtual void OnInit (CEditor *pEditor)
 
virtual void OnUpdate ()
 
virtual bool OnInput (const IInput::CEvent &Event)
 
virtual void OnRender (CUIRect View)
 
virtual void OnHot ()
 
virtual void OnActive ()
 
virtual void OnReset ()
 
virtual void OnMapLoad ()
 
bool IsHot ()
 
void SetHot ()
 
void UnsetHot ()
 
bool IsActive ()
 
void SetActive ()
 
void SetInactive ()
 
CEditorEditor ()
 
const CEditorEditor () const
 
IInputInput ()
 
IClientClient ()
 
CConfigConfig ()
 
IConsoleConsole ()
 
IEngineEngine ()
 
IGraphicsGraphics ()
 
ISoundSound ()
 
ITextRenderTextRender ()
 
IStorageStorage ()
 
CUiUi ()
 
CRenderToolsRenderTools ()
 

Private Member Functions

float ZoomProgress (float CurrentTime) const
 

Private Attributes

bool m_Smoothing
 
float m_Value
 
CCubicBezier m_ValueSmoothing
 
float m_ValueSmoothingTarget
 
float m_ValueSmoothingStart
 
float m_ValueSmoothingEnd
 
float m_MinValue
 
float m_MaxValue
 

Detailed Description

A value that is changed smoothly over time.

Constructor & Destructor Documentation

◆ CSmoothValue()

CSmoothValue::CSmoothValue ( float  InitialValue,
float  MinValue,
float  MaxValue 
)

Member Function Documentation

◆ ChangeValue()

void CSmoothValue::ChangeValue ( float  Amount)

Change the value by the given amount.

◆ GetMaxValue()

float CSmoothValue::GetMaxValue ( ) const

◆ GetMinValue()

float CSmoothValue::GetMinValue ( ) const

◆ GetValue()

float CSmoothValue::GetValue ( ) const

◆ SetValue()

void CSmoothValue::SetValue ( float  Target)

Set a new target which the value should change to.

◆ SetValueInstant()

void CSmoothValue::SetValueInstant ( float  Target)

Set the value to the target instantly. If the value was changing the target will be discarded.

◆ SetValueRange()

void CSmoothValue::SetValueRange ( float  MinValue,
float  MaxValue 
)

◆ UpdateValue()

bool CSmoothValue::UpdateValue ( )

◆ ZoomProgress()

float CSmoothValue::ZoomProgress ( float  CurrentTime) const
private

Member Data Documentation

◆ m_MaxValue

float CSmoothValue::m_MaxValue
private

◆ m_MinValue

float CSmoothValue::m_MinValue
private

◆ m_Smoothing

bool CSmoothValue::m_Smoothing
private

◆ m_Value

float CSmoothValue::m_Value
private

◆ m_ValueSmoothing

CCubicBezier CSmoothValue::m_ValueSmoothing
private

◆ m_ValueSmoothingEnd

float CSmoothValue::m_ValueSmoothingEnd
private

◆ m_ValueSmoothingStart

float CSmoothValue::m_ValueSmoothingStart
private

◆ m_ValueSmoothingTarget

float CSmoothValue::m_ValueSmoothingTarget
private

The documentation for this class was generated from the following files: